Skip to content
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.

can it support send a message to specific target module? #37

Closed
Kevin0626 opened this issue Oct 2, 2016 · 5 comments
Closed

can it support send a message to specific target module? #37

Kevin0626 opened this issue Oct 2, 2016 · 5 comments
Labels

Comments

@Kevin0626
Copy link

In our application, sometimes we need to send a message to a specific module. Can the project provide support for that need?

@damonbarry
Copy link
Member

Do you mean that the gateway application needs to send a message to a module? Or another application on the same machine?

Generally, out-of-band communication like this is not handled by the SDK.

Can you provide a more specific example? Or maybe a pull request? ;)

@Kevin0626
Copy link
Author

I mean sending to a broker module managed by the gateway.

for example, we send data to module A for prcessing, then to module B for further processing.

@damonbarry
Copy link
Member

When you configure modules A and B in the gateway, you can add a link to the configuration so that messages sent from module A and delivered to module B, like this:

"links": [
  { "source": "A", "sink": "B" },
  ...
]

Does that give you what you're looking for?

@aribeironovaes
Copy link
Contributor

Hi @Kevin0626,

To add more, is your scenario like this?
Having a Module A, Module B and Module C and you want sometimes send messages from Module A to Module B and sometimes from Module A to Module C? Is this your scenario?

If so, what you can do is filtering the message using Message Property, (like defining a Content-Type, for example.

I would advice to try to design your scenario so modules send target messages to other modules (using direct links), but if you sometime needs to implement the scenario above you can always use Message Properties.

Hope this helps,

Angelo Ribeiro.

@damonbarry
Copy link
Member

No activity...closing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants