Java persistence.xml

For questions and postings not covered by the other forums
rangerdunadan
Posts: 6
Joined: Sat May 01, 2010 10:53 am

Java persistence.xml

Postby rangerdunadan » Sat May 01, 2010 11:00 am

Hey Guys,

Has anyone tried to get java to connect to Jade, using the javajom.jar, where Jade exists on a separate server?

I can successfully get java to connect to Jade when it exists on the same server partly because the manual tells me what the XML properties are that need to be put into the persistence.xml file. They are jade.database.path and jade.database.configuration. However, it doesn't tell me what all of the options are. Is there a jade.database.host and jade.database.port option? If so is that how I would configure the persistence.xml file to connect to a multi-user Jade DB that exists on a separate server?

What do you all think?

Thanks.

Ranger.

User avatar
BeeJay
Posts: 312
Joined: Tue Jun 30, 2009 2:42 pm
Location: Christchurch, NZ

Re: Java persistence.xml

Postby BeeJay » Sat May 01, 2010 12:31 pm

I have not personally used this, but based on the description that the jomjar connects as a standard client I would imagine when you have set jade.database.multiuser to true that it takes the ini file that you specified using jade.database.configuration and then uses the information in the ServerNodeSpecifications setting of the [JadeClient] section of that ini file to determine how to connect to the database server. For example, if your database server is being hosted on 192.168.1.3 and is listening on port 54321, then your [JadeClient] section would have the following details in the ServerNodeSpecifications setting:

[JadeClient]
ServerNodeSpecifications=TcpIp,192.168.1.3,54321

Given that the jomjar connects as a standard client, you also need to make sure that the value specified in jade.database.path is the database path as viewed by the Database Server process, even if that path doesn't actually exist on the client machine running the Java application.

Cheers,
BeeJay.

rangerdunadan
Posts: 6
Joined: Sat May 01, 2010 10:53 am

Re: Java persistence.xml

Postby rangerdunadan » Sat May 01, 2010 4:10 pm

I'll bet that's it!

Thanks for your reply.

Ranger.


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 49 guests