# Experimental Evaluation of Unicast and Multicast CoAP Group Communication
## 2 Group Communication
### Hybrid Group Communication
#### 2.3.1 Entity Profile  
Resource profiles can be used to express the capabilities of a CoAP server and its resources [16]. In [9], we have extended the resource profiles concept with entity-specific fields. By using entity profiles, it becomes possible to customize the default behavior of the entity. These entity profile fields can be provided by the client upon entity creation time. If no values are provided, the EM will use default values for the newly-created entity. Clients can either use this default behavior or change any of those fields each time they use the entity by adding URI queries to the request. Following is a list of the entity profile fields that are relevant to this current work.  
* Entity resources (er): a list of the individual resources out of which the entity is composed.
* Entity message type (emt): specifies the message type to be used for communication between the EM and members. Possible values are con(confirmable) and non (non-confirmable). The default is con.
* Entity message type (ect): specifies the communication type to be used for communication between the EM and members. Possible values are unicast and multicast. The default is unicast. Whenever ect is set to multicast, the EM sets emt to non, since CoAP supports only non-confirmable multicast requests. Please note that this is the only profile field that can be set only at entity creation time and cannot be set at usage time by using URI queries. The reason for this is that changing the communication type implies changing the multicast group membership (see Section 2.3.2), which we consider as a configuration task that should not be done on the fly.
* Entity number of replies (err): specifies the number of replies that should be received from the members (member replies) before sending a reply to the client (client reply). This makes it possible not to wait for all members to reply. The default behavior is to wait until all replies have been received or have timed out. For example, the entity could consist of five members, but a reply from any three of them can be considered sufficient for the client, and thus, the EM does not need to wait until it receives replies from all group members. This does not just increase the speed of the client reply, but also makes the group tolerant to failures. This feature is of particular importance, since the client could set enrto one. In this case, the multicast entity is very similar to anycast communication where only one node of a potential group of receivers will respond. For anycast communication, the topologically-nearest node will reply. For group communication with enr equal to one, the EM will send a multicast request or several unicast requests to the group members and will send a single reply to the client as soon as the first reply from any of the group member arrives. This is an important feature, since RPL does not support anycast routing, and thus, this communication pattern was not yet available for the constrained nodes.
* Entity operation (eo): The operations that can be performed on the results obtained from the members. The operation is used to combine replies received from all the members (or the number of replies specified by enr) into one reply to the client. If at the time of querying the entity, the client does not specify which operation to use, the first operation listed in this field will be used. Currently, the following entity operations are supported:
* List (lst): A list of replies received from the members, without any arithmetic processing. This is the default behavior if no entity operation was specified.
* Average (avg): The average value.
* Minimum (min): The minimum value.
* Maximum (max): The maximum value.
* Delay between requests (delay): specifies the delay that should be injected between the requests sent from the EM to the members. The default is zero, and thus, the EM will send the requests as fast as it can.