[Design of JBoss ESB] - Re: JmsConnectionPool: Allowing control over the number of S
by tfennelly
So we went for a less intrusive implementation of this. Originally I was working on creating a new JmsSessionPool class and in it, collapsing those 4 Maps down to just a single Map and eliminating all the juggling of sessions between Maps. We decided not to do this at this point, so I then went back and just extended the existing "patterns" inside JmsConnectionPool to accommodate multiple connections.
So what we have right now (working - full CI build) is the old JmsConnectionPool with:
1. An inner JmsSessionPool class for managing sessions associated with a single connection. It basically contains code moved down from the JmsConnectionPool class.
2. The JmsConnectionPool has exactly the same interface as before. It now manages a list of JmsSessionPool objects (List). It gets a session by looping over the session pool list, asking each session pool for a session. If non of the existing pools have a free session, it will create a new connection and add a new session pool for that connection (if it hasn't hit "maxConnections").
"maxConnections" (i.e. max number of session pools) is currently calculated based on the existing "org.jboss.soa.esb.jms.connectionPool" config from the jbossesb-properties.xml file (which is actually the max total number of sessions for the whole connection pool), as well as a new config param called "max-sessions-per-connection", which is currently coming from the "poolKey" (i.e. jndiEnv) used to create the JmsConnectionPool.
So maxConnections = (maxSessions/maxSessionsPerConnection);
This is not quite right though. I don't think we can take maxSessionsPerConnection from the poolKey because of how the JmsConnectionPoolContainer works. Seems to me like this setting also needs to come from the jbossesb-properties.xml file, but we would need to have a setting per JMS Provider. We could base this on the initial context factory class name e.g.:
<property name="org.jboss.soa.esb.jms.max.sessions.per.connection_com.ibm.mq.jms.context.WMQInitialContextFactory" value="1" />
This is not ideal either because I think you may need a different value for max.sessions.per.connection on the same provider, depending on other params e.g. whether or not the connections are XA (ala this forum topic).
Not pretty :)
Options and opinions?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4231293#4231293
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4231293
16 years, 10 months
[Design of JBoss jBPM] - Re: values in example.identities.sql for JBPM4_ID_USER do no
by tom.baeyens@jboss.com
now i got it!
i fixed it like this:
INSERT INTO JBPM4_ID_GROUP VALUES (1,0,'manager','manager','security-role',NULL);
| INSERT INTO JBPM4_ID_GROUP VALUES (2,0,'administrator','administrator','security-role',NULL);
| INSERT INTO JBPM4_ID_GROUP VALUES (3,0,'user','user','security-role',NULL);
| INSERT INTO JBPM4_ID_GROUP VALUES(4,0,'sales','sales',NULL,NULL);
|
| INSERT INTO JBPM4_ID_USER VALUES (1,0,'alex','password','Alex',NULL,'alex(a)jbpm.org');
| INSERT INTO JBPM4_ID_USER VALUES (2,0,'mike','password','Mike',NULL,'mike(a)jbpm.org');
| INSERT INTO JBPM4_ID_USER VALUES (3,0,'peter','password','Peter',NULL,'peter(a)jbpm.org');
| INSERT INTO JBPM4_ID_USER VALUES (4,0,'mary','password','Mary',NULL,'mary(a)jbpm.org');
|
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (1,0,1,2,NULL);
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (2,0,2,1,NULL);
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (3,0,3,3,NULL);
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (4,0,3,4,NULL);
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (5,0,4,3,NULL);
| INSERT INTO JBPM4_ID_MEMBERSHIP VALUES (6,0,4,4,NULL);
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4231256#4231256
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4231256
16 years, 10 months