How do JADE agents send a message?

From the point of view of the programmer, it is just a single method call (send()).
However, the internals of JADE select the most appropriate transport protocol for each different situation:

  •  If the receiver agent lives on the same agent container, the Java object representing the ACL message is passed to the receiver by using an event object, without any message translation.
  • If the receiver agent lives on the same JADE platform but within a different container, the ACL message is sent by using Java Remote Method Invocation. Java RMI allows transparent object marshaling and unmarshaling, avoiding tedious message conversions. Apart from performance, the agent receives a Java object, just like intra-container messaging.
  • If the receiver lives on a different agent platform, the IIOP protocol and OMG IDL interface are used, according to the FIPA standard. This involves translating ACL message object into a character string and then performing a remote invocation using IIOP as middleware protocol. On receiver side, an IIOP unmarshaling will occur, yielding a Java String object, which will be parsed into an ACLMessage object. Eventually, the Java object will be dispatched to the receiver agent (via Java events or RMI calls).

Posted in: More technical questions