You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(claude): improve CLAUDE.md with request flow and dev commands
- Add request flow section explaining notification pipeline across packages
- Add app/ package documentation which was missing
- Add single test and per-package test commands with sqlite tag note
- Add make lint and make fmt commands
- Note golangci-lint v2 usage
- Remove verbose README-like content (Docker, CLI examples, feature lists)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@@ -4,162 +4,87 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
4
4
5
5
## Project Overview
6
6
7
-
Gorush is a push notification microserver written in Go that supports sending notifications to iOS (APNS), Android (FCM), and Huawei (HMS) devices. It provides both HTTP REST API and gRPC interfaces for sending push notifications.
7
+
Gorush is a push notification microserver written in Go that supports sending notifications to iOS (APNS), Android (FCM), and Huawei (HMS) devices. It provides both HTTP REST API and gRPC interfaces.
8
8
9
9
## Architecture
10
10
11
-
### Core Components
11
+
### Request Flow
12
12
13
-
-**main.go**: Entry point that handles CLI flags, configuration loading, and server initialization
14
-
-**config/**: Configuration management with YAML support and environment variable overrides
15
-
-**core/**: Core abstractions for queue, storage, and health check interfaces
16
-
-**notify/**: Push notification implementations for different platforms (APNS, FCM, HMS)
17
-
-**router/**: HTTP server setup using Gin framework with REST endpoints
18
-
-**rpc/**: gRPC server implementation with protocol buffer definitions
19
-
-**status/**: Application statistics and metrics collection
-**config/**: YAML config with Viper, env var overrides. Reference config: `config/testdata/config.yml`
23
+
-**core/**: Shared types and interfaces — `Platform` enum, queue engine constants (`core/queue.go`), storage interface (`core/storage.go`), health check interface (`core/health.go`)
24
+
-**notify/**: Platform-specific push implementations. Each platform has its own file (`notification_apns.go`, `notification_fcm.go`, `notification_hms.go`). `global.go` holds shared client state
25
+
-**router/**: Gin HTTP server with REST endpoints and Prometheus metrics
26
+
-**rpc/**: gRPC server. Proto definitions in `rpc/proto/`
Config uses Viper with YAML files. Key sections: `core`, `grpc`, `android`, `ios`, `huawei`, `queue`, `stat`, `log`, `api`. See `config/testdata/config.yml` for all options. Environment variables can override any config value.
160
82
161
-
## Build Tags
83
+
## API Endpoints
162
84
163
-
- Default: `sqlite` tag enabled
164
-
-`lambda` tag: For AWS Lambda builds
165
-
- Custom tags can be set with `TAGS` environment variable
0 commit comments