Releases: indeedeng/iwf-golang-sdk
v1.2.0 Release
💥 Breaking changes in SDK API:
- Error handling in workflowState implementation
- All the APIs including Object, Persistence, Communication now all panic on error instead of returning.
- Mostly you don't need to. But the error can still be accessible if really need to do some customized handling:
- capturing panic yourself
- get the error from WorkerService API, because WorkerService will use captureStateExecutionError to capture the error
- When upgrading, simply remove the boilerplate code of returning error. See example in samples PR.
- default WorkflowType is now changed to eliminate the leading
*
character if the struct is from a pointer- If you have old workflows using this, you have to use
SetLegacyUseStarPrefixInWorkflowTypeForPointerStruct
API to tell the SDK to keep compatibilities for the old workflows:
- If you have old workflows using this, you have to use
SetLegacyUseStarPrefixInWorkflowTypeForPointerStruct(oldWf1, OldWf2, OldWf3)
- GetDefaultWorkflowType --> GetFinalWorkflowType to be more accurate.
API improvements
- Workflow definition provides new API and deprecated the old ones. The old ones are marked as deprecated. See example in samples PR for how to upgrade.
- NewStartingState --> StartStateDef
- NewNonStartingState --> NonStartStateDef
- NewDataObjectDef --> DataObjectDef
- NewSearchAttributeDef --> SearchAttributeDef
- NewSignalChannelDef --> SignalChannelDef
- NewInterstateChannelDef --> InterstateChannelDef
- Workflow now provides default struct to save the boilerplate code of returning default values.See example in samples PR.
- DefaultWorkflowType
- EmptyPersistenceSchema
- EmptyCommunicationSchema
- WorkflowState now provides default struct to save the boilerplate code of returning default value.See example in samples PR.
- DefaultStateIdAndOptions
- DefaultStateId
- DefaultStateOptions
What's Changed
- Add test for init search attributes and fix error message by @longquanzheng in #31
- Improve APIs to save boilerplate code by @longquanzheng in #35
- Fix default struct for workflow definition by @longquanzheng in #36
Full Changelog: v1.1.0...v1.2.0
v1.1.0 Release
💥 Breaking changes in SDK API:
- Client:
- Removed the startStateId for StartWorkflow API -- this should simplify the experience
- WorkflowOptions use a more friendly way to define initial search attributes
- UnregisteredClient
- Add UnregisteredWorkflowOptions for UnregisteredClient since it cannot use WorkflowOptions anymore. UnregisteredWorkflowOptions is the same as the previous WorkflowOptions
New features (need higher server version)
- Skip timer API for testing/operation : requires server version 1.2 +
- Decider trigger type: any command combination: requires server version 1.2 +
- Improve error handling to add more friendly API to check client side error
- Error handling returns subError type like WorkflowAlreadyStarted/WorkflowNotExists: requires server version 1.2.1+
- Add Attempt and FirstAttemptTimestampSeconds to context: requires server version 1.2.2+
- NOTE: This Attempt and FirstAttemptTimestampSeconds are important to implement complex WorkflowState behavior. E.g. It needs to do some backoff retry in a Start/Decide API for several times, but then give up and move on without failing the workflow
Requirements:
Best if runs with iWF server 1.2 +
It also runs with lower versions of iWF server, but new features will be rejected or returns empty
What's Changed
- Fix ResetType for ResetToStateExecutionId by @longquanzheng in #24
- Remove starting stateId from start workflow API by @longquanzheng in #25
- Separate WorkflowOptions from UnregisteredWorkflowOptions by @longquanzheng in #26
- Add skip timer API by @longquanzheng in #27
- Add anyCommandCombination with tests covering skipTimer API by @longquanzheng in #28
- Add error handling to differentiate different error types by @longquanzheng in #29
- Add attempt and firstAttemptTimestamp to context by @longquanzheng in #30
Full Changelog: v1.0.1...v1.1.0
v1.0.1 Release
Hey iWF users,
This release doesn't change anything else rather than migrated the repo/module to indeedeng organization.
Using the old module should still work as it's backward compatible for Golang.
However, it's recommended to update your application to use the new one.
Thanks and Happy New Year!
What's Changed
- Migrate to indeedeng org by @longquanzheng in #21
Full Changelog: v1.0.0...v1.0.1
v1.0.0 Final Release
Hi community,
This is the first official release of Golang SDK. Enjoy!
Requirement:
iWF server 1.1 +
It also runs with 1.0 version of iWF server, but some feature will be missing.
What's Changed compared to
- Bugfix: get search attributes with more tests by @longquanzheng in #19
- Initialize the project with IDL and interfaces by @longquanzheng in #1
- Define all interfaces and structs for GoSDK by @longquanzheng in #3
- Add workflow registry implementation by @longquanzheng in #4
- Client: Implement start workflow API by @longquanzheng in #5
- Implement Get Result API by @longquanzheng in #6
- Implement basic feature and test framework by @longquanzheng in #8
- Implement Timer by @longquanzheng in #9
- Implement Signal command and add test for workflow options an untypedClient by @longquanzheng in #10
- Implement interstate channel by @longquanzheng in #12
- Refactor to add UnregisteredClient by @longquanzheng in #13
- Implement persistence by @longquanzheng in #14
- Add reset API by @longquanzheng in #15
- Add init search attributes when start workflow by @longquanzheng in #16
- Add search and describe workflow API by @longquanzheng in #17
- Add get search attributes and data objects APIs by @longquanzheng in #18
Beta release
This is a beta release.
Some of the features in this version requires using the 1.1 version in server(e.g. double/bool search attribute type). 1.1 server will be release very soon.
For now, you can use the main branch of server, or If using docker, then using latest
tag of the image (and pull the latest one).
What's Changed
- Initialize the project with IDL and interfaces by @longquanzheng in #1
- Define all interfaces and structs for GoSDK by @longquanzheng in #3
- Add workflow registry implementation by @longquanzheng in #4
- Client: Implement start workflow API by @longquanzheng in #5
- Implement Get Result API by @longquanzheng in #6
- Implement basic feature and test framework by @longquanzheng in #8
- Implement Timer by @longquanzheng in #9
- Implement Signal command and add test for workflow options an untypedClient by @longquanzheng in #10
- Implement interstate channel by @longquanzheng in #12
- Refactor to add UnregisteredClient by @longquanzheng in #13
- Implement persistence by @longquanzheng in #14
- Add reset API by @longquanzheng in #15
- Add init search attributes when start workflow by @longquanzheng in #16
- Add search and describe workflow API by @longquanzheng in #17
- Add get search attributes and data objects APIs by @longquanzheng in #18
New Contributors
- @longquanzheng made their first contribution in #1
Full Changelog: https://github.com/iworkflowio/iwf-golang-sdk/commits/beta