J2EE Spec for JMS Connection usage

I am trying to understand the rational behind the J2EE spec for using JMS that says that a connection within a container should have only one active session.
"... J2EE version 1.4 also requires that components in Web and EJB containers not create more than one active Session per connection."
This is in contrast to the original JMS doc:
"...A JMS client will normally create one Connection object to the JMS provider.
From this Connection, one or more Sessions will be created"
If anyone understands why the behavior should be different in using a Connection within a web container, pls elaborate.

J2EE1.4 requires a connection can have only one session. This has to do with the way JMS is built on JCA from 1.4.
Connection represents both connection and transactional context in JCA , however in JMS 'Session' represents a transactional context.
In J2EE 1.3 a connection can have multiple sessions.
Please look at following link for more details:
http://www-128.ibm.com/developerworks/blogs/dw_blog.jspa?roll=-4&blog=392

Similar Messages

  • Error while starting j2EE server for JMS program

    J2EEServer class doesnot find the class javax.naming.Context eventhough the classpath contains the jndi.jar file....I am using j2sdkee1.3 version and jndi version is 1.2.1...what could be the cause? can anyone help!

    Well I figured it out....there was a version conflict!

  • Does weblogic automatically pools Foreign JMS Connections ?

    I cofigured MQ Series connection factories and queues in my weblogic using Foreign JNDI provider feature.
    I am sending messages to MQ using common JMS approach
         public void sendMessage(List lnTransactionList) throws JMSException {
              XAQueueConnection conn = null;
              try {
                   conn = mqConnectionFactory.createXAQueueConnection("", "");
                   QueueSession session = conn.createQueueSession(false,
                             Session.AUTO_ACKNOWLEDGE);
                   TextMessage message = session.createTextMessage();
                   sender.send(message);
              } catch (JMSException ex) {
                   throw ex;
              } finally {
                   conn.close();
    I know that by default weblogic does some pooling for JMS connections and sessions.
    Does it work for third-party JMS Connections ?
    I checked class names for XAQueueConnection, QueueSession, Queue that weblogic returns for my MQ JNDI objects.
    All of them are from IBM libraries.
    So I think that default pooling doesn`t work in this case.

    Yes, third party pooling is supported and heavily leveraged. JMS resources are automatically pooled when a JMS connection factory is accessed via a standard EJB or Servlet "resource reference" (it is not enough simply to specify a foreign JMS server mapping). You can verify pooling is working by monitoring the stats on the foreign vendor itself, or by monitoring the pool Stats.
    Similar to WebLogic JDBC connection pools, pooled JMS resources still implement all of the public interfaces of a foreign vendor and redirect method invocations on these interfaces to the underlying class. This includes proprietary interfaces.
    Doc links:
    Pooling/Wrapping/Res-Refs:
    http://download.oracle.com/docs/cd/E15523_01/web.1111/e13727/j2ee.htm#g1329180
    FAQ entry on same:
    http://download.oracle.com/docs/cd/E15523_01/web.1111/e13727/interop.htm#i1009836
    Tom

  • JMS Adapter (for DI) does not allow passing username and password to JMS connection

    Post Author: PLed76
    CA Forum: Data Integration
    JMS Adapter (for DI) does not allow passing username and password to JMS connection. It has those fields only for MSMQ. Our Production environment does not allow us to connect to JMS (we use Tibco EMS) anonymously, so it prevents us from use of Data Integrator. Is there any way to pass those params, or obtain the correct version of JMS Adapter, or obtain source codes of the JMS Adapter so we can correct them ourselves (we can send you the corrected sources back) ? Thanks in advance for any help. (PL)ed76 Renaissance Capital

    Bump - Were having the same issue.
    Has anyone found a way to connect to Tibco with a user/pwd?
    Version 14.0.297.

  • When i try to submit an application with Application Loader, the wizard is blocked on "Send API itunes connect usage, waiting for response". Any idea ?

    When i try to submit an application with Application Loader, the wizard is blocked on "Send API itunes connect usage, waiting for response". Any idea ?

    Thank you, Vincent! It's still down for me, but at least I know someone had the same issue. Hoping it's going to work over here soon
    Best!

  • Javax.naming.NameNotFoundException for foreign JMS Connection factory

    I have a foreign jms server configured and when I try and test it I get a Name not found exception.
              javax.naming.NameNotFoundException: Unable to resolve 'jms.SSLQueueConnectionFactory' Resolved jms [Root exception is javax.naming.NameNotFoundException: Unable to resolve 'jms.SSLQueueConnectionFactory' Resolved jms]; remaining name 'SSLQueueConnectionFactory'
              The config.xml looks ok
              <ForeignJMSServer
              ConnectionURL="ssl://eaid1-jms.ges.symantec.com:7243"
              JNDIProperties="" Name="JMS Proxy Dev" Targets="TeamWorksServer">
              <ForeignJMSConnectionFactory
              LocalJNDIName="jms.SSLQueueConnectionFactory"
              Name="MyForeign JMS Connection Factory"
              PasswordEncrypted="{3DES}Es94ikW1TZzBFyDp+3/gktRtDaHWI6j/"
              RemoteJNDIName="SSLQueueConnectionFactory" Username="weblogicUser"/>
              <ForeignJMSDestination LocalJNDIName="jms.WEBLOGIC.TEST.QUEUE"
              Name="MyForeign JMS Destination" RemoteJNDIName="WEBLOGIC.TEST.QUEUE"/>
              </ForeignJMSServer>
              The code i took from the QueueSend example
              package com.symantec.utils.jms;
              import java.io.BufferedReader;
              import java.io.IOException;
              import java.io.InputStreamReader;
              import java.util.Hashtable;
              import javax.jms.*;
              import javax.naming.Context;
              import javax.naming.InitialContext;
              import javax.naming.NamingException;
              /** This example shows how to establish a connection
              * and send messages to the JMS queue. The classes in this
              * package operate on the same JMS queue. Run the classes together to
              * witness messages being sent and received, and to browse the queue
              * for messages. The class is used to send messages to the queue.
              * @author Copyright (c) 1999-2006 by BEA Systems, Inc. All Rights Reserved.
              public class QueueSend
              // Defines the JNDI context factory.
              public final static String JNDI_FACTORY="weblogic.jndi.WLInitialContextFactory";
              // Defines the JMS context factory.
              public final static String JMS_FACTORY="jms.SSLQueueConnectionFactory";
              // Defines the queue.
              public final static String QUEUE="WEBLOGIC.TEST.QUEUE";
              private QueueConnectionFactory qconFactory;
              private QueueConnection qcon;
              private QueueSession qsession;
              private QueueSender qsender;
              private Queue queue;
              private TextMessage msg;
              * Creates all the necessary objects for sending
              * messages to a JMS queue.
              * @param ctx JNDI initial context
              * @param queueName name of queue
              * @exception NamingException if operation cannot be performed
              * @exception JMSException if JMS fails to initialize due to internal error
              public void init(Context ctx, String queueName)
              throws NamingException, JMSException
              qconFactory = (QueueConnectionFactory) ctx.lookup(JMS_FACTORY);
              qcon = qconFactory.createQueueConnection();
              qsession = qcon.createQueueSession(false, Session.AUTO_ACKNOWLEDGE);
              queue = (Queue) ctx.lookup(queueName);
              qsender = qsession.createSender(queue);
              msg = qsession.createTextMessage();
              qcon.start();
              * Sends a message to a JMS queue.
              * @param message message to be sent
              * @exception JMSException if JMS fails to send message due to internal error
              public void send(String message) throws JMSException {
              msg.setText(message);
              qsender.send(msg);
              * Closes JMS objects.
              * @exception JMSException if JMS fails to close objects due to internal error
              public void close() throws JMSException {
              qsender.close();
              qsession.close();
              qcon.close();
              private static void readAndSend(QueueSend qs)throws IOException, JMSException
                   BufferedReader msgStream = new BufferedReader(new InputStreamReader(System.in));
              String line=null;
              boolean quitNow = false;
              do {
              System.out.print("Enter message (\"quit\" to quit): \n");
              line = msgStream.readLine();
              if (line != null && line.trim().length() != 0) {
              qs.send(line);
              System.out.println("JMS Message Sent: "+line+"\n");
              quitNow = line.equalsIgnoreCase("quit");
              } while (! quitNow);
              private static InitialContext getInitialContext(String url)
              throws NamingException
              Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY);
              env.put(Context.PROVIDER_URL, url);
              return new InitialContext(env);
              /** main() method.
              * @param args WebLogic Server URL
              * @exception Exception if operation fails
              public static void main(String[] args) throws Exception
              InitialContext ic = getInitialContext("t3://tus1bpmappdin01.ges.symantec.com:7501");
              QueueSend qs = new QueueSend();
              qs.init(ic, QUEUE);
              readAndSend(qs);
              qs.close();
              Any suggestions would be appreciated
              Regards

    I have a foreign jms server configured and when I try and test it I get a Name not found exception.
              javax.naming.NameNotFoundException: Unable to resolve 'jms.SSLQueueConnectionFactory' Resolved jms [Root exception is javax.naming.NameNotFoundException: Unable to resolve 'jms.SSLQueueConnectionFactory' Resolved jms]; remaining name 'SSLQueueConnectionFactory'
              The config.xml looks ok
              <ForeignJMSServer
              ConnectionURL="ssl://eaid1-jms.ges.symantec.com:7243"
              JNDIProperties="" Name="JMS Proxy Dev" Targets="TeamWorksServer">
              <ForeignJMSConnectionFactory
              LocalJNDIName="jms.SSLQueueConnectionFactory"
              Name="MyForeign JMS Connection Factory"
              PasswordEncrypted="{3DES}Es94ikW1TZzBFyDp+3/gktRtDaHWI6j/"
              RemoteJNDIName="SSLQueueConnectionFactory" Username="weblogicUser"/>
              <ForeignJMSDestination LocalJNDIName="jms.WEBLOGIC.TEST.QUEUE"
              Name="MyForeign JMS Destination" RemoteJNDIName="WEBLOGIC.TEST.QUEUE"/>
              </ForeignJMSServer>
              The code i took from the QueueSend example
              package com.symantec.utils.jms;
              import java.io.BufferedReader;
              import java.io.IOException;
              import java.io.InputStreamReader;
              import java.util.Hashtable;
              import javax.jms.*;
              import javax.naming.Context;
              import javax.naming.InitialContext;
              import javax.naming.NamingException;
              /** This example shows how to establish a connection
              * and send messages to the JMS queue. The classes in this
              * package operate on the same JMS queue. Run the classes together to
              * witness messages being sent and received, and to browse the queue
              * for messages. The class is used to send messages to the queue.
              * @author Copyright (c) 1999-2006 by BEA Systems, Inc. All Rights Reserved.
              public class QueueSend
              // Defines the JNDI context factory.
              public final static String JNDI_FACTORY="weblogic.jndi.WLInitialContextFactory";
              // Defines the JMS context factory.
              public final static String JMS_FACTORY="jms.SSLQueueConnectionFactory";
              // Defines the queue.
              public final static String QUEUE="WEBLOGIC.TEST.QUEUE";
              private QueueConnectionFactory qconFactory;
              private QueueConnection qcon;
              private QueueSession qsession;
              private QueueSender qsender;
              private Queue queue;
              private TextMessage msg;
              * Creates all the necessary objects for sending
              * messages to a JMS queue.
              * @param ctx JNDI initial context
              * @param queueName name of queue
              * @exception NamingException if operation cannot be performed
              * @exception JMSException if JMS fails to initialize due to internal error
              public void init(Context ctx, String queueName)
              throws NamingException, JMSException
              qconFactory = (QueueConnectionFactory) ctx.lookup(JMS_FACTORY);
              qcon = qconFactory.createQueueConnection();
              qsession = qcon.createQueueSession(false, Session.AUTO_ACKNOWLEDGE);
              queue = (Queue) ctx.lookup(queueName);
              qsender = qsession.createSender(queue);
              msg = qsession.createTextMessage();
              qcon.start();
              * Sends a message to a JMS queue.
              * @param message message to be sent
              * @exception JMSException if JMS fails to send message due to internal error
              public void send(String message) throws JMSException {
              msg.setText(message);
              qsender.send(msg);
              * Closes JMS objects.
              * @exception JMSException if JMS fails to close objects due to internal error
              public void close() throws JMSException {
              qsender.close();
              qsession.close();
              qcon.close();
              private static void readAndSend(QueueSend qs)throws IOException, JMSException
                   BufferedReader msgStream = new BufferedReader(new InputStreamReader(System.in));
              String line=null;
              boolean quitNow = false;
              do {
              System.out.print("Enter message (\"quit\" to quit): \n");
              line = msgStream.readLine();
              if (line != null && line.trim().length() != 0) {
              qs.send(line);
              System.out.println("JMS Message Sent: "+line+"\n");
              quitNow = line.equalsIgnoreCase("quit");
              } while (! quitNow);
              private static InitialContext getInitialContext(String url)
              throws NamingException
              Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, JNDI_FACTORY);
              env.put(Context.PROVIDER_URL, url);
              return new InitialContext(env);
              /** main() method.
              * @param args WebLogic Server URL
              * @exception Exception if operation fails
              public static void main(String[] args) throws Exception
              InitialContext ic = getInitialContext("t3://tus1bpmappdin01.ges.symantec.com:7501");
              QueueSend qs = new QueueSend();
              qs.init(ic, QUEUE);
              readAndSend(qs);
              qs.close();
              Any suggestions would be appreciated
              Regards

  • WLS 7.0.4 - JMS connection Factory for RMI queues - server affinity issues help pls

    We are using WLS 7.0.4 - One of JMS connection factory setting in admin
    console we selected "Server Affinity" options.
    We see this messages appear in Weblogic log file,
    ####<Apr 24, 2006 1:56:53 AM EDT> <Error> <Cluster>
    <liberatenode4.dc2.adelphia.com> <node4_svr> <ExecuteThrea
    d: '4' for queue: '__weblogic_admin_rmi_queue'> <kernel identity> <>
    <000123> <Conflict start: You tried to bi
    nd an object under the name sbetrmi2 in the JNDI tree. The object you have
    bound from liberatenode2.dc2.adelp
    hia.com is non clusterable and you have tried to bind more than once from
    two or more servers. Such objects ca
    n only deployed from one server.>
    and then,
    ####<Apr 24, 2006 1:58:12 AM EDT> <Error> <Cluster>
    <liberatenode5.dc2.adelphia.com> <node5_svr> <ExecuteThrea
    d: '7' for queue: '__weblogic_admin_rmi_queue'> <kernel identity> <>
    <000125> <Conflict Resolved: sbetrmi2 for
    the object from liberatenode5.dc2.adelphia.com under the bind name sbetrmi2
    in the JNDI tree.>
    Should we use 'load balancing option' instead of 'server affinity' ?
    Any thuoghts?
    Thanks in adv.
    Vijay

    Test Reply
              <Vijay Kumar> wrote in message news:[email protected]..
              > <b>WLS 7.0.4 - JMS Connection Factory - Server Affinity - issues in log
              > file</b>
              >
              > We are using WLS 7.0.4 - One of JMS connection factory setting in admin
              > console we selected "Server Affinity" options.
              >
              > We see this messages appear in Weblogic log file,
              > ####<Apr 24, 2006 1:56:53 AM EDT> <Error> <Cluster>
              > <liberatenode4.dc2.adelphia.com> <node4_svr> <ExecuteThrea
              > d: '4' for queue: '__weblogic_admin_rmi_queue'> <kernel identity> <>
              > <000123> <Conflict start: You tried to bi
              > nd an object under the name sbetrmi2 in the JNDI tree. The object you have
              > bound from liberatenode2.dc2.adelp
              > hia.com is non clusterable and you have tried to bind more than once from
              > two or more servers. Such objects ca
              > n only deployed from one server.>
              >
              > and then,
              > ####<Apr 24, 2006 1:58:12 AM EDT> <Error> <Cluster>
              > <liberatenode5.dc2.adelphia.com> <node5_svr> <ExecuteThrea
              > d: '7' for queue: '__weblogic_admin_rmi_queue'> <kernel identity> <>
              > <000125> <Conflict Resolved: sbetrmi2 for
              > the object from liberatenode5.dc2.adelphia.com under the bind name
              > sbetrmi2 in the JNDI tree.>
              >
              >
              > Should we use 'load balancing option' instead of 'server affinity' ?
              >
              > Any thuoghts?
              >
              > Thanks in adv.
              > Vijay

  • How to stop and start MDBs to listen for JMS messages

    Hello! This might be more of an architecture question rather than a technical questing, but I post it here, in the lack of a better place...
    For several years I have been using Webster and Webster MQ to send messages back and forth to clients. The architecture for the middleware platform has been designed around the functionality of ListenerPorts. Listenerports is a Webster functionality that let you "stop" and start to listen to JMS messages for a given MDB either by admin console, or by JMX.
    The arhitecture we used was something like this :
    1.Client sends a persistent message to a queue. (order)
    2. An MDB pics up the order message, calls a SessionBean that "fronts" the IIOP back end system.
    This is quite "out of the box" architecture, but we used the Listenerports to solve a stability problem for our back end system.
    The backEnd system was quite unstable, so the EJB threw an exception (typically because of timeout or connection refused) back to the MDB.
    The Listenerport was "defined" to handle 3 errors before stopping, so the MDB resent the message twice before the listenerport automatically stopped. The nice thing about this feature was that the client could continue to send orders, and was not bothered when the back end system was down.
    When the backEnd system was up and running, we could start the listenerport and it was all back to normal state. We even had a start script that checked the state of the listenerport every 30 minute, and started it automatically if it was stopped, making the admin task of starting the MDB unnecessary..
    Now.. Why am I telling this story..
    I would like to know how this could be done using "clean" J2EE technologies..That is..Not using any technology that is not portable..
    I`m playing with glassfish at home, and it struck me that there is nothing in the J2EE spec that defines the functionality described above ? Am i missing something ?
    I Do not want to stop My application because the back end system is down? That is the only way (i know of) that i can "stop" to listen for messages..
    I can put all the messages on an error queue when the backbend system is down, but that would lead to more code just to handle the error messages. Maybe the easiest way to solve this is to "move" (programmatically) all messages from the error queue over to the "standard" queue every XX minute, but somehow that sounds "wrong"
    Can anyone give me some advice to how this problem situation should be solved ? I`m interested in the solution both from an architectural perspective and from a more technical perspective..
    Best regards
    Hans-Jacob Melby

    Breakpoints, whether normal or conditional, are just meant for debugging of your code.  I had the sense from your question that the pausing you want to do is a part of normal operation of your code.  I would NOT recommend using a breakpoint for that situation.  It would bring up the block diagram showing the breakpoint when it occurs.  A user besides the programmer would not know what to do in that case.
     Yes, both the inner and outer loops would have shift registers.
    Putting a case structure with a small while loop inside the "Pausing Case" is doable.  It just depends on what you are doing or waiting for while the program operation is "paused".

  • How to reconnect in case of a JMS connection lost

    If JMS connection is lost during the exceution of the program, how to reconnect to the destination.
    please help me.
    thanks in advance.

    BTW, SJS MQ (The MQ with the J2EE Reference Implementation) also supports that.
    If you are using a queue, you should not loose messages. This is what the JMS spec is all about. If you are using a topic (message broadcast) then you would need to set the client as a durable subscriber, this way, if the client is not connected, the messages are kept for him to come back.
    Another point, if the connection is lost because the message broker went down, then all messages that were not consumed on that destination are lost, if they were not persisted.
    If the messages are persisted then you should have all the messages still available when you restart the broker and reconnect to it. Now since brokers try to be smart about persisting and minimise the disk I/O, you need to learn how the persistence of your broker works, and make sure you configure it to the performance/reliability balance you require for your application.
    TE

  • Is there any tutorial for jms development with jdeveloper out there ?

    Hi
    Thank you for reading my post
    is there any tutorial which show us how to use jdeveloper +oc4j for JMS stuff ?
    I mean an end 2 end tutorial to build mdb+jms resources in oc4j + client
    it will be far better if the tutorial shows how we can use jdeveloper features for this task (if it provide any wizard...)

    This is an example of a client:
    public String listeningJMS (Context context) throws Exception
    String topicName = "jms/demoTopic";
    String topicConnectionFactoryName = "jms/TopicConnectionFactory";
    TopicConnectionFactory topicConnectionFactory = null;
    TopicConnection topicConnection = null;
    TopicSession topicSession = null;
    Topic topic = null;
    TopicSubscriber topicSubscriber = null;
    TextMessage message = null;
    String fileName = null;
    * Look up connection factory and topic. If either does
    * not exist, exit.
    try
    topicConnectionFactory = (TopicConnectionFactory)
    context.lookup(topicConnectionFactoryName);
    topic = (Topic) context.lookup(topicName);
    * Create connection.
    * Create session from connection; false means session is
    * not transacted.
    * Create subscriber.
    * Register message listener (TextListener).
    * Receive text messages from topic.
    * When all messages have been received, enter Q to quit.
    * Close connection.
    topicConnection =
    topicConnectionFactory.createTopicConnection();
    topicSession =
    topicConnection.createTopicSession(false,
    Session.AUTO_ACKNOWLEDGE);
    topicSubscriber =
    topicSession.createSubscriber(topic);
    topicConnection.start();
    System.out.println("Receiving: ");
    TextMessage msg = (TextMessage) topicSubscriber.receive();
    String xmlString =msg.getText();
    topicConnection.close();
    System.err.println("Received: "+xmlString);
    fileName = this.getFileName(msg.getText());
    } catch (Exception e) {
    throw e;
    } finally {
    if (topicConnection != null) {
    try {
    topicConnection.close();
    } catch (JMSException e) {throw e;}
    return fileName;
    public static Context getInitialContext() throws NamingException {
    Hashtable env = new Hashtable();
    // Standalone OC4J connection details
    env.put( Context.INITIAL_CONTEXT_FACTORY, "oracle.j2ee.rmi.RMIInitialContextFactory" );
    env.put( Context.SECURITY_PRINCIPAL, "oc4jadmin" );
    env.put( Context.SECURITY_CREDENTIALS, "welcome1" );
    env.put(Context.PROVIDER_URL, "ormi://localhost:12401");
    //env.put(Context.PROVIDER_URL, "ormi://localhost:23791");
    return new InitialContext( env );
    }

  • Machine Specs for HCP Offerings

    When selecting the size of the machine the only option available is amount of memory and disk space.  There seems to be no option for processor speed and number of CPU's.  Anyone knows how many cores is available and what is the processor speed?
    Also when choosing the App Service is the Apps run on the same machine as the Database or on a different machine?  If on a different machine what are the specs for the machine the app is run on?

    Only work with 32bits
    SAP NetWeaver 7.0 Java Trial Version System Requirements
          Operating System: Windows 2000 (Service Pack 3); Windows XP Professional (Service Pack 1) or Windows Server 2003
          NTFS-File systems
          Internet Explorer 5.5 or higher or Firefox 1.0 or higher
          At least 1 GB RAM, 2 GB are recommended
          Intel Pentium III/1.1 GHz or higher (or compatible)
          14GB free hard disk space (8.6 GB for the installed software and 4.9 GB for the installer software)
          High-resolution monitor (1024x768 or higher, 256 colors)
          Sun Microsystems J2SE SDK version 1.4.2_XX or 1.4.2_XX (Sun JDK 1.5 not tested). You can download this from Sun Microsystems at http://java.sun.com/products/archive/j2se/1.4.2_XX/index.html. Please note that version 1.4.2_10 may cause installation problems.
          If you have already installed SAP products on your computer, you must ensure that none of the systems are called "J2E".
          The file C:\WINNT\system32\drivers\etc\services (Windows 2000) or C:\Windows\system32\drivers\etc\services (Windows XP) must not include an entry for the ports 3601, 3201 and 50000 to 50030. A possible entry can be excluded by using the hash symbol (#).
          If no DHCP server is available on your network (which dynamically determines the IP address) or your computer is not connected to any network, you need to install the virtual interface adapter MS Loopback Adapter. This is described in detail within the contents of the download package.
          To use SAP Interactive Forms by Adobe, you must install the necessary credential file and activatetial file and activate it using a unique password. Download the latest credential and password from SDN.
    check the points if i help you

  • Authorization for JMS resources

    Hi,
    consider the following use-case: we define a JMS topic to which certain, and only certain J2EE apps (probably running in different engines) should be allowed to report messages, but not for example a "malicious" standalone client. On the other side, clients should be allowed browse/read these messages without restrictions. In other words, distinct and selected producers, but broad audience of consumers.
    How could this be achieved best?
    In the online help I found a page suggesting to define a security policy. So I went to Visual Admin -> Security Provider -> Policy Configuration -> service.jms.default.authorization, selected "basic" as authentication method, removed group "Guest" from security role "clients" in "Security Roles", mapped it to a distinct user group (it's an UME user group to be precise, since my engine runs on an UME user store) and tried to publish a message to the topic --- to my surprise it worked! However, it shouldn't, since my client program does neither give user/password for the JNDI lockup nor for the creation of the topic connection.
    In fact, it does not matter how the "client" role is mapped to a user or group, my "malicious" standalone client always is able to post a message.
    What am I doing wrong?
    Best Regards
    Michael
    By the way: what exactly is the purpose of the user/password entries for factories and destinations in the JMS connector? The docu says it is for access to the JMS provider, but at least the SAP JMS provider seems not to make any use of them. Is this for access to third-party JMS providers?

    Hi
    Here are the steps you should make in version 6.40 :
    1. Create your own topic
    JMS Provider -> "Runtime" tab -> "JMS Server instances" border ("default") -> "Topics" tab -> "Create" button.
    Let's name this topic "MySecureTopic".
    2. Create a user which will have the permissions to produce messages to "MySecureTopic".
    Security Provider -> "Runtime" tab -> "User Management" tab -> "Create User" button.
    Let's name this user "secureproducer" with password "securepasswd". In my test I put this
    user in "Authenticated users" group, but maybe he can be in any other group.
    3. Now create new Security Role:
    Security Provider -> "Components" ("service.jms.default.authorization") -> "Runtime" tab -> "Policy Configuration" tab -> "Security Roles" tab -> "Security Roles" -> "Add" button.
    Note: in "service.jms.<b>default</b>.authorization" 'default' is the name of JMS instance (JMS Provider -> "Runtime" tab -> "JMS Server instances" border). If you use another instance, you should use the respective component ("service.jms.<b>another</b>.authorization").
    The name of my role is "SecureProdurerRole".
    Also add "secureproducer" user in this role :
    Select "SecureProdurerRole" and click on "Mappings" -> "Add" button.
    Security Provider -> "Runtime" tab -> "Policy Configuration" tab -> "Security Roles" tab -> "Mappings" border -> "Users" border -> "Add" button
    4. Now you should add a security rule that makes the required behaviour :
    Security Provider -> "Runtime" tab -> "Policy Configuration" tab -> "Resources" tab ->
            4.1. from "Resources" border choose "topic"
            4.2. from "Instances" border choose "MySecureTopic"
            4.3. from "Actions" border choose Action "produce"
            4.4. in "Granted" border should be only "SecureProdurerRole" and in "Denied" border - "administrators" and "clients" roles.
    Now in your Java code you must create your JMS connection with username and password provided:
    // this is the producer connection
    tc = tcf.createTopicConnection("secureproducer", "securepasswd");
    Otherwise using
    tc = tcf.createTopicConnection();
    this exception will occur :
    javax.jms.JMSSecurityException: You do not have permissions: action produce and instance MySecureTopic.
            at ...
    HTH
    Best regards

  • Sharing JMS connections among senders

              Is it wise for a web application to store connections to particular destinations
              in a static hashtable to reduce the number of createConnection operations, assuming
              the connections will only be used for send operations? Or would this prevent
              objects from being returned to the pool and cause threads to hang?
              

    Jason Taylor wrote:
              > Hey you're really great! I don't really expect anything on a Saturday but thanks!
              >
              > Is it possible that a connection could age out after a certain time and cause
              > things to hang? (please put your wls 6.1sp3 hat on for this one please, I'm still
              > a couple of revs back ;)
              Nothing hangs, but the connection can go bad for a variety
              of reasons (WL server failure, machine failure, network
              failure). But if anything goes wrong with the connection,
              the connection listeners optional onException handler is called.
              At this point, the connection can be automatically cleaned out
              of the pool. I think the sample code in the white-paper already
              does this.
              The built-in 8.1 pools take this one step farther - they eventually
              close JMS connections if they've gone idle for a while in order
              to conserve resources. Not a strong necessity with WL JMS,
              as such resources amount to no more than a bit of extra
              memory usage, unless perhaps the pool has pooled connections
              for many remote JMS servers.
              WL will kill idle network connections after a while - but I think this
              only applies to the iiop protocol, which JMS does not support
              until 8.1, not t3. I think idle http tunnelled connections may
              also get killed (in which onException would get called).
              The idle timeout is a configurable network setting on
              a per server basis. Post to the RMI newsgroup for details.
              >
              > Tom Barnes <[email protected]> wrote:
              >
              >>Hi Jason,
              >>
              >>Caching improves performance for high-throughput applications.
              >>So yes, it may be wise. You may also want
              >>to cache your producers, JNDI lookups, etc.
              >>
              >>As for the question about threads, unlike some other
              >>JMS implementations, WebLogic JMS does NOT create a thread per
              >>connection or per consumer. In fact, WL JMS could
              >>service a few thousand connections with just one or two
              >>threads in theory - but we do steal a few more than that
              >>for performance reasons, and laziness reasons
              >>(saves thinking about how to prevent thread starvation!).
              >>
              >>If you are thinking about caching, I suggest you look into
              >>two things:
              >>
              >>1) 8.1 contains built-in caching, check out the new features
              >>section for JMS in the release notes. (The use of ejb
              >>resource refs to access JMS will implicitly create a
              >>cache for you underneath, very cool - well I think
              >>its cool anyway.)
              >>
              >>2) If 8.1 caching is not sufficient, check out the example
              >>producer pool in the WL JMS Performance Guide. Regardless
              >>you may want to read it useful reading:
              >>
              >>http://dev2dev.bea.com/resourcelibrary/whitepapers/WL_JMS_Perform_GD.jsp
              >>
              >>Tom
              >>
              >>Jason Taylor wrote:
              >>
              >>>Is it wise for a web application to store connections to particular
              >>
              >>destinations
              >>
              >>>in a static hashtable to reduce the number of createConnection operations,
              >>
              >>assuming
              >>
              >>>the connections will only be used for send operations? Or would this
              >>
              >>prevent
              >>
              >>>objects from being returned to the pool and cause threads to hang?
              >>
              >
              

  • Weblogic jms connection problem

    Hi All,
    My jms bpel process listening on jms Queue. If I deploy bpel process first time I am not getting any jms connection problem with weblogic , but if redploy I am getting jms conneciton problem. saying
    Adapter_start: Jms Adapter started
    <2005-12-07 10:19:20,044> <ERROR> <default.collaxa.cube.activation> <JMSAdapter::Inbound> Error whil
    e creating managed connection:
    <2005-12-07 10:19:20,044> <ERROR> <default.collaxa.cube.activation> <JMSAdapter::Inbound>
    ORABPEL-12141
    ERRJMS_CONN_FAC_NOT_FOUND.
    Unable to instantiate connection factory. JMS adapter was unable to look up the connection factor BP
    ELJMS neither through JNDI nor instantiate it as a Java class
    Please examine the log file to determine the problem.
    at oracle.tip.adapter.jms.JMS.JMSConnectionFactoryFactory.getConnectionFactory(JMSConnection
    FactoryFactory.java:156)
    at oracle.tip.adapter.jms.JMS.JMSConnectionFactoryFactory.getQueueConnectionFactory(JMSConne
    ctionFactoryFactory.java:95)
    at oracle.tip.adapter.jms.JMS.JMSConnection.init(JMSConnection.java:143)
    at oracle.tip.adapter.jms.JMS.JMSConnection.<init>(JMSConnection.java:102)
    at oracle.tip.adapter.jms.JmsManagedConnectionFactory.createConnection(JmsManagedConnectionF
    actory.java:355)
    at oracle.tip.adapter.jms.JmsManagedConnectionFactory.createDefaultConnection(JmsManagedConn
    ectionFactory.java:346)
    at oracle.tip.adapter.jms.JmsManagedConnectionFactory.createConnection(JmsManagedConnectionF
    actory.java:309)
    at oracle.tip.adapter.jms.JmsManagedConnectionFactory.createManagedConnection(JmsManagedConn
    ectionFactory.java:99)
    at com.evermind.server.connector.ApplicationConnectionManager.createManagedConnection(Applic
    ationConnectionManager.java:564)
    at oracle.j2ee.connector.ConnectionPoolImpl.createManagedConnection(ConnectionPoolImpl.java:
    Work around is I need to restart the BPEL server.
    Is there any permanant solution for this, Please suggest.
    Thanks,
    Srini

    srini,
    see this thread
    JMS Connection
    thanks,
    -Ng.

  • Licensing for Unity Connection after Upgrade from 8.5 to 9.1.2

    I upgraded my Unity connection from 8.5.1 to 9.1.2. ( my CUCM is still on 8.5.1) . I have 200 CUWL-STD ( 2200 DLUs), and 50 CUWL-PRO (850 DLUs) . Now I am working with Cisco to get a license file for Unity Connection and apply that to my ELM. I attached my licensing page for when I was in 8.5.1 . Just want to make sure if I will be getting enough license with that license file, or possibly I need to buy more. Someone told me that if I want to have users with mailbox I need to order more licenses since every user take one CUWL license.
    Honestly i do not know how CUWL licensing work regardig to Unity or even CUCM.
    Thanks,

    Hi,
    The following link provides details of licenses usage by diff endpoints on version 9.x
    http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cucm/upgrade/uct/9_1_1/CUCM_BK_U0AE00F5_00_uct-admin-guide/CUCM_BK_U0AE00F5_00_uct-admin-guide_chapter_0100.html
    HTH
    Manish

Maybe you are looking for

  • SAP Java Connectivity Builder -NoClassDefFoundError com.sap.aii...Reference

    Hi there, I'm trying to generate Java Proxies for SAPJCO using the SAP Java Connectivity Builder (JCB). I got it from the NetWeaver 6.20 Release. The tool installs and runs properly but after putting in the connection properties and klicking "next",

  • New computer, downloaded a program and it now will not uninstall program

    I recently just bought this laptop and I downloaded Windows Office 365 proplus, (basically it says office 2013 version in all of the programs,)  package from my schools website for me to do school work.  I ran into an issue first with being able to l

  • How to make custom Metadata accessible in Text Template Editor ?

    Hi all. I used Lightroom SDK to create a plugin generating custom set of Metadata (for LR5) to manage images as produced items (printed and framed photos). In order to be able to create usefull lists of items, I would need to be able to print this me

  • EHP1 - Exponential cpu time per data packet

    Has anybody experienced this on a EHP1 system runnin glarge DTPs which have start routines which place large values inside of itabs - then these get read inside routines Not only are we seeing an exponential growth in the routines themselves but also

  • Video Import: Restriction on dimensions

    While trying to import some small (23x23) Quicktime movies to the library, I ran into the below error. "Your final video size must be at least 32x32 pixels." Do I need to re-process the movies so they are 32x32, or is there a work-around? Anyone know