Bug Fixes
-
💥 [
worker
] Remove unnecessaryReplayWorkerOptions
(#816)BREAKING CHANGE: While this is technically breaking (if you pass options that are irrelevant to replay like
maxActivitiesPerSecond
, you'll get a compilation error), we decided it did not warrant a major version bump, as it doesn't affect production code (replay is a testing feature) and is only a type change (is caught at compile type by TS users and doesn't affect JS users). -
Warn instead of throwing when getting
workflowBundle
withworkflowsPath
andbundlerOptions
(#833)⚠️ NOTE: We now prefer taking
workflowBundle
overworkflowsPath
when both are provided, which is the correct behavior and what users should expect.We also now warn that workflow interceptors are ignored when using
workflowBundle
. -
[
workflow
] Make breakpoints work inside workflow isolate context (#819)⚠️ NOTE: Bundles created with
bundleWorkflowCode
should only be used for callingWorker.create
when the exact same version of@temporalio/worker
is used. (If you don't pin to exact versions in yourpackage.json
, then you should use a lockfile, and both the machine that runsbundleWorkflowCode
andWorker.create
should runnpm ci
, notnpm install
.)⚠️ DEPRECATION:
sourceMap
andsourceMapPath
are now deprecated. We've inlined source maps, so now this works:const { code } = await bundleWorkflowCode({ workflowsPath }); const worker = await Worker.create({ workflowBundle: { code }, ...otherOptions });
-
Avoid using dynamic import in
@temporalio/testing
(#805) -
[
worker
] Don't start activity poller if no activities registered (#808) -
Update
proto3-json-serializer
to^1.0.3
(#809) -
Add
@types/long
to client (#735) -
[
worker
] Improve worker default options heuristics (#802) -
Use
GITHUB_TOKEN
increate-project
for CI (#721)
Features
-
💥 [
worker
] Add webpack configuration, closes #537 (#815)This was our most-upvoted feature request! (9 👍's.) See
WorkerOptions.bundlerOptions.webpackConfigHook
for usage.BREAKING CHANGE: If you provide both
workflowBundle
&workflowsPath
or bothworkflowBundle
&bundlerOptions
toWorker.create
, aValueError
will now be thrown. While this is technically breaking, TODO -
Add
@temporalio/nyc-test-coverage
package (#798, thanks to@vkarpov15
🙏)This package adds code coverage for Istanbul. It's currently in beta: the API may be unstable as we gather feedback on it from users. To try it out, see this code snippet for current usage.
-
[
common
] ImproveApplicationFailure
arguments; add.create
and.fromError
(#767)See
ApplicationFailure.create
andApplicationFailure.fromError
-
Expose additional console methods to workflow context (#831)
console.[error|warn|info|debug]
can now be called from Workflow code, in addition toconsole.log