Share ofbiz resources with jndi

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Share ofbiz resources with jndi

Daniel Riquelme
I would like to access the database that ofbiz is using, from an external
application through jndi.
Is this possible ?

Thanks,
Daniel
Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

Jacques Le Roux
Administrator
Why not through HTTP ?

Jacques

From: "Daniel Riquelme" <[hidden email]>
>I would like to access the database that ofbiz is using, from an external
> application through jndi.
> Is this possible ?
>
> Thanks,
> Daniel
>

Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

Daniel Riquelme
Because the external application knows how to use jndi and jdbc only, and in
this case jdbc is not an opiton.

On Thu, Jun 4, 2009 at 12:37 PM, Jacques Le Roux <
[hidden email]> wrote:

> Why not through HTTP ?
>
> Jacques
>
> From: "Daniel Riquelme" <[hidden email]>
>
>  I would like to access the database that ofbiz is using, from an external
>> application through jndi.
>> Is this possible ?
>>
>> Thanks,
>> Daniel
>>
>>
>
Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

David E Jones-3
In reply to this post by Daniel Riquelme

Check out:

http://docs.ofbiz.org/display/OFBTECH/Apache+OFBiz+Technical+Production+Setup+Guide

It has a link to this document as well that has a few more details on  
getting JTA and JDBC objects from JNDI:

http://ofbiz.apache.org/docs/entityconfig.html

-David


On Jun 4, 2009, at 10:03 AM, Daniel Riquelme wrote:

> I would like to access the database that ofbiz is using, from an  
> external
> application through jndi.
> Is this possible ?
>
> Thanks,
> Daniel

Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

Daniel Riquelme
These two documents talk about an external jndi server and how to configure
ofbiz to use it's resources, am I right ?
I would like to know if it's possible to use ofbiz+geronimo as the jndi
server and obtain a jdbc connection from an external application using jndi.

On Thu, Jun 4, 2009 at 1:11 PM, David E Jones
<[hidden email]>wrote:

>
> Check out:
>
>
> http://docs.ofbiz.org/display/OFBTECH/Apache+OFBiz+Technical+Production+Setup+Guide
>
> It has a link to this document as well that has a few more details on
> getting JTA and JDBC objects from JNDI:
>
> http://ofbiz.apache.org/docs/entityconfig.html
>
> -David
>
>
>
> On Jun 4, 2009, at 10:03 AM, Daniel Riquelme wrote:
>
>  I would like to access the database that ofbiz is using, from an external
>> application through jndi.
>> Is this possible ?
>>
>> Thanks,
>> Daniel
>>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

David E Jones-3

I see. Yes, that is possible. If you deploy OFBiz in an external app  
server you'll usually setup OFBiz to get the JTA and JDBC objects from  
JNDI, and then any other app can too.

There is a JNDI server running inside OFBiz right now too, and it is  
used for getting various objects (like the RemoteDispatcher for the  
service engine, etc). Right now by default the JTA and JDBC objects  
are not put into JNDI, but with a few lines of code that could change...

-David


On Jun 4, 2009, at 3:13 PM, Daniel Riquelme wrote:

> These two documents talk about an external jndi server and how to  
> configure
> ofbiz to use it's resources, am I right ?
> I would like to know if it's possible to use ofbiz+geronimo as the  
> jndi
> server and obtain a jdbc connection from an external application  
> using jndi.
>
> On Thu, Jun 4, 2009 at 1:11 PM, David E Jones
> <[hidden email]>wrote:
>
>>
>> Check out:
>>
>>
>> http://docs.ofbiz.org/display/OFBTECH/Apache+OFBiz+Technical+Production+Setup+Guide
>>
>> It has a link to this document as well that has a few more details on
>> getting JTA and JDBC objects from JNDI:
>>
>> http://ofbiz.apache.org/docs/entityconfig.html
>>
>> -David
>>
>>
>>
>> On Jun 4, 2009, at 10:03 AM, Daniel Riquelme wrote:
>>
>> I would like to access the database that ofbiz is using, from an  
>> external
>>> application through jndi.
>>> Is this possible ?
>>>
>>> Thanks,
>>> Daniel
>>>
>>
>>

Reply | Threaded
Open this post in threaded view
|

Re: Share ofbiz resources with jndi

Daniel Riquelme
I took a peek at the code you mention. I found that an rmi registry is used
to store the RemoteDispatcher. I also found that the DBCP data source is
created before the registry (in DBCPConnectionFactory), the data source that
is created here is stored in a private cache.
What modifications would you recommend to get a DataSource registered ?
It looks like I would have to modify DBCPConnectionFactory or perharps there
is some other way to get a reference to the DataSource object.

On Thu, Jun 4, 2009 at 5:19 PM, David E Jones
<[hidden email]>wrote:

>
> I see. Yes, that is possible. If you deploy OFBiz in an external app server
> you'll usually setup OFBiz to get the JTA and JDBC objects from JNDI, and
> then any other app can too.
>
> There is a JNDI server running inside OFBiz right now too, and it is used
> for getting various objects (like the RemoteDispatcher for the service
> engine, etc). Right now by default the JTA and JDBC objects are not put into
> JNDI, but with a few lines of code that could change...
>
> -David
>
>
>
> On Jun 4, 2009, at 3:13 PM, Daniel Riquelme wrote:
>
>  These two documents talk about an external jndi server and how to
>> configure
>> ofbiz to use it's resources, am I right ?
>> I would like to know if it's possible to use ofbiz+geronimo as the jndi
>> server and obtain a jdbc connection from an external application using
>> jndi.
>>
>> On Thu, Jun 4, 2009 at 1:11 PM, David E Jones
>> <[hidden email]>wrote:
>>
>>
>>> Check out:
>>>
>>>
>>>
>>> http://docs.ofbiz.org/display/OFBTECH/Apache+OFBiz+Technical+Production+Setup+Guide
>>>
>>> It has a link to this document as well that has a few more details on
>>> getting JTA and JDBC objects from JNDI:
>>>
>>> http://ofbiz.apache.org/docs/entityconfig.html
>>>
>>> -David
>>>
>>>
>>>
>>> On Jun 4, 2009, at 10:03 AM, Daniel Riquelme wrote:
>>>
>>> I would like to access the database that ofbiz is using, from an external
>>>
>>>> application through jndi.
>>>> Is this possible ?
>>>>
>>>> Thanks,
>>>> Daniel
>>>>
>>>>
>>>
>>>
>