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

[BUG] component_scaled events are published twice when a component stops #1888

Closed
1 of 9 tasks
brooksmtownsend opened this issue Apr 12, 2024 · 2 comments
Closed
1 of 9 tasks
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@brooksmtownsend
Copy link
Member

Affected project(s)

  • documentation
  • examples
  • wasmCloud host
  • wasmCloud CLI (wash)
  • wasmCloud dashboard UI (washboard)
  • capability providers
  • provider bindgen
  • control interface client
  • other / not sure

Describe the bug

When a component is scaled to a max instances value of 0, we emit two component_scaled events that assert that it was scaled to zero.

Steps to reproduce

wash start component wasmcloud.azurecr.io/http-hello-world:0.1.0 asd
nats sub "wasmbus.evt.>"
wash stop component asd

Expected behavior

I expect to see one event.

Environment

  • OS: [e.g. Linux, MacOS]
  • Shell [e.g. bash, zsh, powershell]
  • wasmcloud Version [e.g. 0.81.0]

Screenshots / Logs / Additional context

No response

@brooksmtownsend brooksmtownsend added bug Something isn't working good first issue Good for newcomers labels Apr 12, 2024
@yerzham
Copy link
Contributor

yerzham commented Apr 21, 2024

Related to this error, when running the following command for the running component:

wash scale component <host-id> wasmcloud.azurecr.io/http-hello-world:0.1.0 asd

There are also two component_scaled events, but one asserts that it is unbounded (max_instances: 4294967295), and the consequent event asserts that it is scaled to 0.

Similarly, when using

wash update component asd wasmcloud.azurecr.io/http-hello-world:0.1.0

It emits component_scaled about the updated component, but emits two component_scaled events that an old component is scaled to 0.

I have identified the root issue and will create a pull request soon.

@brooksmtownsend
Copy link
Member Author

Fixed by #1968

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants