I have two solutions for data transfer and information between co-operate processes:
Message Passing and Shared Memory.
1- But I do not know which one is suitable for low(small) data exchange, and why?
2- Implementation which is easier to communicate between computers?
3- Which one is faster? And why?
Below are the answers which I hope helps you out:
1) I would suggest to go with “Message Passing” for small data exchange. Using Message passing you can avoid all the problems that you have to face in shared memory like locking, synchronization etc.
2) Well you can’t implement Shared memory across computers, hence you have to go with message passing. Using TCP sockets (even UDP sockets), Named pipes etc.
3) If you compare both than Shared memory is fast as the data is not copied between the processes as it is being done in Message passing, but I would suggest you to not choose Shared memory over message passing just on the fact of being “faster” as there are other aspects which are on the side of message passing like simplicity, avoid all locking problems