Hi! I have been developing and distributing Standalone Java Products in my local market for 4 years. My products include, POS Softwares for Retail and whole Sale Businesses and for Food Businesses such as Restaurants and cafes.
I use Apache Derby Database which is also known as 'JavaDB' as database and it works perfectly. I have also used JavaDB in a Cient Server Architecture (e.g if my customer has 3 PCs, and he wants to centralized database on his one Physical Server).

For database in Local Machine I used following Connections Strings:

    String dbdriver = "org.apache.derby.jdbc.EmbeddedDriver";
  Class.forName(dbdriver).newInstance();
 con = DriverManager.getConnection("jdbc:derby:C:\\QuintexDB; create = true"); 

And for Remote Servers is Used following Connection Strings:

 con = DriverManager.getConnection("jdbc:derby://192.168.10.125/C:\\QuintexDB; create = true"); 

As you saw that In Case of Remote server I used IP address of that machine. Firstly I gave static IP address to all PCs and server
and then Start the JavaDBServer by running CMD commands on Server Machine. And its works perfectly.

Now I need a new thing , I want JavaDB on cloud. What I want is I set up an account on Cloud service which provide facility of JavaDB and In My Connection String I just put the web address or IP address of that cloud services which is linked to my Account.
And When Me or my Customer starts his/ her java Destktop based application on his PC, the Java application should connect to the JavaDB on that cloud service and do his/her work. In short Now i am going to make my product an ERP.

I am facing two problems here:
1-) I searched on google by following phrases: "Online JavaDB connectivity" OR "Connect java application to online JavaDB" etc.
But most of the websites google provided me were providing only Mysql Database services
2-) And i also could not find , that what the connection string should be in this case in my Code. Because I have also worked many times with mySQL in my local machine and I know very well the connection string for that.

I need your help in finding me the the Hosting Service website which provides JavaDB and also guide me What should be the connection String to connect with that Cloud based JavaDB.

A few issues.

  1. JavaDB doesn't appear to be distributed any longer. I'm reading https://blogs.oracle.com/java-platform-group/deferring-to-derby-in-jdk-9 which was in 2015 so I'll write JavaDB is no more.

  2. https://db.apache.org/derby/docs/10.0/manuals/admin/hubprnt09.html gives us a clue that we may want to search for hosting for Tomcat. Such should be able to run Derby as well.

  3. If I search for "Tomcat on the cloud" I find various offerings.

JavaDB is just Derby, which moved from Oracle to Apache where it is still very much alive.
The most recent release was March 1st 2021 (!)
https://db.apache.org/derby/

Thanks for all your guidance. I have successfully connected my java application to MySql instead of Derby. Because mysql is comparatively easily available online.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.