ActiveMQ adapter is used to send messages. Messages are just what they sound like, payloads of data that can be shipped between various systems. These payloads can have headers and properties associated with them This adapter supports 3 types of data formats i.e. CSV, XML and JSON.
UseCase: Agent ActiveMQ Adapter for JSON payload. #
Objective: Test ActiveMQ Outbound adapter for JSON Format #
Pre-requiste: #
- Create Integration.
- Create Metadata Provider, IStructure Repository and Create Flat Message Type.
- Metadata Provider:Agent_ActiveMQ_RabbitMQ_JMS_Metadata
- IStructure Repository: ACtiveMQJSON
- Message Type:Root
Step1:To Create Agent ActiveMQ Json Outbound Adapter:
- Go to Integration (Example: Agent_new _adapter)
- Click on link AGENT Control Board.
- Go to Adapter Tab and Click on New Button.
Step2: How to Create Agent ActiveMQ Json Inbound Adapter:
- Click on link AGENT Control Board.
- Go to Adapter Tab and Click on New Button.
Configure Agent RabbitMQ CSV Inbound Adapter: you need to enter adapter properties base on system requirement and Select Connection Destination (Example:Agent LINUX).
Step3: Create Integration and Outbound Interface:
- Inbound Interface: ActiveMQ_Intbound_xml
- Metadata: AgentRabitMQ_ActiveMQ_JMSCSV
- Respository:RAbitMQCSV
- MessageType:Root
- Adapter: ActiveMQ_Outbound_JSON
Step4: Do mapping
Callout:
skyvvasolutions.CallOutControl c = new skyvvasolutions.CallOutControl();
c.returnJSONComplete=true;
c.actionDoIntegrate=false;
c.isCreateMessage=true;
String[] ids= new String[]{‘0011X00000nMy8jQAC’,’0011X00000nO1KoQAK’};
List<skyvvasolutions.CalloutResponse> result = skyvvasolutions.Iservices.invokeCalloutV3(‘ActiveMQ Adapter’,’ActiveMQ_outbound_JSON’,ids,’SYNC’,c);
Step5: Check result on Message Monitoring:
ActiveMQ Server: #
Check CSV Data on ActiveMQ Server:
- Open Link: http://18.197.54.48:8161/admin
- Username: admin
- Password: admin
Go to Queue:
click on the Queue name:
Click on Message ID generated on server to see message detail: