Can a JavaFX program run in JWS and access a database? [message #1726849] |
Thu, 17 March 2016 01:27 |
Reinhardt Christiansen Messages: 73 Registered: March 2010 |
Member |
|
|
I am starting to design an application that ideally would have its GUI written in JavaFX, would run in a JWS (Java Web Start) environment and read and write from a relational database, either DB2 or MySQL.
Before I spend a lot of time on the design, I'd just like to verify that this combination is possible.
If anyone has a simple program with all or most of those features that they'd be willing to share for me to use as a starting point, I'd really appreciate it. Otherwise, I'll do that myself. If I write a program that uses JavaFX to display a button on a stage and pressing the button executes a trivial query, like "what is the current date?" on a DB2 or MySQL database, that should prove that the concept is viable. If the prototype can also write a trivial record to a database, such as a single row to an empty table, that would be even better.
|
|
|
Re: Can a JavaFX program run in JWS and access a database? [message #1726852 is a reply to message #1726849] |
Thu, 17 March 2016 01:59 |
|
It shouldn't be any different from any other Java Web Start application. You can web start an application with JavaFX as long as the user has an appropriate version of Java installed. You will most likely need to sign your jars and jnlp file to make it work.
Keep in mind that e(fx)clipse supports both standard Java applications as well as OSGi applications. It is possible to use OSGi with JavaFX, but it is very difficult. You will be much better off using standard Java.
|
|
|
Re: Can a JavaFX program run in JWS and access a database? [message #1726885 is a reply to message #1726849] |
Thu, 17 March 2016 09:39 |
Thomas Schindl Messages: 6651 Registered: July 2009 |
Senior Member |
|
|
a) it should be possible
b) I would not implement it this way because then your user has a
physical db connection and could issue DELETE FROM tbl, ... .
Tom
On 17.03.16 02:27, Reinhardt Christiansen wrote:
> I am starting to design an application that ideally would have its GUI
> written in JavaFX, would run in a JWS (Java Web Start) environment and
> read and write from a relational database, either DB2 or MySQL.
> Before I spend a lot of time on the design, I'd just like to verify that
> this combination is possible.
> If anyone has a simple program with all or most of those features that
> they'd be willing to share for me to use as a starting point, I'd really
> appreciate it. Otherwise, I'll do that myself. If I write a program that
> uses JavaFX to display a button on a stage and pressing the button
> executes a trivial query, like "what is the current date?" on a DB2 or
> MySQL database, that should prove that the concept is viable. If the
> prototype can also write a trivial record to a database, such as a
> single row to an empty table, that would be even better.
|
|
|
Re: Can a JavaFX program run in JWS and access a database? [message #1726887 is a reply to message #1726885] |
Thu, 17 March 2016 09:42 |
Thomas Schindl Messages: 6651 Registered: July 2009 |
Senior Member |
|
|
One more note: Oracle suggest to use the java-packager and ship a
private JRE with it!
Tom
On 17.03.16 10:39, Tom Schindl wrote:
> a) it should be possible
> b) I would not implement it this way because then your user has a
> physical db connection and could issue DELETE FROM tbl, ... .
>
> Tom
>
> On 17.03.16 02:27, Reinhardt Christiansen wrote:
>> I am starting to design an application that ideally would have its GUI
>> written in JavaFX, would run in a JWS (Java Web Start) environment and
>> read and write from a relational database, either DB2 or MySQL.
>> Before I spend a lot of time on the design, I'd just like to verify that
>> this combination is possible.
>> If anyone has a simple program with all or most of those features that
>> they'd be willing to share for me to use as a starting point, I'd really
>> appreciate it. Otherwise, I'll do that myself. If I write a program that
>> uses JavaFX to display a button on a stage and pressing the button
>> executes a trivial query, like "what is the current date?" on a DB2 or
>> MySQL database, that should prove that the concept is viable. If the
>> prototype can also write a trivial record to a database, such as a
>> single row to an empty table, that would be even better.
>
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03071 seconds