Skip to content

Service development

drakehutner edited this page Apr 23, 2013 · 1 revision

Service Development

How to write your own service for hydra?

The none-distributed approach

The minimal effort to get your software running inside hydra is writing a service activator. A service activator starts the main routine of your software and enables it to run.

This method doesn't allow any distributed computing through the hydra. It's just another way to call the main routine.

Example Activator

... To be written ...

Register message handlers, referencing other nodes

To benefit from hydras distributed nature you need to register handlers on specific event messages. This way your software can spread tasks across the network. Each service activator provides a ServiceContext which has a registerMessageHandler method. The ServiceContext also provides the possibility for referencing other nodes to communicate with them more or less directly, by sending direct messages through the eventstream.