#How to observe events coming from a callback actor?

1 messages · Page 1 of 1 (latest)

noble patrol
#

I've tried inspect and watching the snapshot, but I can't seem to find a way to observe the events my actor emits. I've debugged the process and watched the callback actor use sendBack to send events, but neither inspect nor subscribe are able to see these events. How do I expose this for testing?

noble patrol
#

One solution I've figured out is throwing the actor into an ad-hoc machine which reenters a state each time it gets any event from the callback actor, then subscribing to that machine. But there must be a cleaner way to observe the events

echo spoke
#

Yes. In the state that invokes the callback actor, you can add an on: { someEvent: {} } and listen to the events sent back there.

noble patrol
#

Awesome, thanks Kevin. I'm happy as long as I know I'm not missing something.

rotund lynx
#

You should be able to use the inspect API to see these events