-
Notifications
You must be signed in to change notification settings - Fork 2
feat: JS SDK emitter (#131), C# SDK emitter (#132), Python SDK emitter (#133) #180
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
johnOC03
wants to merge
16
commits into
camunda:main
Choose a base branch
from
johnOC03:feat/python-sdk-emitter-issue-133
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
8e74e72
feat: js-sdk emitter — lower path-analyser scenarios onto @camunda8/o…
johnOC03 a6bd2d8
chore: resolve merge conflicts with main — add with-config, reorder j…
johnOC03 0e5332b
feat: implement Python SDK async pytest emitter (#133)
dashka-str df5a36b
feat: implement Python SDK emitter with factory pattern and operation…
dashka-str a70ed2e
fix: resolve python-sdk emitter bugs, spec-pin hash, Windows spawn, b…
yarm03 f34f921
c#sdk
Muhamad690 0a224c0
Add job search/fail APIs and codegen support
Muhamad690 c29e837
feat: add JS SDK (#131) and C# SDK (#132) DoD completions — fixtures,…
yarm03 d4bdf00
chore: fix lint issues after rebase — suppressions, unused vars, temp…
yarm03 71d5f92
chore: fix spec-pin expectedSpecHash to match CI (Linux) bundler output
yarm03 3e8e469
fix: emit python model imports
Muhamad690 ce5fc03
fix: resolve 7 SDK emitter issues from PR #180
5a7ce53
chore: ignore local Visual Studio solution file
Muhamad690 728a356
refactor: omit OutputType from .csproj to use implicit default (Optio…
3302954
Merge branch 'feat/python-sdk-emitter-issue-133' of https://github.co…
dashka-str 4b4440f
fix: load .env via DotNetEnv before reading CAMUNDA_BASE_URL in emitt…
yarm03 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,3 +6,6 @@ external-spec/ | |
| test-results/ | ||
| *.tsbuildinfo | ||
| .claw/ | ||
| csharp-sdk/**/obj/ | ||
| csharp-sdk/**/bin/ | ||
| api-test-generator.sln | ||
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| # C# Semantic Type Automation Boundary | ||
|
|
||
| This note captures which parts of the C# semantic type system can be generated from | ||
| OpenAPI `x-semantic-type` annotations, and which parts are intentionally manual. | ||
|
|
||
| ## What a generator can safely do | ||
|
|
||
| - Emit `readonly record struct` wrappers for every `x-semantic-type` in the spec. | ||
| - Generate implicit conversions to and from `string` for ergonomic interop with | ||
| JSON and API payloads. | ||
| - Generate `ToString()` forwarding to the underlying `Value`. | ||
| - Group the generated types by domain (identifiers, keys, ids) in a single file | ||
| or a small file set. | ||
|
|
||
| These choices are structural and do not require human policy decisions. | ||
|
|
||
| ## What should remain manual | ||
|
|
||
| - **Type naming policy**: mapping `x-semantic-type` values to C# type names | ||
| (e.g., `ProcessDefinitionId` vs `ProcessDefinitionKey`) is mechanical, but | ||
| exceptions and aliases should be human-reviewed. | ||
| - **Nullability and default handling**: deciding when a type should be nullable | ||
| in DTOs is domain-specific and not always derivable from the schema alone. | ||
| - **API surface choices**: whether to include implicit conversions, explicit | ||
| `Parse`/`TryParse`, or validation checks is a usability decision that should | ||
| be reviewed by maintainers. | ||
| - **Packaging and namespaces**: project layout, namespace prefixes, and file | ||
| organization are repo conventions, not spec-derived data. | ||
|
|
||
| ## Recommended split of responsibilities | ||
|
|
||
| | Area | Generator responsibility | Manual responsibility | | ||
| | --- | --- | --- | | ||
| | Value struct type list | Create one type per `x-semantic-type` | Rename or alias any type that is confusing or deprecated | | ||
| | Conversions + `ToString()` | Generate standard conversions | Decide if stricter parsing or validation is needed | | ||
| | DTO field typing | Use generated types where `x-semantic-type` exists | Override nullability or apply domain rules | | ||
| | Project structure | None | Decide file layout, namespaces, and packaging | | ||
|
|
||
| ## Practical guidance | ||
|
|
||
| - Generate the initial `Identifiers.cs` file from the spec, then review and | ||
| curate it by hand for naming and nullability policy. | ||
| - Keep any manual edits in a separate patch or file so future regenerations | ||
| can be reviewed cleanly. |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,66 @@ | ||
| # gRPC Orientation Notes (zeebe-client-csharp) | ||
|
|
||
| This note documents the gRPC-only baseline of the community C# client so the | ||
| REST SDK work can be compared against it. | ||
|
|
||
| ## What was reviewed | ||
|
|
||
| - `Client.Cloud.Example/Program.cs` shows `CamundaCloudClientBuilder` usage for | ||
| Camunda Cloud, then calls `TopologyRequest().Send()`. | ||
| - `Client.Examples/Program.cs` shows a local gateway flow: | ||
| deploy BPMN, create process instance, and open a job worker. | ||
|
|
||
| ## Observations | ||
|
|
||
| - The client is a gRPC wrapper; all interaction is via gRPC commands. | ||
| - Key types are plain numeric values (e.g., `processDefinitionKey` and | ||
| `job.Key` are `long`-like values), with no distinct semantic wrappers. | ||
| - The job worker API uses `IJobClient`/`IJob` with plain numeric keys and | ||
| JSON string payloads. | ||
|
|
||
| ## Local run attempt | ||
|
|
||
| - `dotnet build Zeebe.sln` succeeded, with analyzer warnings. | ||
| - Running the Camunda Cloud example was blocked by `global.json` requiring | ||
| .NET SDK 10.0.201 (only 8.0.420 is installed here). | ||
| - The `camunda-platform` repo no longer ships Docker Compose files; the README | ||
| points to the Camunda Docker Compose quickstart artifacts instead. | ||
| - Downloaded the Camunda 8 Docker Compose quickstart (8.9) from the Camunda | ||
| distributions release and extracted it locally. | ||
| - `docker compose up -d` initially failed with a port bind error on | ||
| `0.0.0.0:8080`. The compose file was updated to publish the HTTP port on | ||
| `8088` instead, and the stack started successfully. | ||
| - The Orchestration Cluster container is healthy; gRPC is listening on | ||
| `localhost:26500` and HTTP is reachable at `http://localhost:8088`. | ||
|
|
||
| ## Next steps to fully execute the quick start | ||
|
|
||
| 1. Install .NET SDK 10.0.201 or adjust `global.json` for a supported SDK. | ||
| 2. Provide real Camunda Cloud credentials (`ZEEBE_CLIENT_ID`, | ||
| `ZEEBE_CLIENT_SECRET`, `ZEEBE_ADDRESS`) or run against a local gateway. | ||
| 3. Re-run the Cloud example and record the runtime outputs. | ||
|
|
||
| ## Next steps for local Docker Compose | ||
|
|
||
| 1. Re-run `docker compose up -d` in the extracted quickstart directory. | ||
| 2. Verify the Orchestration Cluster is reachable: | ||
| - REST API: `http://localhost:8088/v2` | ||
| - gRPC API: `localhost:26500` | ||
| 3. Re-run the local example and capture the console output. | ||
|
|
||
| ## Local Zeebe gateway run recipe (when credentials are unavailable) | ||
|
|
||
| 1. Start a local Camunda 8 / Zeebe gateway (for example, via your preferred | ||
| docker-based dev stack) and confirm the gateway is reachable at a host:port | ||
| such as `0.0.0.0:26500`. | ||
| 2. In the zeebe client repo, run the local examples project: | ||
|
|
||
| ```bash | ||
| export PATH="$HOME/.dotnet:$PATH" | ||
| dotnet run --project Client.Examples/Client.Examples.csproj | ||
| ``` | ||
|
|
||
| 3. If your gateway is not on the default `0.0.0.0:26500`, update the | ||
| `ZeebeUrl` constant in `Client.Examples/Program.cs` before running. | ||
| 4. Confirm the deploy → create instance → job worker sequence completes and | ||
| record the key types observed in the console output. |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # Camunda Orchestration REST SDK (C#) | ||
|
|
||
| Minimal REST client scaffold intended for the api-test-generator SDK emitter. | ||
|
|
||
| Status: minimal endpoints and DTOs are stubbed and should be verified against the | ||
| bundled OpenAPI spec before production use. | ||
|
|
||
| ## Included endpoints | ||
|
|
||
| - Create deployment | ||
| - Create process instance | ||
| - Cancel process instance | ||
| - Search process instances | ||
| - Activate jobs | ||
| - Complete job | ||
|
|
||
| ## Usage (sample) | ||
|
|
||
| See [csharp-sdk/examples/usage.cs](csharp-sdk/examples/usage.cs) for a minimal example. | ||
|
|
||
| ## Build | ||
|
|
||
| Requires .NET SDK 8.x: | ||
|
|
||
| ```bash | ||
| dotnet build csharp-sdk/src/Camunda.Orchestration.RestSdk/Camunda.Orchestration.RestSdk.csproj | ||
| ``` |
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done