Skip to content
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

Database persistence for seata-go Saga state machine #638

Closed
ptyin opened this issue Jan 3, 2024 · 1 comment · Fixed by #649
Closed

Database persistence for seata-go Saga state machine #638

ptyin opened this issue Jan 3, 2024 · 1 comment · Fixed by #649
Assignees

Comments

@ptyin
Copy link
Member

ptyin commented Jan 3, 2024

This is a subtask under the #618

Description:

This feature involves the storage aspect of the state machine and has dependencies on both the 1.1 Domain Model and 1.2 State Machine Configuration. The primary focus will be on creating SQL templates, with reference to the seata-engine-store module.

Implementation Details:

1. State Machine Definition (JSON) Storage - StateLangStore:

  • Implement a module for storing state machine definitions in JSON format. This could be achieved through a StateLangStore interface.

2. State Log Storage - StateLogStore:

  • Develop a storage mechanism for state logs. Create a StateLogStore module to handle the storage and retrieval of state logs.

3. Database Configuration Implementation - DbStateMachineConfig:

  • Implement the database configuration related to the state machine. Introduce a DbStateMachineConfig class responsible for configuring the database settings.

4. SQL Templates:

  • Focus on writing SQL templates for the state machine storage. Refer to the seata-engine-store module for guidance on structuring the SQL templates.

Next Steps:

  1. State Machine Definition (JSON) Storage - StateLangStore:

    • Define the StateLangStore interface for storing state machine definitions in JSON format.
  2. State Log Storage - StateLogStore:

    • Implement the StateLogStore module to handle the storage and retrieval of state logs.
  3. Database Configuration Implementation - DbStateMachineConfig:

    • Create the DbStateMachineConfig class to manage database-related configurations for the state machine.
  4. SQL Templates:

    • Focus on writing SQL templates for state machine storage, taking inspiration from the structure in the seata-engine-store module.

By completing these steps, we aim to establish a robust database storage system for the seata-go state machine, encompassing the storage of state machine definitions in JSON, managing state logs, and configuring the database settings through DbStateMachineConfig.

@ptyin
Copy link
Member Author

ptyin commented Jan 4, 2024

assign me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant