Geronimo logging for connection pool events

2009-11-26 Thread andyhan

I have a database connection pool of type TranQL Generic JDBC Resource
Adapter with oracle.jdbc.OracleDriver.
We need to monitor all about connection life-cycle: when they were open and
closed.

How can I configure server-log4j.properties so that this information appears
in log? 

This doesn't work:
log4j.logger.oracle.jdbc.pool.OracleConnectionCacheManager=INFO
log4j.logger.org.tranql.connector.jdbc.AbstractLocalDataSourceMCF=INFO
log4j.logger.apache.geronimo.connector.outbound.MCFConnectionInterceptor=INFO

If not configurable: Is there any possibility do it another way?
-- 
View this message in context: 
http://old.nabble.com/Geronimo-logging-for-connection-pool-events-tp26528939s134p26528939.html
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.



Re: Geronimo logging for connection pool events

2009-11-26 Thread chi runhua
You may refer to [1] to see whether it helps.

http://cwiki.apache.org/GMOxDOC22/configuring-application-specific-logging-with-log4j.html

Jeff C

On Thu, Nov 26, 2009 at 8:43 PM, andyhan a.luben...@gmx.de wrote:


 I have a database connection pool of type TranQL Generic JDBC Resource
 Adapter with oracle.jdbc.OracleDriver.
 We need to monitor all about connection life-cycle: when they were open and
 closed.

 How can I configure server-log4j.properties so that this information
 appears
 in log?

 This doesn't work:
 log4j.logger.oracle.jdbc.pool.OracleConnectionCacheManager=INFO
 log4j.logger.org.tranql.connector.jdbc.AbstractLocalDataSourceMCF=INFO

 log4j.logger.apache.geronimo.connector.outbound.MCFConnectionInterceptor=INFO

 If not configurable: Is there any possibility do it another way?
 --
 View this message in context:
 http://old.nabble.com/Geronimo-logging-for-connection-pool-events-tp26528939s134p26528939.html
 Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.




Re: fetching deployed server instance value

2009-11-26 Thread chi runhua
See the implementation in Geronimo for reference.

https://svn.apache.org/repos/asf/geronimo/server/branches/2.2/framework/modules/geronimo-commands/src/main/groovy/org/apache/geronimo/commands/WaitForServerCommand.groovy

Jeff C

On Mon, Nov 23, 2009 at 4:17 AM, anshukpal
anshuk_palchaudh...@infosys.comwrote:


 I am deploying a web app on geronimo application server. I would like to
 know
 whether there are any specific apis from which would allow to fetch the
 specific application server instance value, the reason being the same
 application would be deployed on two different application server instances
 and the unique application server instance would be required to do some
 operations.

 Anshuk

 --
 View this message in context:
 http://old.nabble.com/fetching-deployed-server-instance-value-tp26467881s134p26467881.html
 Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.




Re: ActiveMQ questions

2009-11-26 Thread chi runhua
Go to Geronimo_HOME/var/activemq/conf directory and update activemq.xml
file according to your needs. You can have the same experiences as you can
do for a standalone ActiveMQ server.
If you need to update ActiveMQ default port in Geronimo, you may update the
value of ActiveMQPort in /var/config/config-substitutions.properties file.

Hope this helps.

Jeff C



On Tue, Nov 24, 2009 at 11:09 PM, easyl easy@gmail.com wrote:


 I use geronimo 2.1.2.
 It seems that the only way to configurate embedded AMQ is through
 ServerUrl.

 For example:
 config-property-setting

 name=ServerUrltcp://localhost:61616?jms.copyMessageOnSend=falseamp;jms.watchTopicAdvisories=falseamp;socket.tcpNoDelay=trueamp;wireFormat.tcpNoDelayEnabled=true/config-property-setting


 Now I want to completely disable advisory message.
 See: http://activemq.apache.org/advisory-message.html
 The configuration is through XML config data.
  broker advisorySupport=false...

 How can I do that in geronimo?
 I try to follow the instructions from
 http://activemq.apache.org/resource-adapter-properties.html

 To add this in deploy plan...
 config-property-setting
 name=BrokerXmlConfigxbean:config.xml/config-property-setting

 But geronimo can not handle xbean schema.
 ...did not start because Failed to startup an embedded broker:
 xbean:config.xml, due to: java.io.IOException: Could load xbean
 factory:java.lang.NoClassDefFoundError:
 org/springframework/beans/BeansException





 --
 View this message in context:
 http://old.nabble.com/ActiveMQ-questions-tp6326283s134p26497537.html
 Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.




Re: Geronimo with openjpa (and DataSource lookups)

2009-11-26 Thread David Jencks
The datasource module needs to be listed as a dependency of the war  
module if they are deployed separately.  Single-valued component  
search in geronimo follows the directed acyclic graph of dependencies  
so you can deploy lots of datasources named jdbc/db in different  
modules yet still get the one you want in your app by specifying the  
module with the right one as a dependency.


thanks
david jencks

On Nov 26, 2009, at 9:44 AM, cumbers wrote:



I am looking for someone to put me out of my geronimo/openpa misery.

I have an application that I can deploy to Geronimo (2.1.1.3) that  
uses

openjpa where the properties inside the persistence.xml are explicitly
defined like so:

properties
   property name=openjpa.ConnectionDriverName
value=oracle.jdbc.driver.OracleDriver/property
   property name=openjpa.ConnectionURL
value=jdbc:oracle:thin:@localhost:1521:DB/property
   property name=openjpa.ConnectionUserName
value=dbuser/property
   property name=openjpa.ConnectionPassword
value=passw0rd/property
/properties

However this app is going to be deployed by lots of users, and  
ideally I
would like to ship a war file, and direct users to create a JNDI  
object that

they define and then openjpa uses this.

Simply defining the JNDI datasource connection within Geronimo, and  
using

the reference in the jta-data-sourcejdbc/db/jta-data-source or
non-jta-data-sourcejdbc/db/non-jta-data-source does not appear  
to work,

and I get the following error message when I try and create an
EntityManager:

openjpa-1.2.1-r2180:4612 fatal user error
org.apache.openjpa.persistence.ArgumentException: A JDBC Driver or
DataSource class name must be specified in the ConnectionDriverName
property.

After 3 days on google, I found this page:
http://cwiki.apache.org/GMOxDOC21/datasource-connectionfactory-mdb-and-jpa.html
which suggests that:

Although many other servers use jndi to define the meaning of the
jta-data-source and non-jta-data-source geronimo does not. These are  
not
jndi names in any way but must match the name specified in the  
connector

plan.

OK so using the jndi object name directly does not seem to be  
supported.
However the name in the resourceadapter of the plan.xml IS jdbc/db  
and so
I think this should work. Here is the relevant snippet from my  
plan.xml as

created when I define a JDBC datasource using Geronimo.

   resourceadapter
   outbound-resourceadapter
   connection-definition

connectionfactory-interfacejavax.sql.DataSource/connectionfactory- 
interface

   connectiondefinition-instance
   namejdbc/db/name

I have run out of ideas on how I can make this work, and would be  
massively
appreciative if anyone can shed some light on why this is not  
working. If

you think you need more information please let me know!

Cheers

Rich
--
View this message in context: 
http://old.nabble.com/Geronimo-with-openjpa-%28and-DataSource-lookups%29-tp26532836s134p26532836.html
Sent from the Apache Geronimo - Users mailing list archive at  
Nabble.com.






Re: Geronimo with openjpa (and DataSource lookups)

2009-11-26 Thread Forrest Xia
Hi,

You can have the daytrader sample as an example for how to use defined
datasource in persistence.xml.

http://svn.apache.org/repos/asf/geronimo/daytrader/trunk/

If still not successful, pls try to describe your deployment steps and
related exceptions.

Forrest