mardi 21 juillet 2015

c# design for communication with other system via tcp

I have a c# application that has a service layer that currently uses different repositories for accessing data.

I know need to get data and send commands to an embedded system using TCP (modbus) communication. I would like to know what the best pattern(s) to use with regards to interfacing between my service layer and the external embedded system.

Some of the ideas that I have been thinking of are: CQRS - Embedded system can be a repository for querying/getting data and an IReceiver for receiving commands. Or I create a facade (service) for getting data and executing commands/methods such as CloseSwitch().

Any advice would be greatly appreciated.

Aucun commentaire:

Enregistrer un commentaire