Repository navigation
docs(architecture): add SDK architecture documentation and registry (#1199) - #1218
Closed
huangji6693-max wants to merge 1 commit into
Closed
huangji6693-max wants to merge 1 commit into
huangji6693-max wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documents the complete architecture and design decisions of
@stellar-split/sdkand adds a programmaticArchitectureRegistrycatalog with automated verification tests.Closes #1199
Changes
ARCHITECTURE.md,src/architectureRegistry.ts):./react,./ui,./lazy,src/qr)StellarSplitClient,NetworkEnvironment,TypedEventEmitter)InvoiceStateMachine,PaymentOrchestrator,Signer,sep41Adapter)PluginRegistry,Deduplicator,TelemetryHookManager)RpcLoadBalancer,CircuitBreaker,OfflineQueue,RpcConnectionPool)xdrDecoder,StellarSplitErrortaxonomy,horizonErrorClassifier)ARCHITECTURE.md,docs/ARCHITECTURE_GUIDE.md):ADR-001throughADR-006) covering strictbigintstroop representation, simulate-before-submit preflight pipeline, onion plugin middleware vs. fire-and-forget telemetry hooks, request deduplication for idempotency, multi-endpoint RPC load balancing with circuit breaking, and subpath exports for tree-shaking.ARCHITECTURE.md):flowchart TB), mutating transaction lifecycle (sequenceDiagram), and resilience circuit breaker state machine (stateDiagram-v2).ARCHITECTURE.md,docs/ARCHITECTURE_GUIDE.md):package.jsonsubpath entrypoints (.,./ui,./react,./testing,./mock,./telemetry,./utils,./lazy).SdkPlugin,TelemetryHooks, customSigner, request/response interceptors,HealthCheckRegistry, andregisterUpgradeMigration) with working TypeScript examples.SEP-0010,SEP-0024,SEP-0031,SEP-0041).test/architectureDocs.test.ts):ArchitectureRegistry, layer ordering, ADRs, Mermaid diagrams,package.jsonsubpath coverage, extension points, and reference links.Verification
npx vitest run test/architectureDocs.test.ts(8/8 passing)npm test(all core client, retry policy, and network environment tests passing)