wasmCloud/examples

[proposal] Adding a dapr-http-provider

Closed this issue · 4 comments

background

I am using wasmcloud in the test environment, and I want to put some micro-services running in wasmcloud as actors. But these actors need to communicate with the services running in k8s with the dapr sidecar.
In this way, new micro services can run in wasmcloud and the old services need no change.

design

Add a dapr-http-provider that respects the httpserver interface, and register to consul when the put link is called. When dapr calls wasmcloud actors, dapr will find the address in consul and finally call the dapr-http-provider. When the wasmcloud actor calls dapr services, it calls dapr-http-provider first.
image

need help

I am not sure if httpserver interface is enough for actor calls provider.
I am using go and currently can't find the tools or examples of how a provider calls an actor.

Are you interested in this? Looking forward to your feedback. I will put these codes on GitHub soon.

//cc @jordan-rash In case you are interested as I've found an awesome example of how actors call providers in go from you.

Hi, I've finished the first step of this provider. Now it lets dapr apps call wasmcloud actors.
here is the source code https://github.com/Taction/wasmcloud-dapr-http-provider

And this provider needs some configuration to start, another member of our team has submitted these changes. wasmCloud/wasmcloud-otp#498

I've uploaded a quick demo video for how to use this provider. https://www.youtube.com/watch?v=zi-Sg3uct5o

This is awesome! Just a note on the wasmcloud-provider SDK you pulled in from me, its not feature complete yet (i am hoping to have to fully MVP by end of next week). Notably, I don't handle multiple links to the provider quite yet. Now that I know someone is actually using it, Ill prioritize getting it finished

@jordan-rash Thanks for your excellent work!!👏 This can not be done without your work! I forked your sdk and made some changes https://github.com/Taction/wasmcloud-provider. Also, I've fixed the handle of multiple links in the dapr-http-provider project. I am glad to contribute sdk together if needed. Feel free to reach me from slack or email if there is anything I can help with!

stale commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If this has been closed too eagerly, please feel free to tag a maintainer so we can keep working on the issue. Thank you for contributing to wasmCloud!