Hi,
First of all, I want to thank you for your work on Eventric. I've used Eventric to bootstrap a showcase on Event Sourcing. The Socket.IO endpoint especially came in handy.
When I started to play with Eventric, I first tried the example provided in README.md as is, but I've not been able to make it work. I had to dig into the source code to come up with a solution. I'm not making a pull request yet because I'm not sure my corrections are the good ones.
Here are the changes I've made.
First of all, when I tried to configure the Socket.IO remote endpoint on the server, the following code didn't work :
socketIORemoteEndpoint.initialize socketIORemoteEndpointOptions, ->
eventric.addRemoteEndpoint socketIORemoteEndpoint
It looks like we can't have a callback in the initialize function
I changed it to :
socketIORemoteEndpoint.initialize socketIORemoteEndpointOptions
eventric.addRemoteEndpoint socketIORemoteEndpoint
Then, client side, when I tried to remote connect to the todo context, the folowing line didn't work :
var todoContext = eventric.remote('Todo');
It looks like the eventric.remote function does not exist. I used the eventric.remoteContext function instead :
var todoContext = eventric.remoteContext('Todo');
If this is correct, I can make a pull request if you wish.
Gilles
Hi,
First of all, I want to thank you for your work on Eventric. I've used Eventric to bootstrap a showcase on Event Sourcing. The Socket.IO endpoint especially came in handy.
When I started to play with Eventric, I first tried the example provided in README.md as is, but I've not been able to make it work. I had to dig into the source code to come up with a solution. I'm not making a pull request yet because I'm not sure my corrections are the good ones.
Here are the changes I've made.
First of all, when I tried to configure the Socket.IO remote endpoint on the server, the following code didn't work :
It looks like we can't have a callback in the
initializefunctionI changed it to :
Then, client side, when I tried to remote connect to the todo context, the folowing line didn't work :
It looks like the
eventric.remotefunction does not exist. I used theeventric.remoteContextfunction instead :If this is correct, I can make a pull request if you wish.
Gilles