11g SOA and ActiveMQ Foreign JMS Server?

Some how the message was added as a blank. Please delete this message from the forum. I couldn't see a way to do that.
user624946
Edited by: user624946 on Dec 7, 2010 8:28 AM

A late reply, but worthwhile as I hit this too
Active MQ client side also needs the osgi-3.0.1.jar, whcih I got from here
http://www.jarfinder.com/index.php/jars/versionInfo/70177

Similar Messages

  • Using ActiveMQ as JMS Server for 11g BPEL?

    I have 11g SOA and ActiveMQ 5.4.1 running on the same Linux server. I would like to configure SOA to be a client of the ActiveMQ server so my BPEL process can receive the JMS messages. I will need to use correlations to get the message to the right BPEL process. I'm not sure how the SOA service performs this task.
    We have several 10g BPEL applications that we need to port to the 11g install. They were originally written using Oracle's AQ. If someone knows of a document that could explain this transition, that would be a great help. Also, a document explaining how to configure SOA to be an ActiveMQ client would be of equal great help. I have searched the WEB and haven't found anything, but I have to think this is easier for the 11g WebLogic implementation.

    You can register any compliant JMS provider as a foreign jms provider in weblogic and then can access the JMS administered objects (destination and connection factory) from the local weblogic JNDI tree.
    This blog shows how to configure AQJMS as a foreign JMS provider and then configure JMS adapter to access the jms objects.
    http://biemond.blogspot.com/2009/07/using-aq-jms-text-message-in-wls-1031.html
    You can use the above link as a reference on how to setup. You will have to modify the Initial Context Factory, Provider URL, JNDI Properties, foregin connection factories and foreign detsinations section to suit activeMQ.
    Note: Weblogic does not come inbuild with the required jars to connect to ActiveMQ unlike AQJMS, so you need to ensure that the active mq jms client jars are available in the weblogic's classpath.

  • Load balancing MQ 7.0 Foreign JMS Server and Weblogic 10 MDBs?

    We have the following configuration and we are trying to troubleshoot what appears to be a load balancing issue.
    We have 3 Solaris servers. Each Solaris server has two Weblogic managed servers running on it. There are a total of 6 managed servers in the Weblogic cluster.
    MQ Series 7.0 is also installed on each Solaris server. The MQ queue managers are in a MQ cluster. Each queue manager has the same queues defined.
    We have a foreign JMS Server configured on Weblogic that has destinations and a connection factory defined. There aren't many configuration options available for the connection factory. The destinations are bound to the queues defined on MQ using the MQ bindings file.
    The MQ bindings file was generated using the TRANSPORT(BIND) mechanism. Each bindings file points to the queue manager running on that machine. So the 2 managed servers running on one machine are accepting messages from the queue manager on that machine.
    The MDB's listenning for messages on the MQ queues are configured as follows in the weblogic-ejb-jar.xml:
         <max-beans-in-free-pool>16</max-beans-in-free-pool>
    We also created a custom work manager with min threads constraint=5 and max threads constraint=16. The dispatch-policy of all the MDBs is set to the custom work manager.
    The open input count on each MQ queue managers shows up as 32 which is expected.
    The default load algorithm on the cluster is round-robin.
    When we run a load test (injecting 40 messages per second on one MQ queue), we notice that one managed server ends up being significantly loaded than the other. Each MQ queue manager in the MQ cluster receives approximately the same number of messages in the load test. But it seems like one managed server is preferred over the other in Weblogic.
    What can be done to equally balance the load among the two managed servers on each Solaris server?
    Thanks for the help.

    Load balancing generally applies at determing how many consumer threads has to be created on each of the clustered queue instance. In that sense you have achieved perfect load balancing as your queue instances has the same no of consumer threads.
    Once you have set 'x' consumer threads on a queue, it is upto messaging provider to decide which thread to deliver a particular message and you will hardly have any control over this. Since your 32 threads are listening on the same queue, MQ can select any thread for delivering the message and the behaviour could be non deterministic.
    One option to change your design is to have a dispacther mdb which picks the messages off the MQ and then routes to a weblogic distributed destination and you can have your core mdb which does all processing listen to this distributed destination. You can enable load balancing when the disaptcher mdb routes the message to the distributed destination. Since dispatcher MDB is nothing more than a router, the unbalanced consumption off the MQ shouldn't seriously affect the server.

  • WLS 11g, define foreign JMS server

    Hi,
    I want to define JMS server on my server A and set on this A JMS server foreign destination to the JMS server B.
    On server A i defined:
    - JMS server and set target
    - JMS modules (set subdeployment, Connection Factory, Uniform Distributed Queue, JNDI Name, subdeployment)
    And i dont know where can i set destination foreign JMS server ? I have to define:
    - at JMS server: JNDI Connection URL: t3://XXX.0.22.191:7004,
    - at factory: Remote JNDI Name: Jms.VI and user name
    - at destination: Remote JNDI Name: Jms.queue.NOTIFICATIONS
    can you help me?
    thanks

    http://docs.oracle.com/cd/E23943_01/apirefs.1111/e13952/taskhelp/jms_modules/foreign_servers/ConfigureForeignServers.html

  • ORA-25228 error occurs when Foreign JMS Server connecting to the Oracle AQ

    Hi,
    I configure of a Foreign JMS Server that uses the Oracle JDBC Driver to connect to the AQ Topic. I use OSB messaging proxy service as a JMS client to connect the Foreign JMS Server. After the launch, I get the following error:
    ####<Jan 30, 2013 4:51:49 AM MSK> <Error> <EJB> <EPRUSARW0520> <osb_server1> <RequestEJB7826682746890400115XX35047bed.13c85602eea.X7f53> <<anonymous>> <> <0000Jm8w2Es6qI_5xRh8iW1H1sMk0001sD> <1359507109078> <BEA-010079> <An error occurred while attempting to receive a message from JMS for processing by a message-driven bean: oracle.jms.AQjmsException: JMS-120: Dequeue failed
    Nested exception: java.sql.SQLException: ORA-00604: error occurred at recursive SQL level 1
    ORA-06502: PL/SQL: numeric or value error
    ORA-06512: at line 11
    ORA-25228: timeout or end-of-fetch during message dequeue from MDM.ALL_NSI
    The exception is : oracle.jms.AQjmsException: JMS-120: Dequeue failed
         at oracle.jms.AQjmsError.throwEx(AQjmsError.java:315)
         at oracle.jms.AQjmsConsumer.jdbcDequeue(AQjmsConsumer.java:1620)
         at oracle.jms.AQjmsConsumer.receiveFromAQ(AQjmsConsumer.java:1035)
         at oracle.jms.AQjmsConsumer.receiveFromAQ(AQjmsConsumer.java:960)
         at oracle.jms.AQjmsConsumer.receiveFromAQ(AQjmsConsumer.java:938)
         at oracle.jms.AQjmsConsumer.receive(AQjmsConsumer.java:790)
         at weblogic.deployment.jms.WrappedMessageConsumer.receive(WrappedMessageConsumer.java:201)
         at weblogic.ejb.container.internal.JMSMessagePoller$1.run(JMSMessagePoller.java:262)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
         at weblogic.ejb.container.internal.JMSConnectionPoller.doPrivilegedJMSAction(JMSConnectionPoller.java:2752)
         at weblogic.ejb.container.internal.JMSMessagePoller.processOneMessage(JMSMessagePoller.java:257)
         at weblogic.ejb.container.internal.JMSMessagePoller.pollContinuously(JMSMessagePoller.java:351)
         at weblogic.ejb.container.internal.JMSMessagePoller.pollForParent(JMSMessagePoller.java:483)
         at weblogic.ejb.container.internal.JMSMessagePoller.run(JMSMessagePoller.java:499)
         at java.lang.Thread.run(Thread.java:722)
    Caused by: java.sql.SQLException: ORA-00604: error occurred at recursive SQL level 1
    ORA-06502: PL/SQL: numeric or value error
    ORA-06512: at line 11
    ORA-25228: timeout or end-of-fetch during message dequeue from MDM.ALL_NSI
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:462)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:397)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:389)
         at oracle.jdbc.driver.T4Caqdq.processError(T4Caqdq.java:497)
         at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:481)
         at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:205)
         at oracle.jdbc.driver.T4Caqdq.doOAQDQ(T4Caqdq.java:183)
         at oracle.jdbc.driver.T4CConnection.doDequeue(T4CConnection.java:4704)
         at oracle.jdbc.driver.PhysicalConnection.dequeue(PhysicalConnection.java:17863)
         at oracle.jdbc.driver.PhysicalConnection.dequeue(PhysicalConnection.java:17949)
         at oracle.jdbc.OracleConnectionWrapper.dequeue(OracleConnectionWrapper.java:1624)
         at weblogic.jdbc.wrapper.XAConnection_oracle_jdbc_driver_LogicalConnection.dequeue(Unknown Source)
         at weblogic.jdbc.wrapper.JTAConnection_weblogic_jdbc_wrapper_XAConnection_oracle_jdbc_driver_LogicalConnection.dequeue(Unknown Source)
         at oracle.jms.AQjmsConsumer.jdbcConnectionDequeueCheck25242(AQjmsConsumer.java:1713)
         at oracle.jms.AQjmsConsumer.jdbcDequeue(AQjmsConsumer.java:1295)
         ... 13 moreHowever, when I put message to AQ topic, the OSB proxy receives and processes it. But SQLException occurs every five seconds and pollute logs.
    Request help to resolve this.
    Thanks in advance.
    Regards
    Alexander.

    Maybe this can help: http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::p11_question_id:4018285967344

  • Foreign JMS Server Limitation

    Hi all,
              Iam facing a limitation with Foreign JMS server.
              We are tyring to migrate from Message Bridge to Foreign JMS server.
              Our current setup is
              We have 3 MQ queues which are bridged to one JMS destination(queue).The MDB is consuming messages from the weblogic queue.
              If we want to replace this setup with Foreign JMS server the MDB can connect to only one MQ queue.
              We want the MDB to consume messages from all the 3 queues.
              How can we acheive this ?
              Thanks,
              Rabbani

    U should take my reply with a grain of salt because I'm pretty new at this stuff but I don't think it's within an MDBs design to listen to more than one queue/topic so therefore you'll have to create additional MDBs that either listen to each foreign queue individually and do whatever your single MDB is doing with the data now or create the n MDBS (where n = number of foreign queues currently bridgin to the one) that then publish to an intermediate topic which your existing MDB can listen to.
              Hope this helps, figure if I'm going to be pounding the boards with questions I should try to contribute where I can ;)
              And also, if you do setup the foreign JMS provider feel free to take a look at my topic and provide your experience if you think it will help :D

  • Foreign JMS Server - Weblogic 8.1 - Weblogic 8.1

    Hi
    I have to weblogic servers running on different ports.
    http://server1:port1
    http://server2:port2
    I have configured JMS store, JMS server, Destination (queue) in port2. I am able to send messages and retrieve messages in port2.
    I have written a MDB which was deployed in server1. I want to process the Messages posted to server2 destination. I tried to configure foreign JMS server in server1.
    In both servers, i am using default connection factories only.
    I am getting the following exceptions.
    ForeignMDB is unable to connect to the JMS destination: LocalTestingQueue
    LocalTestingQueue is the local jndi name given to the foreign destination.
    please find below the weblogic.xml entries for MDB
    <weblogic-enterprise-bean>
         <ejb-name>ForeignMDB</ejb-name>
         <message-driven-descriptor>           <destination-jndi-name>LocalTestingQueue</destination-jndi-name>           <initial-context-factory>weblogic.jndi.WLInitialContextFactory</initial-context-factory>
              <provider-url>http://myserver:26565</provider-url>          <connection-factory-jndi-name>weblogic.jms.ConnectionFactory</connection-factory-jndi-name>
         </message-driven-descriptor>
    </weblogic-enterprise-bean>
    could you please guide me to complete this?
    Thanks in advance
    Srinivas

    1 - Ensure that the MDB is configured to reference the remote connection factory AND remote destination.
    2 - If using the foreign JMS server facility, ensure that it defines the URL of the remote cluster/server, a connection factory mapping, and a destination mapping. Also ensure that the MDB connection factory and destination descriptor fields reference the local JNDI names for the mappings.
    3 - If not using the foreign JMS server facility, ensure that the MDB descriptor has the URL of the remote cluster, and a destination JNDI name that's in the remote cluster. (The connection factory JNDI name is not needed in this case, as the MDB will automatically look for a default connection factory that MDB's use.)
    I think the MDB chapter of the EJB programmer's guide will likely be helpful here. The latest documentation for the latest release may be more up-to-date than 8.1 -- the concepts are the same with the newer releases.
    Tom

  • Foreign JMS server connection issue.

    Hi All,
    We are migrating a JMS application from websphere 6.1 to weblogic 10.3. The message queue resides in a TIBCO EMS server.
    We are trying to configure the foreign JMS server through JMS Module in the admin console. We are getting the following error will deploying the application.
    +<May 4, 2009 12:32:52 AM PDT> <Warning> <EJB> <BEA-010061> <The Message-Driven EJB: TxnMessageSubscriber is unable to connect to the JMS destination: weblogic.bbmdb-txn.jms/system+
    module-0-jms.xml. The Error was:
    Can not get distribute destination information. The destination JNDI name is weblogic.bbmdb-txn.jms/systemmodule-0-jms.xml, the provider URL is null>
    we have provided the connection URL in "JNDI Connection URL" column in the foreign server setup page.
    Is there any other thing that need to be configured?

    I m facing the same problem, we are using Weblogic Server 10.3.
    We have defined a cluster on one Weblogic server and have created one managed server in the cluster machine and the other managed server in another machine.
    We are using Foreign JMS and I m getting the error as follow:
    ####<Jun 19, 2009 3:30:53 PM IST> <Warning> <EJB> <iflexpkw513> <Managed1> <[STANDBY] ExecuteThread: '3' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1245405653881> <BEA-010061> <The Message-Driven EJB: TestJMSALSB is unable to connect to the JMS destination: fcssi/FCSSI. The Error was:
    Can not get distribute destination information. The destination JNDI name is fcssi/FCSSI, the provider URL is null>
    Not able to understand what is the problem here...
    ejb-jar.xml :
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar id="ejb-jar_ID">
    <enterprise-beans>
    <message-driven>
    <ejb-name>TestJMSALSB</ejb-name>
    <ejb-class>samplemdb.TestJMSALSB</ejb-class>
    <transaction-type>Container</transaction-type>
    <message-driven-destination id="MessageDrivenDestination_1169302343246">
         <destination-type>javax.jms.Queue</destination-type>
    </message-driven-destination>
    </message-driven>
    </enterprise-beans>
    </ejb-jar>
    weblogic-ejb-jar.xml :
    <?xml version="1.0" encoding="UTF-8"?>
    <weblogic-ejb-jar
    xmlns="http://www.bea.com/ns/weblogic/90" xmlns:j2ee="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.bea.com/ns/weblogic/90 http://www.bea.com/ns/weblogic/90/weblogic-ejb-jar.xsd">
    <weblogic-enterprise-bean>
    <ejb-name>TestJMSALSB</ejb-name>
    <message-driven-descriptor>
    <destination-jndi-name>fcssi/FCSSI</destination-jndi-name>
    <connection-factory-jndi-name>iflex/fcssiQCF</connection-factory-jndi-name>
    </message-driven-descriptor>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    Can anyone provide some help on this.....

  • MDB for Foreign JMS server

    I am trying to access MQ que with Message Driven bean in weblogic 8.1.
              I have defined Foreign JMS server in weblogic pointing to MQ JNDI name.
              I am not sure what to define in "weblogic-ejb-jar.xml" and "ejb-jar.xml" to refer to que connection factory and que.
              Error message that I am getting while deploying is as follows:
              <The Message-Driven EJB: MesssageHandlerBean is unable to connect to the JMS destination: jms.MediaQueue. The Error was:
              [EJB:011010]The JMS destination with the JNDI name: jms.MediaQueue could not be found. Please ensure that the JNDI name in the weblogic-ejb-jar.xml is correct, and the JMS destination has been deployed.>
              Looks like it weblogic is not able to identify JNDI name that I have defined in foreign server for remote que.
              Please let me know how i can reference foreign JMS server JNDI names.
              Thanks a bunch for help.
              Please find attached configuration files.
              weblogic-ejb-jar.xml
              <weblogic-ejb-jar>
              <weblogic-enterprise-bean>
              <ejb-name>MesssageHandlerBean</ejb-name>
              <message-driven-descriptor>
              <destination-jndi-name>
              jms.MediaQueue
              </destination-jndi-name>
              <initial-context-factory>
              com.sun.jndi.fscontext.RefFSContextFactory
              </initial-context-factory>
              <provider-url>file://localhost/d:/mqm</provider-url>
              <connection-factory-jndi-name>
              jms.MediaQcf
              </connection-factory-jndi-name>
              </message-driven-descriptor>
              <jndi-name>MesssageHandlerBean</jndi-name>
              </weblogic-enterprise-bean>
              </weblogic-ejb-jar>
              ejb-jar.xml
              <enterprise-beans>      
              <message-driven>
              <ejb-name>MesssageHandlerBean</ejb-name>
              <ejb-class>com.ejb.MesssageHandlerBean</ejb-class>
              <transaction-type>Container</transaction-type>
              <message-driven-destination>
              <destination-type>javax.jms.Queue</destination-type>
              </message-driven-destination>
              </message-driven>
              </enterprise-beans>
              weblogic "config.xml" for foeign JMS server.
              <ForeignJMSServer ConnectionURL="file://localhost/d:/mqm" InitialContextFactory="com.sun.jndi.fscontext.RefFSContextFactory"
              JNDIProperties="" Name="MQJMS Server" Targets="cgServer">
              <ForeignJMSConnectionFactory LocalJNDIName="jms.MediaQcf"
              Name="MQ JMS Connection Factory" PasswordEncrypted=""
              RemoteJNDIName="jms/lMediaQcf" Username=""/>
              <ForeignJMSDestination LocalJNDIName="jms.MediaQueue"
              Name="MQJMS Destination" RemoteJNDIName="jms/IMediaQueue"/>
              </ForeignJMSServer>
              Message was edited by:
              [email protected]
              Message was edited by:
              [email protected]

    Thanks for going over the problem it is resolved now by changing weblogic-ejb-jar.xml. To point to weblogic initial context factory. Since weblogic has a foreign server defined so MDB is able to read from MQ que.
              Thanks
              Akash
              <weblogic-enterprise-bean> <ejb-name>MesssageHandlerBean</ejb-name> <message-driven-descriptor> <destination-jndi-name>jms.MediaQueue</destination-jndi-name> <initial-context-factory> weblogic.jndi.WLInitialContextFactory</initial-context-factory> <provider-url>t3://localhost:7001</provider-url> <connection-factory-jndi-name>jms.MediaQcf</connection-factory-jndi-name> </message-driven-descriptor> <jndi-name>MesssageHandlerBean</jndi-name> </weblogic-enterprise-bean>

  • Foreign JMS Server Persistance\Retry in case Remote JMS Provider goes down

    Hi All
    I would need more clarity on this. How does the Foreign JMS Server behave in case the remote JMS provider goes down. Does it take the message from the Publishing Proxy Service and retries\persists the JMS Message till the remote provide is up?
    Please let us know. This would effect our design as retrial is very important here. Thanks

    If you want to provide guaranteed delivery with automatic retries when using remote JMS implementations, there are multiple ways to implement it:
    1. While reading from a foreign JMS destination
    Create a Foreign JMS server using transactional drivers (use XA in case of JMS). The messages remain on remote server JMS queue and OSB proxy polls the message directly on remote server. So if Remote Server is down OSB will not be able to read the message. Once remote server is up OSB will pick up the message (as long as foreign JMS server provides persistence and maintains the messages in the queue during a server restart). In case of error in OSB foreign queue can do retry if it provides a retry mechanism.
    2. While writing the message to a foreign JMS destination
    a. Use a foreign JMS server using transactional connection. Put the retry mechanism in OSB Business service which writes to the foreign JMS/MQ queue. In case of failure Business Service can retry based on configuration. If you want to provide guaranteed delivery then create a local JMS queue to store the messages. So when remote destination is down for a long time undelivered messages will be rolled back to the local queue. You can put retry mechanism on the local queue.
    b. Use a messaging bridge which will write the messages to the remote destination. You can configure retry delivery rules in messaging bridge so once busienss service writes the message to the bridge, a SAF agent will ensure the delivery to remote destination whenever it is up.

  • Foreign JMS Server vs Messaging bridge

    Could any body tell me which one is the best Whether Foreign JMS Server or Messaging bridge for connecting Weblogic to IBM MQ Series.I am trying to use foreign jms server but i dont know how to post the message to that queue i created in foreign jms server..

    Hi,
              For sending messages non-transactionally, foreign JMS server is sufficient. For sending messages transactionally using standard JTA transactions, the simplest way is to send them on the server and reference the foreign JMS through an EJB resource reference. See the the following FAQ for a walk-through of the various options, including guidance on when to use a bridge:
              http://e-docs.bea.com/wls/docs81/faq/interop.html
              Tom

  • Error occurred when use foreign Jms server[JMSClientExceptions:055142].

    I want to use a foreign Jms server(Tibco EMS), after I have config the JNDI of foreign server,connectionfactory and destinations, the correct JNDI name can be find on the JNDI tree.
    Then I deploy a demo mdb ear on the weblogic(version is 10.3),there's warnning tag on the ear application, and there is error message in the log:
    <2011-1-10 上午10时15分07秒 CST> <Warning> <EJB> <BEA-010061> <The Message-Drive
    n EJB: MDBDemo is unable to connect to the JMS destination: NotifyAlertAlertQueue. The Error was:
    weblogic.jms.common.InvalidDestinationException: [JMSClientExceptions:055142]Foreign destination, Queue[notify.alert.alertQueue]>
    NotifyAlertAlertQueue is the JNDI name of the destination defined on the weblogic console,and the same as ems jndi name for queue notify.alert.alertQueue.
    It seems that the application has find the queue correctly, but why it throw that exception[JMSClientExceptions:055142]?
    Thanks for any help.
    Edited by: 826761 on 2011-1-9 下午6:40

    I suspect that somehow your configuration is messed up and the MDB ended up using a WebLogic connection to access a TIBCO EMS destination.
    Please make sure that your JMS server configuration maps a TIBCO connection factory jndi name to a jndi name in WebLogic server JNDI tree, a TIBCO destination jndi name to a jndi name in WebLogic server JNDI tree, and your MDB configuration refers to the jndi names in the WebLogic JNDI tree.
    Regards.

  • Messaging Bridge/Foreign JMS Server

    Can someone clarify what is the difference in using messaging bridge or Foreign JMS Server in listening to a topic from other weblogic server of same version.
    Edited by: user11359157 on 6 Jul, 2009 3:17 PM

    I always thought one has to use remote classes from the foreign JMS server in local the classpath to send or receive messages stored at
    the foreign JMS server / the remote side.
    <Jayesh> that is true of the remote side of the JMS is non-weblogic. </Jayesh>
    Also in the WLS bridge this can be specified. IMHO the bridge has the advantage that I can use the wls classe and the bridge knows
    the classpath and bridges to the foreign jms server, so the application developer doesn't have to use foreign classes, eg. tibco or mq.
    <Jayesh> When you have remote JMS is WebLogic it is obvious considering that both remote and local jms uses same weblogic classes. </Jayesh>
    Now, where does this happen for the foreign jms server (which is kind of alternative to wls bridge, without store and forward)?
    All I can see is a local JNDI lookup being translated to a remote one.
    Is really the local JMS implementation used to talk to the remote JMS server?
    When a JNDI lookup for a queue happens will then be WLS queue implementation returned?
    <Jayesh> No there is not local JMS store is used. Foreign JMS server just provides administrative convenience by moving remote JMS destination JNDI definitions in local JNDI definition. It allows to use this local definition by all EJBs, servlets and messaging bridges. If the remote definitions changes you can change those definition in admin console and does not need change in deployment descriptors of the EJBs and servlets to prevent redeployment. Again this is no administrative convenience and during run time it will behave exactly same as you are sending or receiving message directly from remote JMS destination.
    </Jayesh>
    Hope this clears confusion.
    jayesh@yagna

  • Do I need a Foreign JMS Server?

              Initially, I had an exploded web application, an ejb jar, a jms server, a connection
              factory and a queue all deployed under one weblogic instance. I am now trying
              to move the jms configuration to another machine running weblogic. However, I
              am unsure whether I need to configure a Foreign JMS Server on the initial weblogic
              instance. I have tried to do so and I cannot successfully start the connection
              from my web/ejb app (i.e., myQueueConnection.start() throws an exception - weblogic.jms.common.JMSException:
              Connection not found).
              I saw a thread here about changing the names of the JMS Servers, so I configured
              my web server with a foreign jms server (ForeignMessageServer) and I configured
              one foreign connection factory and one foreign destination. The local jndi names
              of these are unique and different from the remote jndi name. The remote jndi names
              match the names of the connection/destination on the app server (my 2nd server).
              I am using the url of the web server as my provider url and the foreign connection
              factory local jndi name to look up the connection.
              I have two questions:
              Is it necessary to use a foreign jms server configuration to implement this structure?
              If a foreign jms server configuration is necessary, am I going about this correctly?
              Thanks,
              John
              

    It certainly will work. Basically, all it does is move information like the
              JNDI provider name and URL from your deployment descriptors into config.xml.
              For a lot of applications, that's a big help. You can use the "Foreign JMS
              Provider" support anywhere you want to create a JNDI entry on your local
              server that points to something else. You can even use it to point to a JMS
              queue, topic, or connection factory in the same cluster, or the same WLS
              server if you want. I do this for testing so I don't have to have different
              versions of my EJB for different environments.
              As for the bridge, it depends on whether you need to interact with the JMS
              provider synchronously or asynchronously. When you use the bridge, you first
              put the message on one JMS queue or topic, and the bridge copies it to the
              other. So, if the foreign provider is down, you can still send messages.
              However, using the bridge adds an extra "hop" which will slow performance.
              greg
              <[email protected]> wrote in message news:[email protected]...
              > Hi Tom,
              >
              > If I have 2 WLS servers: server1 and server2 and they are NOT in the same
              > cluster. server1 wants to send a JMS message to server2. I know I can
              > achieve the desired result using your 3 suggestions below but would
              using
              > foreign JMS server works as well? When should I use foreign JMS server
              > instead of a messaging bridge?
              >
              > Thanks,
              >
              > Vincent
              >
              >
              >
              > "Tom Barnes" <[email protected]> wrote in message
              > news:[email protected]...
              > > If both weblogic servers participate in the same cluster
              > > there is no additional configuration needed.
              > > All servers in cluster share the same JNDI
              > > name space. Simply specifying a JNDI name
              > > (as you already must have done) is enough
              > > for any server in the cluster, or any client connected
              > > to the cluster, to find a JNDI resource that is hosted
              > > on any server in the cluster (such as queue).
              > > This location transparency is one of the primary
              > > benefits of using clusters.
              > >
              > > If the MDB is in a different cluster than its
              > > source destination, then you have three choices
              > > (1) Change the MDB weblogic descriptor to specify
              > > a URL that resolves to any one of the
              > > addresses of a WL server in the remote cluster.
              > > I don't recall the name of the URL field,
              > > but it is in the weblogic descriptor, and
              > > is documented in the EJB (MDB) programmer's
              > > guide.
              > > (2) Configure wrappers that refer to the
              > > remote JMS resources in the cluster, and change
              > > the MDB descriptors to point to the jndi
              > > locations you configured for the wrapped
              > > connection factory and wrapped destination.
              > > (3) Configure a messaging bridge that
              > > moves from the remote destination to
              > > a local destination (which, in turn,
              > > the MDB consumes from).
              > >
              > > Tom
              > >
              > > John Owen wrote:
              > >
              > > > Initially, I had an exploded web application, an ejb jar, a jms
              server,
              > a connection
              > > > factory and a queue all deployed under one weblogic instance. I am now
              > trying
              > > > to move the jms configuration to another machine running weblogic.
              > However, I
              > > > am unsure whether I need to configure a Foreign JMS Server on the
              > initial weblogic
              > > > instance. I have tried to do so and I cannot successfully start the
              > connection
              > > > from my web/ejb app (i.e., myQueueConnection.start() throws an
              > exception - weblogic.jms.common.JMSException:
              > > > Connection not found).
              > > >
              > > > I saw a thread here about changing the names of the JMS Servers, so I
              > configured
              > > > my web server with a foreign jms server (ForeignMessageServer) and I
              > configured
              > > > one foreign connection factory and one foreign destination. The local
              > jndi names
              > > > of these are unique and different from the remote jndi name. The
              remote
              > jndi names
              > > > match the names of the connection/destination on the app server (my
              2nd
              > server).
              > > > I am using the url of the web server as my provider url and the
              foreign
              > connection
              > > > factory local jndi name to look up the connection.
              > > >
              > > > I have two questions:
              > > >
              > > > Is it necessary to use a foreign jms server configuration to implement
              > this structure?
              > > > If a foreign jms server configuration is necessary, am I going about
              > this correctly?
              > > >
              > > > Thanks,
              > > > John
              > >
              >
              >
              

  • MDB connecting to Foreign JMS server in WL8.1

    Hello,
              I have this problem that I am hoping someone can help me with. There is a
              MDB deployed in a local WL8.1 that is trying to connect to a Foreign JMS
              Server which is also a WL8.1 running in a remote server. This MDB is
              attempting to subscribe to a topic hosted by that foreign server. In the
              local WL8.1 I created a Foreign JMS Server via the adminconsole and mapped
              the connection factory as well as destinations to the Foreign JMS Server.
              The MDB (via its deployment descriptor) only refers to the local JNDI names
              of the ConnectionFactory and Topic. Here are the scenarios concerning
              security:
              1) When security is turned off (user is in group everyone) everything works
              fine. Messages published to the foreign Topic are received by the MDB in
              the local WL8.1 server and processed.
              2) When a security policy is applied to the Topic (via the remote
              adminconsole), the MDB in the local server gets a 'permission denied'. I
              now have to get around this by defining a principle for the MDB to run as
              and to map the credentials of this principle to that of the user in the
              remote environment with access permissions to the Topic.
              3) When I specify the security identity of my MDB, its JNDI lookup of the
              Topic fails with 'not found'.
              4) Even when the security policy in the remote server is reverted back to
              'everyone' (effectively turning security off) but leaving the MDB running as
              the security principle, it still cannot find the Topic.
              I hope this is something that people have seen and dealt with before.
              Thanks for any and all help anyone can provide. I have also included the
              deployment descriptors for this MDB:
              <ejb-jar>
              <enterprise-beans>
              <message-driven>
              <ejb-name>MDB</ejb-name>
              <ejb-class>sample.class.MDB</ejb-class>
              <transaction-type>Container</transaction-type>
              <message-driven-destination>
              <destination-type>javax.jms.Topic</destination-type>
              </message-driven-destination>
              <security-identity>
              <run-as>
              <role-name>OutsideJMSUser</role-name>
              </run-as>
              </security-identity>
              </message-driven>
              </enterprise-beans>
              <assembly-descriptor>
              <security-role>
              <role-name>OutsideJMSUser</role-name>
              </security-role>
              </assembly-descriptor>
              </ejb-jar>
              <weblogic-ejb-jar>
              <weblogic-enterprise-bean>
              <ejb-name>MDB</ejb-name>
              <message-driven-descriptor>
              <pool>
              <initial-beans-in-free-pool>1</initial-beans-in-free-pool>
              </pool>
              <destination-jndi-name>ForeignTopic</destination-jndi-name>
              <connection-factory-jndi-name>ForeignConnectionFactory</connection-factory-j
              ndi-name>
              </message-driven-descriptor>
              <jndi-name>MDB</jndi-name>
              </weblogic-enterprise-bean>
              <security-role-assignment>
              <role-name>OutsideJMSUser</role-name>
              <principal-name>OutsideJMSUser</principal-name>
              </security-role-assignment>
              </weblogic-ejb-jar>
              

    Thanks for the suggestion Greg. I have enabled trust between the two
              domains and that has certainly cut down the variations of SecurityExceptions
              that I get. Now I am consistently only getting a JMSSecurityException with
              a access denied to the topic. I believe I have the credential mapped
              correctly between the run-as local user and the remote authorized user.
              Unfortunately the exception does not specify what username was rejected, it
              would have been useful in determining the next debugging step to take.
              I think you're right, I should engage the security forum for this. Thanks
              again for the help.
              "Greg Brail" <[email protected]> wrote in message
              news:[email protected]...
              > Hmm. The security people (on weblogic.developer.interest.security) might
              > have to help you here, too. When you set the "runAs" identity for the MDB,
              > it's doing everything, including the JNDI lookup, under that identity. So
              if
              > that identity is one that's recognized by the remote domain, then you
              should
              > be OK. One way to make your local identity recognized by the remote domain
              > is to make your domains trusted, but you may wish not to do that.
              >
              > greg
              >
              > "Steve Chan" <[email protected]> wrote in message
              > news:[email protected]...
              > > Hello,
              > >
              > > I have this problem that I am hoping someone can help me with. There is
              a
              > > MDB deployed in a local WL8.1 that is trying to connect to a Foreign JMS
              > > Server which is also a WL8.1 running in a remote server. This MDB is
              > > attempting to subscribe to a topic hosted by that foreign server. In
              the
              > > local WL8.1 I created a Foreign JMS Server via the adminconsole and
              mapped
              > > the connection factory as well as destinations to the Foreign JMS
              Server.
              > > The MDB (via its deployment descriptor) only refers to the local JNDI
              > names
              > > of the ConnectionFactory and Topic. Here are the scenarios concerning
              > > security:
              > >
              > > 1) When security is turned off (user is in group everyone) everything
              > works
              > > fine. Messages published to the foreign Topic are received by the MDB
              in
              > > the local WL8.1 server and processed.
              > >
              > > 2) When a security policy is applied to the Topic (via the remote
              > > adminconsole), the MDB in the local server gets a 'permission denied'.
              I
              > > now have to get around this by defining a principle for the MDB to run
              as
              > > and to map the credentials of this principle to that of the user in the
              > > remote environment with access permissions to the Topic.
              > >
              > > 3) When I specify the security identity of my MDB, its JNDI lookup of
              the
              > > Topic fails with 'not found'.
              > >
              > > 4) Even when the security policy in the remote server is reverted back
              to
              > > 'everyone' (effectively turning security off) but leaving the MDB
              running
              > as
              > > the security principle, it still cannot find the Topic.
              > >
              > > I hope this is something that people have seen and dealt with before.
              > > Thanks for any and all help anyone can provide. I have also included
              the
              > > deployment descriptors for this MDB:
              > >
              > > <ejb-jar>
              > > <enterprise-beans>
              > > <message-driven>
              > > <ejb-name>MDB</ejb-name>
              > > <ejb-class>sample.class.MDB</ejb-class>
              > > <transaction-type>Container</transaction-type>
              > > <message-driven-destination>
              > > <destination-type>javax.jms.Topic</destination-type>
              > > </message-driven-destination>
              > > <security-identity>
              > > <run-as>
              > > <role-name>OutsideJMSUser</role-name>
              > > </run-as>
              > > </security-identity>
              > > </message-driven>
              > > </enterprise-beans>
              > >
              > > <assembly-descriptor>
              > > <security-role>
              > > <role-name>OutsideJMSUser</role-name>
              > > </security-role>
              > > </assembly-descriptor>
              > >
              > > </ejb-jar>
              > >
              > > <weblogic-ejb-jar>
              > > <weblogic-enterprise-bean>
              > > <ejb-name>MDB</ejb-name>
              > > <message-driven-descriptor>
              > > <pool>
              > > <initial-beans-in-free-pool>1</initial-beans-in-free-pool>
              > > </pool>
              > > <destination-jndi-name>ForeignTopic</destination-jndi-name>
              > >
              > >
              >
              <connection-factory-jndi-name>ForeignConnectionFactory</connection-factory-j
              > > ndi-name>
              > > </message-driven-descriptor>
              > > <jndi-name>MDB</jndi-name>
              > > </weblogic-enterprise-bean>
              > >
              > > <security-role-assignment>
              > > <role-name>OutsideJMSUser</role-name>
              > > <principal-name>OutsideJMSUser</principal-name>
              > > </security-role-assignment>
              > >
              > > </weblogic-ejb-jar>
              > >
              > >
              >
              >
              

Maybe you are looking for