-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 
Author Message
 Post subject: hibernate + jboss ??
PostPosted: Wed Mar 03, 2004 1:21 am 
Beginner
Beginner

Joined: Fri Feb 27, 2004 3:49 am
Posts: 25
i following instruction on http://www.hibernate.org/66.html. and generate hibernate sar file called hibernateStartup.sar.

it is my hibernateStartup.sar look like.

<server>
<mbean code="net.sf.hibernate.jmx.HibernateService"
name="jboss.jca:service=Hibernate">

<depends>jboss.jca:service=RARDeployer</depends>
<attribute
name="MapResources">com/creativesol/erp4all/model/Inventory.hbm.xm l</attribute>
<attribute name="JndiName">java:/HibernateFactory</attribute>
<attribute name="Datasource">java:/MySqlDSERP4ALL</attribute>
<attribute name="Dialect">net.sf.hibernate.dialect.MySQLDialect</attribute>
<attribute name="UseOuterJoin">true</attribute>
<attribute name="ShowSql">false</attribute>
<attribute name="UserTransactionName">UserTransaction</attribute>
<attribute name="TransactionStrategy">net.sf.hibernate.transaction.JTATransactionFactory</attribute>
<attribute name="TransactionManagerLookupStrategy">net.sf.hibernate.transaction.JBossTransactionManagerLookup</attribute>
</mbean>

</server>

then i copy this file to my jboss/server/deploy and run the jboss. but i got error message :
...
2004-03-03 13:19:25,156 INFO [net.sf.hibernate.cfg.Configuration]
processing foreign key constraints
2004-03-03 13:19:25,234 INFO [net.sf.hibernate.dialect.Dialect] Using
dialect: net.sf.hibernate.dialect.MySQLDialect
2004-03-03 13:19:25,234 INFO [net.sf.hibernate.cfg.SettingsFactory] Use
outer join fetching: true
2004-03-03 13:19:25,250 INFO [net.sf.hibernate.util.NamingHelper] JNDI
InitialContext properties:{}
2004-03-03 13:19:25,265 FATAL
[net.sf.hibernate.connection.DatasourceConnectionProvider] Could
not find datasource: java:/MySqlDSERP4ALL
javax.naming.NameNotFoundException: MySqlDSERP4ALL not bound
at org.jnp.server.NamingServer.getBinding(NamingServer.java:495)
...

someone can help me to solve this promble? thanks


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2004 5:03 am 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
Well looks like your datasource is not bound at java:/MySqlDSERP4ALL - check for that.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 04, 2004 4:17 am 
Beginner
Beginner

Joined: Thu Jan 08, 2004 4:40 am
Posts: 48
Location: Bangkok, Thailand
<?xml version="1.0" encoding="UTF-8"?>



<!-- ===================================================================== -->

<!-- -->

<!-- JBoss Server Configuration -->

<!-- -->

<!-- ===================================================================== -->



<!-- $Id: mysql-ds.xml,v 1.1 2002/07/22 22:57:24 d_jencks Exp $ -->

<!-- ==================================================================== -->

<!-- Datasource config for MySQL using 2.0.11 driver -->

<!-- ==================================================================== -->





<datasources>

<local-tx-datasource>

<jndi-name>MySqlDSERP4ALL</jndi-name>

<connection-url>jdbc:mysql://your-server/your-database</connection-url>

<driver-class>your-driver</driver-class>

<user-name>your-user-name</user-name>

<password>your-password</password>

</local-tx-datasource>



</datasources>

_________________
<name>arin</name>
<at>netplus software</at>


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 04, 2004 6:52 pm 
Senior
Senior

Joined: Tue Nov 25, 2003 9:35 am
Posts: 194
Location: San Francisco
You should see your datasource being created in the server.log. Is it there?


Sherman


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 05, 2004 1:13 am 
Beginner
Beginner

Joined: Fri Feb 27, 2004 3:49 am
Posts: 25
i solved the problem. thanks for your information.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.