running ops in jboss using hibernate

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

running ops in jboss using hibernate

Merin Shaji
Hi,
 
I have an OPS application running in JBoss Application Server, which uses Hibernate for persistence. Hibernate is using JNDI datasource configured in JBoss. When I run this, I am getting the following exception:

FATAL [DatasourceConnectionProvider] Could not find datasource: java:/OracleDS

javax.naming.NameNotFoundException

: OracleDS not bound

When I run the another Web Project (deployed as war file) in the same context using hibernate, it is identifying the datasource.

I have made the following changes in JBoss to configure JNDI datasource:

Created oracle-ds.xml inside D:\jboss-4.0.3RC1\server\default\deploy folder with the following entries:

<datasources>

<local-tx-datasource>

<jndi-name>OracleDS</jndi-name>

<connection-url>jdbc:oracle:thin:@xxx.xxx.com:1521:orcl</connection-url>

<driver-class>oracle.jdbc.driver.OracleDriver</driver-class>

<user-name>test</user-name>

<password>test</password>

<min-pool-size>5</min-pool-size>

<max-pool-size>20</max-pool-size>

<idle-timeout-minutes>0</idle-timeout-minutes>

</local-tx-datasource>

</datasources>

Is there any additional settings I have to do to make it working in OPS?

I have not given any reference to the datasource in my web.xml for the second Web Project I mentioned above.

But I tried that with OPS. I made an entry for resource-ref in web.xml and jboss-web.xml as mentioned in the JBoss documentation. This also did not work.

Has any one got any idea on how to configure this?

Please help as this is very critical for our project.

Thanks in advance

Merin

 



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: running ops in jboss using hibernate

Erik Bruchez
Administrator
Merin,

If I understand well, the datasource is just accessed by Hibernate, not
by something like the oxf:sql processor?

If that's the case, I fear that I don't have a solution. I don't think
Orbeon Forms does anything particular with datasources.

-Erik

Merin Shaji wrote:

> Hi,
>  
> I have an OPS application running in JBoss Application Server, which
> uses Hibernate for persistence. Hibernate is using JNDI datasource
> configured in JBoss. When I run this, I am getting the following exception:
>
> *FATAL [DatasourceConnectionProvider] Could not find datasource:
> java:/OracleDS*
>
> _
>
> *javax.naming.NameNotFoundException*
>
> _*: OracleDS not bound*
>
> When I run the another Web Project (deployed as war file) in the same
> context using hibernate, it is identifying the datasource.
>
> I have made the following changes in JBoss to configure JNDI datasource:
>
> *Created oracle-ds.xml inside D:\jboss-4.0.3RC1\server\default\deploy
> folder with the following entries:*
>
> <datasources>
>
>     <local-tx-datasource>
>
>         <jndi-name>OracleDS</jndi-name>
>
>         <connection-url>jdbc:oracle:thin:@xxx.xxx.com:1521
>         <http://jdbc:oracle:thin:@xxx.xxx.com:1521>:orcl</connection-url>
>
>         <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
>
>         <user-name>test</user-name>
>
>         <password>test</password>
>
>         <min-pool-size>5</min-pool-size>
>
>         <max-pool-size>20</max-pool-size>
>
>         <idle-timeout-minutes>0</idle-timeout-minutes>
>
>     </local-tx-datasource>
>
> </datasources>
>
> Is there any additional settings I have to do to make it working in OPS?
>
> I have not given any reference to the datasource in my web.xml for the
> second Web Project I mentioned above.
>
> But I tried that with OPS. I made an entry for resource-ref in web.xml
> and jboss-web.xml as mentioned in the JBoss documentation. This also did
> not work.
>
> Has any one got any idea on how to configure this?
>
> Please help as this is very critical for our project.
>
> Thanks in advance
>
> Merin
--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: running ops in jboss using hibernate

Merin Shaji
Erik,
 
Datasource is working fine for me when I do the same hibernate configuration in another web project. That is why I doubt whether the problem is due to any config changes made in OPS. Please share any ideas you have regarding this. Is there any documentation on how JBoss' JNDI datasource is used in OPS? 
 
Thanks & Regards
Merin

 
On 5/17/07, Erik Bruchez <[hidden email]> wrote:
Merin,

If I understand well, the datasource is just accessed by Hibernate, not
by something like the oxf:sql processor?

If that's the case, I fear that I don't have a solution. I don't think
Orbeon Forms does anything particular with datasources.

-Erik

Merin Shaji wrote:

> Hi,
>
> I have an OPS application running in JBoss Application Server, which
> uses Hibernate for persistence. Hibernate is using JNDI datasource
> configured in JBoss. When I run this, I am getting the following exception:
>
> *FATAL [DatasourceConnectionProvider] Could not find datasource:
> java:/OracleDS*
>
> _
>
> *javax.naming.NameNotFoundException*
>
> _*: OracleDS not bound*
>
> When I run the another Web Project (deployed as war file) in the same
> context using hibernate, it is identifying the datasource.
>
> I have made the following changes in JBoss to configure JNDI datasource:
>
> *Created oracle-ds.xml inside D:\jboss-4.0.3RC1\server\default\deploy
> folder with the following entries:*
>
> <datasources>
>
>     <local-tx-datasource>
>
>         <jndi-name>OracleDS</jndi-name>
>
>         <connection-url> jdbc:oracle:thin:@xxx.xxx.com:1521
>         <http://jdbc:oracle:thin:@xxx.xxx.com:1521>:orcl</connection-url>
>
>         <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
>
>         <user-name>test</user-name>
>
>         <password>test</password>
>
>         <min-pool-size>5</min-pool-size>
>
>         <max-pool-size>20</max-pool-size>
>
>         <idle-timeout-minutes>0</idle-timeout-minutes>
>
>     </local-tx-datasource>
>
> </datasources>
>
> Is there any additional settings I have to do to make it working in OPS?
>
> I have not given any reference to the datasource in my web.xml for the
> second Web Project I mentioned above.
>
> But I tried that with OPS. I made an entry for resource-ref in web.xml
> and jboss-web.xml as mentioned in the JBoss documentation. This also did
> not work.
>
> Has any one got any idea on how to configure this?
>
> Please help as this is very critical for our project.
>
> Thanks in advance
>
> Merin

--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: running ops in jboss using hibernate

Alessandro Vernet
Administrator
Hi Merin,

On 5/21/07, Merin Shaji <[hidden email]> wrote:
> Datasource is working fine for me when I do the same hibernate configuration
> in another web project. That is why I doubt whether the problem is due to
> any config changes made in OPS. Please share any ideas you have regarding
> this. Is there any documentation on how JBoss' JNDI datasource is used in
> OPS?

In this case the datasource is not used by Orbeon Forms: it is
configured in JBoss and used by Hibernate. Is this understanding
correct? If it is, I am not sure how Orbeon Forms could interfere.

Alex
--
Orbeon Forms - Web 2.0 Forms for the Enterprise
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws