- 3,722,440 Users
- 2,244,312 Discussions
- 7,849,837 Comments
Forum Stats
Discussions
Categories
- 16 Data
- 362.2K Big Data Appliance
- 7 Data Science
- 2K Databases
- 589 General Database Discussions
- 3.7K Java and JavaScript in the Database
- 32 Multilingual Engine
- 495 MySQL Community Space
- 7 NoSQL Database
- 7.7K Oracle Database Express Edition (XE)
- 2.8K ORDS, SODA & JSON in the Database
- 419 SQLcl
- 57 SQL Developer Data Modeler
- 185K SQL & PL/SQL
- 21.1K SQL Developer
- 2.3K Development
- 3 Developer Projects
- 32 Programming Languages
- 135.5K Development Tools
- 12 DevOps
- 3K QA/Testing
- 323 Java
- 10 Java Learning Subscription
- 12 Database Connectivity
- 70 Java Community Process
- 2 Java 25
- 11 Java APIs
- 141.2K Java Development Tools
- 8 Java EE (Java Enterprise Edition)
- 153K Java Essentials
- 135 Java 8 Questions
- 86.2K Java Programming
- 270 Java Lambda MOOC
- 65.1K New To Java
- 1.7K Training / Learning / Certification
- 13.8K Java HotSpot Virtual Machine
- 14 Java SE
- 13.8K Java Security
- 3 Java User Groups
- 22 JavaScript - Nashorn
- 18 Programs
- 145 LiveLabs
- 34 Workshops
- 9 Software
- 3 Berkeley DB Family
- 3.5K JHeadstart
- 5.7K Other Languages
- 2.3K Chinese
- 4 Deutsche Oracle Community
- 15 Español
- 1.9K Japanese
- 3 Portuguese
EWPS and JMS

We are running Documaker Standard Edition in a Docker container. We are using EWPS (in the same container) to receive requests and send them to Docupresentment to generate documents.
Currently, we are using http queues, but Oracle is recommending the use of JMS or MQ for high volume environments. I have Docupresentment listening on JMS queues (ActiveMQ is also installed in the container ..I can prove this by using thread.sh), but I am having trouble getting EWPS to communicate over JMS.
ewps.config.xml:
<entry name="queuefactory.class">com.docucorp.messaging.jms.DSIJMSJNDIMessageQueueFactory</entry>
<entry name="jms.inputqueue.connectstring">resultq</entry>
<entry name="jms.outputqueue.connectstring">requestq</entry>
<entry name="jms.qcf.name">queueConnectionFactory</entry>
<entry name="jms.initial.context.factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</entry>
<entry name="jms.provider.URL">tcp://0.0.0.0:61616</entry>
<entry name="jms.security.principal">admin</entry>
<entry name="jms.security.credentials">admin</entry>
<entry name="jms.inputqueue.connectstring">resultq</entry>
<entry name="jms.outputqueue.connectstring">requestq</entry>
Given that, the EWP log indicates:
2021-02-02 04:33:07,983-[http-nio-8080-exec-1]-Queue Manager properties -
#Tue Feb 02 04:33:07 UTC 2021
jms.qcf.name=queueConnectionFactory
jms.initial.context.factory=org.apache.activemq.jndi.ActiveMQInitialContextFactory
queuefactory.class=com.docucorp.messaging.jms.DSIJMSJNDIMessageQueueFactory
jms.outputqueue.connectstring=requestq
jms.inputqueue.connectstring=resultq
2021-02-02 04:33:07,984-[http-nio-8080-exec-1]-EWPS Configuration read from web.xml location '/WEB-INF/xml/ewps.config.xml'
2021-02-02 04:33:07,986-[http-nio-8080-exec-1]-EWPSDocumentServicesSkeleton : filecache is disabled
2021-02-02 04:33:08,443-[http-nio-8080-exec-1]-javax.naming.NameNotFoundException: queueConnectionFactory
I am missing something, and I suspect that I need to create a jndi.properties file so that EWP can find queueConnectionFactory.
Any ideas?
Thanks in advance!
Dave
Answers
-
Hi Dave,
I haven't tested this specifically with EWPS, but I did do a similar setup with IDS using RabbitMQ over JMS. In order to do this, I used the following settings in docserv.xml, which should be translatable to your EWPS.config.xml:
<section name="queue"> <section name="marshallers"> <entry name="marshaller.class">com.docucorp.messaging.data.marshaller.SOAPMIMEDSIMessageMarshaller</entry> <entry name="marshaller.class">com.docucorp.messaging.data.marshaller.SerializationDSIMessageMarshaller</entry> </section> <entry name="queuefactory.class">com.docucorp.messaging.jms.DSIJMSJNDIMessageQueueFactory</entry> <entry name="jms.initial.context.factory">com.sun.jndi.fscontext.RefFSContextFactory</entry> <entry name="jms.provider.URL">file:///home/oracle/odee/docupresentment</entry> <entry name="jms.qcf.name">idsqcf</entry> <entry name="jms.inputqueue.connectstring">idsreq</entry> <entry name="jms.outputqueue.connectstring">idsres</entry> </section>
Then, I created a .bindings file in the IDS directory - the RefFSContextFactory is automatically configured to look for this file in this directory; you may be able to do similar configuration for EWPS. Note you should replace the RabbitMQ class names with what's appropriate for your system.
idsqcf/ClassName=javax.jms.ConnectionFactory idsqcf/FactoryName=com.rabbitmq.jms.admin.RMQObjectFactory idsqcf/RefAddr/0/Content=jms/ConnectionFactory idsqcf/RefAddr/0/Type=name idsqcf/RefAddr/0/Encoding=String idsqcf/RefAddr/1/Content=javax.jms.ConnectionFactory idsqcf/RefAddr/1/Type=type idsqcf/RefAddr/1/Encoding=String idsqcf/RefAddr/2/Content=com.rabbitmq.jms.admin.RMQObjectFactory idsqcf/RefAddr/2/Type=factory idsqcf/RefAddr/2/Encoding=String # replace with IP address of RabbitMQ host. idsqcf/RefAddr/3/Content=127.0.0.1 idsqcf/RefAddr/3/Type=host idsqcf/RefAddr/3/Encoding=String idsreq/ClassName=javax.jms.Queue idsreq/FactoryName=com.rabbitmq.jms.admin.RMQObjectFactory idsreq/RefAddr/0/Content=jms/Queue idsreq/RefAddr/0/Type=name idsreq/RefAddr/0/Encoding=String idsreq/RefAddr/1/Content=javax.jms.Queue idsreq/RefAddr/1/Type=type idsreq/RefAddr/1/Encoding=String idsreq/RefAddr/2/Content=com.rabbitmq.jms.admin.RMQObjectFactory idsreq/RefAddr/2/Type=factory idsreq/RefAddr/2/Encoding=String # replace [IDSREQ] with RMQ name for request queue. idsreq/RefAddr/3/Content=IDSREQ idsreq/RefAddr/3/Type=destinationName idsreq/RefAddr/3/Encoding=String idsres/ClassName=javax.jms.Queue idsres/FactoryName=com.rabbitmq.jms.admin.RMQObjectFactory idsres/RefAddr/0/Content=jms/Queue idsres/RefAddr/0/Type=name idsres/RefAddr/0/Encoding=String idsres/RefAddr/1/Content=javax.jms.Queue idsres/RefAddr/1/Type=type idsres/RefAddr/1/Encoding=String idsres/RefAddr/2/Content=com.rabbitmq.jms.admin.RMQObjectFactory idsres/RefAddr/2/Type=factory idsres/RefAddr/2/Encoding=String # replace [IDSRES] with RMQ name for result queue. idsres/RefAddr/3/Content=IDSRES idsres/RefAddr/3/Type=destinationName idsres/RefAddr/3/Encoding=String
I might be able to come back later and test with with EWPS, but I thought I'd get this here to help you out a bit.
-A
-
Ok, I was able to get this working.
Modify
ewps.config.xml
as shown below:<queuemanager> <entry name="queuefactory.class">com.docucorp.messaging.jms.DSIJMSJNDIMessageQueueFactory</entry> <entry name="ReceiveRequestIntervalMillis">30000</entry> <entry name="jms.initial.context.factory">weblogic.jndi.WLInitialContextFactory</entry> <entry name="jms.provider.URL">URL_TO_JMS_SERVER</entry> <entry name="jms.security.principal">JMS_USER</entry> <entry name="jms.security.credentials">JMS_PASS</entry> <entry name="jms.qcf.name">JNDI_QUEUE_CONNECTION_FACTORY_NAME</entry> <entry name="jms.inputqueue.connectstring">JNDI_RESULT_QUEUE_NAME</entry> <entry name="jms.outputqueue.connectstring">JNDI_REQUEST_QUEUE_NAME</entry> <entry name="jms.outputqueue.expiry">6000</entry> </queuemanager>
Comment out/remove any other settings from the block.
Replace the items in all caps with the necessary settings for your system. The items prefixed with JNDI_ will be resolved through a JNDI context lookup, which is done via the class named in the
jms.initial.context.factory
. In the above example, I'm using the WebLogic context factory to connect to a JMS server hosted in WebLogic. You will use the context factory appropriate for your JMS implementation. You may also use a context file, which is noted in my first comment above (create a .bindings file and set thejms.initial.context.factory
tocom.sun.jndi.fscontext.RefFSContextFactory
).Copy the content of the
<queuemanager>
block into the the<IDSProvider>
block, then save the file.Finally, make sure you place the appropriate JAR file that contains the
jms.initial.context.factory
class into the IDSlib
directory.