wasmCloud icon indicating copy to clipboard operation
wasmCloud copied to clipboard

[BUG] Ensure bad components do not affect the host

Open vados-cosmonic opened this issue 1 year ago • 2 comments

Affected project(s)

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

Describe the bug

If a component handles streams incorrectly (in particular), it is possible for the host to hang and not exit properly, and for the host to report that the component is missing, despite it being listed in inventory.

Version 0.1.0 of component-http-jsonify has this problem -- sometimes it works just fine, and others

Steps to reproduce

  1. Start the host (wash up)
  2. Start a component with faulty stream handling (wash start ghcr.io/component-http-jsonify:0.1.0 http-jsonify)
  3. Use wash call on the component (wash call http-jsonify "wrpc:http/incoming-handler.handle")
  4. Notice that the call fails, reporting that the component is missing, and the host then does not exit cleanly with Ctrl+C

Expected behavior

The host should always be isolated from bad components

Environment

  • OS: Linux
  • Shell ZSH
  • wasmcloud Version 1.0.0

Screenshots / Logs / Additional context

No response

vados-cosmonic avatar Apr 18 '24 15:04 vados-cosmonic

When we solve this issue, I definitely want to clarify here exactly the blast radius that we can reproduce. A hanging shutdown is more acceptable (IMO) than a component affecting another running component

brooksmtownsend avatar Apr 19 '24 14:04 brooksmtownsend

This is primarily resolved by #2000 and #2017

brooksmtownsend avatar Apr 30 '24 16:04 brooksmtownsend

Closing because of ☝🏻

brooksmtownsend avatar May 08 '24 19:05 brooksmtownsend