Skip to content

Commit c2ee6d5

Browse files
committed
1 parent 96c3d63 commit c2ee6d5

27 files changed

+770
-112
lines changed

.circleci/config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
test:
3434
docker:
3535
- image: circleci/node:11.10.1
36-
- image: camunda/zeebe:0.23.0
36+
- image: camunda/zeebe:0.23.1
3737
working_directory: ~/zeebe-client-node-js
3838
steps:
3939
- checkout

CHANGELOG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
_Changes in APIs or behaviour that may affect existing applications that use zeebe-node._
66

77
- The `job.variables` and `job.customHeaders` in the worker job handler are now typed as read-only structures. This will only be a breaking change if your code relies on mutating these data structures. See the section "Working with Workflow Variables and Custom Headers" in the README for an explanation on doing deep key updates on the job variables.
8+
- The ZBClient no longer eagerly connects to the broker by default. Previously, it did this by issuing a topology command in the constructor. This allows you an onReady event to be emitted. You can re-enable the eager connection behavior, by either passing `eagerConnection: true` to the client constructor options, or setting the environment variable `ZEEBE_NODE_EAGER_CONNECTION` to `true`. See [#151](https://github.com/creditsenseau/zeebe-client-node-js/issues/151).
89
- The library nows logs with the simplified `ZBSimpleLogger` by default, for friendly human-readable logs. This will only be a breaking change if you currently rely on the structured log output. To get the previous structured log behaviour, pass in `stdout: ZBJsonLogger` to the `ZBClient` constructor options, or set the environment variable `ZEEBE_NODE_LOG_TYPE` to `JSON`. Refer to the "Logging" section in the README.
910

1011
## New Features
@@ -20,7 +21,6 @@ _New shiny stuff._
2021
- `ZBClient` now contains an `activateJobs` method. This effectively exposes the entire Zeebe GRPC API, and allows you to write applications in the completely unmanaged style of the Java and Go libraries, if you have some radically different idea about application patterns.
2122
- The Grpc layer has been refactored to implement the idea of "connection characteristics". When connecting to Camunda Cloud, which uses TLS and OAuth, the library would emit errors every time. The refactor allows these connection errors to be correctly interpreted as expected behaviour of the "connection characteristics". You can also set an explicit initial connection tolerance in milliseconds for any broker connection with the environment variable `ZEEBE_INITIAL_CONNECTION_TOLERANCE`. See [this article](https://www.joshwulf.com/blog/2020/03/camunda-cloud-connection-2/), issue [#133](https://github.com/creditsenseau/zeebe-client-node-js/issues/133), and the README section "Initial Connection Tolerance" for more details.
2223
- The connection tolerance for transient drop-outs before reporting a connection error is now configurable via the environment variable `ZEEBE_CONNECTION_TOLERANCE`, as well as the previous constructor argument `connectionTolerance`.
23-
- The ZBClient eagerly connects to the broker by issuing a topology command. This allows you an onReady event to be emitted. You can disable this (for example, for testing without a broker), by either passing `eagerConnection: false` to the client constructor options, or setting the environment variable `ZEEBE_NODE_EAGER_CONNECTION` to `false`. See [#151](https://github.com/creditsenseau/zeebe-client-node-js/issues/151).
2424
- The integration tests have been refactored to allow them to run against Camunda Cloud. This required dealing with a Zeebe broker in an unknown state, so all tests now template unique process ids, unique task types, and unique message names to avoid previous test run state in the cluster interfering with subsequent test runs.
2525
- I've started documenting the internal operation of the client in BPMN diagrams. These can be found in the `design` directory.
2626
- The README now contains a section "Writing Strongly-typed Job Workers", on writing typed workers in TypeScript.

design/grpc-error-handling.md

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# GRPC Channel Error Handling
2+
3+
There are a few things that can go wrong on the Grpc channel:
4+
5+
- **No resolvable DNS address**. In this case, the stream emits an error with `code`: `14`, and `details`: `Name resolution failed for target nobroker:26500`.
6+
- **Resolvable address, but no broker**
7+
- **Broker goes away**. This can be due to a Docker restart, or a K8s pod reschedule (for example, in Camunda Cloud).
8+
- **Intermittent Network Error**
9+
- **Business Error**. For example:
10+
- **Broker backpressure**. This returns error code 8.

0 commit comments

Comments
 (0)