• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Urgent : Java Executable in Windows and Linux

 
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Hello

I have to deliver a pilot applicationfor a java project involving Struts, Hibernate, SFTP for encrypted file transfer,GNU Privacy Guard (GPG) for Decryption/Encryption
and postgre. This has to be executed in either Windows/Linux environment.

The client wants the executable file of this application which should run in both windows and linux.

I have to send an executable file to my client by friday (this week).

Please suggest me how to do this.

Thanks
Madhan
 
Rancher
Posts: 3742
16
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
With a requirement as vague as that, this is about the best I can come up with.

1. Learn java, Struts, Hibernate, SFTP for encrypted file transfer,GNU Privacy Guard (GPG) for Decryption/Encryption and postgre
2. Write code.
3. Create executable jar file.
4. Test
5. Repeat 2, 3 and 4 until program works
6. Package jar file and any required third party stuff
7. Send to client.
 
Saloon Keeper
Posts: 7585
176
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How would an executable file that contains a web app work? Should the double-clickable app start up an embedded servlet container that can then be used to serve the web app? Certainly doable, even in a cross-platform compatible way, although rather unconventional.

What's more, GPG is native code - have you figured out yet how to use that as part of a web app?

You didn't say how far along you are in this project, but if a question this fundamental (about how to deploy your app) comes up only now I very much doubt that it's going to happen until Friday.
 
Ranch Hand
Posts: 1609
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

madhankumar kumaravelu wrote:
Hello

I have to deliver a pilot applicationfor a java project involving Struts, Hibernate, SFTP for encrypted file transfer,GNU Privacy Guard (GPG) for Decryption/Encryption
and postgre. This has to be executed in either Windows/Linux environment.

The client wants the executable file of this application which should run in both windows and linux.

I have to send an executable file to my client by friday (this week).

Please suggest me how to do this.

Thanks
Madhan



When I first read "I have to deliver a pilot application", i thought if it rocket science being discussed, then I read the word "java" I sighed... I continued reading, and by the time it came to "by friday (this week)."...

Madhan Ease up.
 
madhankumar kumaravelu
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I want to know only how to create an executable jar file in linux/windows and

whether it can contain all the technical stuffs i have mentioned.

Obviously i cannot be in a position to start coding now and deliver by friday.

Implementation and testing are done.

 
Tim Moores
Saloon Keeper
Posts: 7585
176
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So this is a web app, then? How did you envision running a web app from within a jar file? How did you test it if you don't know how to deploy it?
 
Akhilesh Trivedi
Ranch Hand
Posts: 1609
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

madhankumar kumaravelu wrote:
I want to know only how to create an executable jar file in linux/windows and

whether it can contain all the technical stuffs i have mentioned.

Obviously i cannot be in a position to start coding now and deliver by friday.

Implementation and testing are done.



You can always create a jar that runs both on windows and linux. That is why Java is platform independent. But you are looking for jar or war, and if implementation and testing are done, then what is pending?
 
madhankumar kumaravelu
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Actually, i have implemented and tested with the Eclipse IDE.

1)

I want to know the command that will create jar file.

The client should only double click it and the application should run.

2)

The created jar file can only contain the souce code.
The client should have the same environment (e.g. postgre installed) to execute it?


 
Tim Moores
Saloon Keeper
Posts: 7585
176
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The client should have the same environment (e.g. postgre installed) to execute it?


Since the app apparently requires a servlet container and a DB, yes, the user will need those. You can substitute the servlet container by starting up an embedded one in the double-clickable jar file. As to the DB, you could embed something like HSQLDB or Derby in your app as well. Native-code DBs like Postgres or Mysql are pretty much out of the question, unless you expect the users to be able and willing to install non-trivial software on their machines.

The created jar file can only contain the souce code.


Um, what? Why would you want to ship source code? And how do you expect to run the app if you ship *only* source code? What would there be to execute?
 
madhankumar kumaravelu
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Source code means the class files in the jar file.


You can substitute the servlet container by starting up an embedded one in the double-clickable jar file.



Can you detail the above comment?
 
Tim Moores
Saloon Keeper
Posts: 7585
176
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Source code means the class files in the jar file.


Class files are not source code, they're executable code.

You can substitute the servlet container by starting up an embedded one in the double-clickable jar file.



Can you detail the above comment?
This may be a start: http://java.dzone.com/articles/embedded-tomcat-minimal. The Tomcat documentation probably has more about this.
 
Can't .... do .... plaid .... So I did this tiny ad instead:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic