Skip to Content
Author's profile photo Former Member

Static and Dynamic Queue Generator

I would like to share with you about my experience in a requirement.

The requirement was to create both static and dynamic queue (payload value) generator.

Since this was to be implemented for many scenarios I ruled out the way of approaching through udf in mapping.

I created an adapter module where the inputs of the module was to provide an existing QueueID from the channel, Xpath to determine the payload value, constant that needs to be static for the queue.

Creation of Adapter module:

1.       Install NWDS based on the PI version.

2.       If you are using latest version of JRE downgrade it to Java 6.

3.       File -> New EJB Project


4.       Uncheck the checkbox


5.       Clicking the finish button the project looks like this.


6.       Now right click on the project and create a EJB Bean


7.       Uncheck the service endpoint checkbox


8.       Click on the file and write your logic for Dynamic Queue generation Code is attached.


9.       Right click on your EJB project and Build project


10.   Now we have to attach the EJB project to EAR. File -> New (EAR Project)


11.   Attach the EJB project to our EAR.


12.   Double click on the application-j2ee.engine.xml file


     Add the below references:


13.   Build the EAR project follow Step 10

14.   Window preference add the SAP system where you want to deploy.


15.   Right Click on the EAR project Click Run on Server and finish button.


16.   Add the Configuration in Channel:


17.   Output


Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Eng Swee Yeoh
      Eng Swee Yeoh

      Hi Ragavendran

      Thank you for making the effort to contribute in this space on SCN.

      However, the bulk of the content above deals with the creation of the EJB/EAR project for adapter modules and not much on the details of this specific module. If you search on SCN, there already exist plenty of materials that cover the creation and deployment processes for adapter module development.

      As such, I'd like to suggest that you elaborate more on the specific details of your custom module, for example, the use cases, the logic of the module and some runtime examples. This would add move value to the blog as it allows others to consider if such a module would be useful for their own integration requirements.


      Eng Swee

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Hi Eng Swee,

      Thank you for the suggestion. Going forward will add up good details along with the code.

      This module is about generating dynamic queue as per the payload value (providing XPATH) along with the static constant to identify which particular interface.

      If user is not providing both the constant in the module parameters. The code will take by default "DEF" as constant. Then if the xpath value is not available or null in the payload Default Queue ID that is passed in the parameter will be taken.

      This module will be helpful in case of EOIO messages that might get stuck due to some issue other plants or shipments get affected in order to have a effective business flow. The generation of this dynamic and static queue module is used.

      I hope this information helped you to understand the overview of module solution.



      Author's profile photo Eng Swee Yeoh
      Eng Swee Yeoh

      You can use the Edit functionality to modify your blog accordingly instead of explaining this in the comments section.