feat: snapshot CLI + Jira/Salesforce with smart seeding#16
Closed
feat: snapshot CLI + Jira/Salesforce with smart seeding#16
Conversation
4 tasks
Contributor
|
Not sure we want to integrate wit airbyte automatically ? |
2 tasks
02dd1f0 to
a6bf78f
Compare
…eeding Adds the `doubleagent snapshot` CLI command and wires up Jira and Salesforce as zero-code Airbyte-backed services with smart seeding. Rust CLI: - snapshot pull/list/inspect/delete/push subcommands - ConnectorConfig struct with type/image/streams/config_env/stream_mapping - seeding + backend fields for smart relational filtering - Passes --seeding-json and --backend to Python subprocess Services (zero custom code — use generic_server.py from SDK): - Jira: 8 streams, smart seeding (3 projects → issues/sprints/boards/comments) - Salesforce: 8 streams, smart seeding (5 accounts → contacts/opportunities/cases) Smart seeding means: pull 3 Jira projects, follow foreign keys to get only their issues (max 10 each), then follow to comments (max 5 per issue). Result: small, relationally-consistent datasets instead of brute-force dumps. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Write self-contained main.py for Jira and Salesforce services (inline StateOverlay, NamespaceRouter, read-only resource endpoints) - Replace SDK generic_server with per-service FastAPI servers - Add crates/core/src/snapshot.rs for Rust-side snapshot manifest I/O - Simplify snapshot CLI pull command to delegate to connector/pull.py - Remove doubleagent-sdk dependency from all service pyproject.toml - Fix seed.rs for Option<String> file argument Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… pull Adds the `snapshot_pull` Python package in services/_lib/ that handles pulling data from Airbyte source connectors (PyAirbyte backend, no Docker needed). Includes smart relational filtering, PII redaction, and snapshot storage. Restores Airbyte routing in the Rust CLI — `doubleagent snapshot pull jira` now detects `type: airbyte` in service.yaml and delegates to `python -m snapshot_pull` with the connector config. This is infrastructure tooling (called by the CLI), not a service SDK. Services remain fully self-contained. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
76f95a4 to
b186670
Compare
Contributor
Author
|
Needs revision per feedback:
The snapshot CLI and Airbyte connector approach are good — just need to feed into seed instead of a separate bootstrap concept. |
…es, COW state Strip StateOverlay/NamespaceRouter from Jira and Salesforce snapshot servers, replace with simple dict state. Remove bootstrap/info/namespaces endpoints. Remove --hard, --namespace, --validate-against-real CLI flags. Remove httpx dependency from both services. 322 → 122 lines per service. Plain Python, zero framework overhead. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
Author
|
Revised — Simplified Jira/Salesforce services and CLI per feedback: Python services:
CLI:
|
…tracts - Run cargo fmt on snapshot.rs - Fix clippy unnecessary_unwrap: use if-let instead of is_some + unwrap - Update CI discovery to only include services with a contracts/ dir (Jira/Salesforce are snapshot-only, no contract tests) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
tomerezer
reviewed
Feb 17, 2026
Contributor
tomerezer
left a comment
There was a problem hiding this comment.
I'd separate the snapshot to its own PR
zozo123
added a commit
that referenced
this pull request
Feb 23, 2026
Cherry-picked from feat/airbyte-services (#16): - Jira fake service (8 streams, snapshot-backed) - Salesforce fake service (8 streams, snapshot-backed) - CI: discover only services with contracts/ dir - .gitignore: snapshot and venv patterns - _lib/pyproject.toml for snapshot_pull package Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
10 tasks
Contributor
Author
|
Superseded by #33 (consolidated PR) |
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
Adds
doubleagent snapshotCLI + Jira/Salesforce fake services + thesnapshot_pulltool for Airbyte connectors. No SDK dependency — each service is self-contained.What's in this PR
1. Rust CLI:
doubleagent snapshot(5 subcommands)pull <service>— auto-detects connector type from service.yaml:type: airbyte→ delegates tosnapshot_pull(PyAirbyte, no Docker)type: native→ runs service'sconnector/pull.pylist,inspect,delete,push— manage snapshot profiles2.
snapshot_pulltool (services/_lib/src/snapshot_pull/)Standalone Python package the CLI calls for Airbyte-backed services:
user-N@doubleagent.local)~/.doubleagent/snapshots/3. Jira + Salesforce services (read-only, snapshot-backed)
Self-contained FastAPI servers with inline COW state + namespace isolation:
/resources— list all resource types with counts/resources/{type}— list/search/filter resources (supports?q=field=value)/resources/{type}/{id}— get by ID/_doubleagent/health,reset,seed,bootstrap,info,namespaces)Jira: 8 streams (projects, issues, comments, sprints, boards, users, fields, workflows)
Salesforce: 8 streams (accounts, contacts, leads, opportunities, cases, users, tasks, events)
Architecture
Test plan
cargo check— zero warningspython -m snapshot_pull --help— entry point works🤖 Generated with Claude Code