Developing a protocol plug-in
You can use protocol plug-ins to add industry-specific messaging protocols to Eclipse Amlen in a controlled way that does not compromise the security of the server environment. The protocol plug-in can also support existing sensors that are not able to change to MQTT. You can write your own protocol plug-ins to use with Eclipse Amlen by using the Eclipse Amlen protocol plug-in SDK. The protocol plug-in facility is not available in high availability environments.
Download and extract the contents of the SDK bundle. Then, follow the instructions in ImaTools/ImaPlugin/README.txt to import the sample plug-in projects that are provided with the SDK bundle.
- IBM® SDK, Java Technology Edition, Version 7 (64-bit)
- Oracle Java SE Development Kit, Version 7 (64-bit)
You can use the Eclipse Amlen protocol plug-in SDK to extend Eclipse Amlen protocol support beyond the protocols that are natively supported. Use the SDK to write Java plug-ins that you can then deploy in Eclipse Amlen.
- A plug-in configuration file that is written in JSON
- A set of JAR files to implement the plug-in
/*
* Sample plug-in configuration file for JSON based messaging
*/
{
"Name": "json_msg",
"Description": "A sample plug-in for JSON based messaging",
"Protocol": "json_msg",
"Classpath": [ "jsonprotocol.jar" ],
"Class": "com.ibm.ima.samples.plugin.jsonmsg.JMPlugin",
"WebSocket": [ "json-msg" ],
"InitialByte": [ "{" ], /* The json_msg always starts with a JSON object */
"UseQueue": false, /* This plug-in does not implement queues */
"UseTopic": true, /* This plug-in implements topics */
"Properties": {
"Debug": true
}
}