Hey,
I'm trying to set up a Hypersonic service to an existing database that I
use. I'm trying to do it by re-using the Hypersonic service MBean, but it
seems the service isn't starting.
In my jboss.jcml I've added the following lines...
<mbean name="DefaultDomain:service=Hypersonic">
<attribute name="Port">1477</attribute>
<attribute name="Silent">false</attribute>
<attribute name="Database">FantasyFootball</attribute>
<attribute name="Trace">false</attribute>
</mbean>
<mbean
name="DefaultDomain:service=XADataSource,name=FantasyFootballDS">
<attribute name="Properties"></attribute>
<attribute
name="URL">jdbc:HypersonicSQL:hsql://localhost:1477</attribute>
<attribute name="GCMinIdleTime">1200000</attribute>
<attribute name="JDBCUser">sa</attribute>
<attribute name="MaxSize">10</attribute>
<attribute name="Password" />
<attribute name="GCEnabled">false</attribute>
<attribute name="InvalidateOnError">false</attribute>
<attribute name="TimestampUsed">false</attribute>
<attribute name="Blocking">true</attribute>
<attribute name="GCInterval">120000</attribute>
<attribute name="IdleTimeout">1800000</attribute>
<attribute name="IdleTimeoutEnabled">false</attribute>
<attribute name="LoggingEnabled">false</attribute>
<attribute name="MaxIdleTimeoutPercent">1.0</attribute>
<attribute name="MinSize">0</attribute>
</mbean>
Note that I haven't deleted the service used by DefaultDS, as I don't want
to replace it. Instead, I'm trying to start a second hypersonic server.
I've copied the existing FantasyFootball files to the db/hypersonic
directory.
When I start jBoss I get a connection broken error as follows...
[FantasyFootballDS] Starting
[FantasyFootballDS] XA Connection pool FantasyFootballDS bound to
java:/FantasyFootballDS
[FantasyFootballDS] java.sql.SQLException: Connection is broken: Connection
refused: no further information
[FantasyFootballDS] at org.hsql.Trace.getError(Trace.java:124)
[FantasyFootballDS] at org.hsql.Trace.getError(Trace.java:115)
[FantasyFootballDS] at org.hsql.Trace.error(Trace.java:130)
[FantasyFootballDS] at
org.hsql.jdbcConnection.reconnectHSQL(jdbcConnection.java:621)
[FantasyFootballDS] at
org.hsql.jdbcConnection.openHSQL(jdbcConnection.java:605)
[FantasyFootballDS] at
org.hsql.jdbcConnection.<init>(jdbcConnection.java:523)
[FantasyFootballDS] at org.hsql.jdbcDriver.connect(jdbcDriver.java:78)
[FantasyFootballDS] at java.sql.DriverManager.getConnection(Unknown
Source)
[FantasyFootballDS] at java.sql.DriverManager.getConnection(Unknown
Source)
[FantasyFootballDS] at
org.jboss.minerva.xa.XADataSourceImpl.getXAConnection(XADataSourceImpl.java:
121)
[FantasyFootballDS] at
org.jboss.minerva.xa.XADataSourceImpl.getXAConnection(XADataSourceImpl.java:
155)
[FantasyFootballDS] at
org.jboss.minerva.factories.XAConnectionFactory.createObject(XAConnectionFac
tory.java:232)
[FantasyFootballDS] at
org.jboss.minerva.pools.ObjectPool.createNewObject(ObjectPool.java:801)
[FantasyFootballDS] at
org.jboss.minerva.pools.ObjectPool.getObject(ObjectPool.java:549)
[FantasyFootballDS] at
org.jboss.minerva.datasource.XAPoolDataSource.getConnection(XAPoolDataSource
.java:169)
[FantasyFootballDS] at
org.jboss.jdbc.XADataSourceLoader.initializePool(XADataSourceLoader.java:288
)
[FantasyFootballDS] at
org.jboss.jdbc.XADataSourceLoader.startService(XADataSourceLoader.java:252)
[FantasyFootballDS] at
org.jboss.util.ServiceMBeanSupport.start(ServiceMBeanSupport.java:92)
[FantasyFootballDS] at java.lang.reflect.Method.invoke(Native Method)
[FantasyFootballDS] at
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
[FantasyFootballDS] at
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
[FantasyFootballDS] at
org.jboss.dependencies.DependencyManager.startMBean(DependencyManager.java:2
84)
[FantasyFootballDS] at
org.jboss.dependencies.DependencyManager.loadService(DependencyManager.java:
261)
[FantasyFootballDS] at
org.jboss.dependencies.DependencyManager.processService(DependencyManager.ja
va:243)
[FantasyFootballDS] at
org.jboss.dependencies.DependencyManager.processService(DependencyManager.ja
va:238)
[FantasyFootballDS] at
org.jboss.dependencies.DependencyManager.startMBeans(DependencyManager.java:
117)
[FantasyFootballDS] at org.jboss.Main.<init>(Main.java:162)
[FantasyFootballDS] at org.jboss.Main$1.run(Main.java:87)
[FantasyFootballDS] at
java.security.AccessController.doPrivileged(Native Method)
[FantasyFootballDS] at org.jboss.Main.main(Main.java:83)
If i remove the lines that declare my hypersonic database
<mbean name="DefaultDomain:service=Hypersonic">
<attribute name="Port">1477</attribute>
<attribute name="Silent">false</attribute>
<attribute name="Database">FantasyFootball</attribute>
<attribute name="Trace">false</attribute>
</mbean>
from jboss.jcml, and instead run a stand-alone hsql server to the
FantasyFootball database, everything works fine.
Also, if I completley remove the lines declaring the DefaultDS service and
data-source, and leave in the declaration for FantasyFootballDS as shown
above, evrything works fine.
So I guess my question is, what is the problem with trying to start two
Hypersonic servers to two different dbases using the same hypersonic-service
MBean?
Cheers,
Ian.
______________________________________________
Ian Priest
t +44 (0) 1344 644162 | m +44 (0) 7970 243401 | f +44 (0) 1344 644190
a Rubus Court | Eastern Road | Bracknell | Berkshire RG12 2UP | UK
Rubus provides e-business solutions that turn innovative ideas
into practical business reality.
______________________________________________
:: rubus | www.rubus.com
Any views or opinions presented are solely those of the author
and do not necessarily represent those of Rubus.
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user