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

refactor!: refine extension startup flow #52

Merged
merged 3 commits into from
Sep 28, 2024

Conversation

halajohn
Copy link
Member

No description provided.

@halajohn halajohn self-assigned this Sep 26, 2024
With the introduction of the on_configure() initialization phase, the startup process of the
extension has been better planned.

- on_configure ~ on_configure_done + on_init ~ on_init_done: Handles its own initialization; cannot
  send or receive messages. The reason for this is that, before `on_init_done`, the extension may
  not be ready to handle external requests, so the received messages need to be temporarily stored.

- ~ on_start: The messages received before on_start() will be temporarily stored, and only after
  on_start() is called will they be sent to the extension. The reason for this is developers
  generally expect `on_start` to occur before any `on_cmd` events.

- on_start ~ on_stop_done: Normal sending and receiving of all messages and results.

BREAKING CHANGE: The initialization actions that were originally performed in on_start() need to be
moved to on_init(). This is because once on_start() is called, on_cmd() will start being received.
@halajohn halajohn changed the title feat: add more standalone testing logic refactor!: refine extension startup flow Sep 27, 2024
With the introduction of the on_configure() initialization phase, the startup process of the
extension has been better planned.

- on_configure ~ on_configure_done + on_init ~ on_init_done: Handles its own initialization; cannot
  send or receive messages. The reason for this is that, before `on_init_done`, the extension may
  not be ready to handle external requests, so the received messages need to be temporarily stored.

- ~ on_start: The messages received before on_start() will be temporarily stored, and only after
  on_start() is called will they be sent to the extension. The reason for this is developers
  generally expect `on_start` to occur before any `on_cmd` events.

- on_start ~ on_stop_done: Normal sending and receiving of all messages and results.

BREAKING CHANGE:
@halajohn halajohn merged commit 2abe332 into main Sep 28, 2024
22 checks passed
@halajohn halajohn deleted the feat--add-more-standalone-testing-logic branch September 28, 2024 06:15
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 this pull request may close these issues.

1 participant