Discussions
Categories
- 197K All Categories
- 2.5K Data
- 546 Big Data Appliance
- 1.9K Data Science
- 450.8K Databases
- 221.9K General Database Discussions
- 3.8K Java and JavaScript in the Database
- 31 Multilingual Engine
- 552 MySQL Community Space
- 479 NoSQL Database
- 7.9K Oracle Database Express Edition (XE)
- 3.1K ORDS, SODA & JSON in the Database
- 556 SQLcl
- 4K SQL Developer Data Modeler
- 187.2K SQL & PL/SQL
- 21.4K SQL Developer
- 296.3K Development
- 17 Developer Projects
- 139 Programming Languages
- 293K Development Tools
- 110 DevOps
- 3.1K QA/Testing
- 646.1K Java
- 28 Java Learning Subscription
- 37K Database Connectivity
- 158 Java Community Process
- 105 Java 25
- 22.1K Java APIs
- 138.2K Java Development Tools
- 165.3K Java EE (Java Enterprise Edition)
- 19 Java Essentials
- 162 Java 8 Questions
- 86K Java Programming
- 81 Java Puzzle Ball
- 65.1K New To Java
- 1.7K Training / Learning / Certification
- 13.8K Java HotSpot Virtual Machine
- 94.3K Java SE
- 13.8K Java Security
- 205 Java User Groups
- 24 JavaScript - Nashorn
- Programs
- 468 LiveLabs
- 39 Workshops
- 10.2K Software
- 6.7K Berkeley DB Family
- 3.5K JHeadstart
- 5.7K Other Languages
- 2.3K Chinese
- 175 Deutsche Oracle Community
- 1.1K Español
- 1.9K Japanese
- 233 Portuguese
Distribute Java jar application in Optical Disk with private JRE

neilghosh
Member Posts: 47
I am trying to ship my Jar application using DVDs and need the user just to run an exe and launch the program. So I have written a batch file which runs the jar using the private JRE shipped in the same DVD.
Now when I run the batch file from the DVD it takes over one minute to launch the application because JRE is in the DVD as well.
When I copy the JRE in hard disk and use that in my batch file to lauch the program it runs fast. However I wouldn't the path where the user copies the JRE in his hard disk. How would I detect the same in my batch file ?
Even Launch4J takes same time as batch file.
If I anyway have to ship JRE and ask the user install first ,how does batch file know the installed jre location if JAVA_HOME is not set. it would start using the jre in DVD and slow down. Anyway to make sure JAVA home is set to begin with ? May be 1st time if Java home is not set it copies to jre to C drive and then next time onwards it launches using the same Java home? What do you suggest
[cross post |http://stackoverflow.com/questions/13372969/distribute-java-jar-application-in-optical-disk]
Note I am using JDK8 , which is only developer preview now am I allowed to ship it in my DVD ?
Now when I run the batch file from the DVD it takes over one minute to launch the application because JRE is in the DVD as well.
When I copy the JRE in hard disk and use that in my batch file to lauch the program it runs fast. However I wouldn't the path where the user copies the JRE in his hard disk. How would I detect the same in my batch file ?
Even Launch4J takes same time as batch file.
If I anyway have to ship JRE and ask the user install first ,how does batch file know the installed jre location if JAVA_HOME is not set. it would start using the jre in DVD and slow down. Anyway to make sure JAVA home is set to begin with ? May be 1st time if Java home is not set it copies to jre to C drive and then next time onwards it launches using the same Java home? What do you suggest
[cross post |http://stackoverflow.com/questions/13372969/distribute-java-jar-application-in-optical-disk]
Note I am using JDK8 , which is only developer preview now am I allowed to ship it in my DVD ?
Tagged:
Answers
-
Neil Ghosh wrote:I wouldn't do that. Even if it is allowed, which I doubt, you're shipping unfinished and potentially dangerous software. I would also stick to the runtime only if I were you.
Note I am using JDK8 , which is only developer preview now am I allowed to ship it in my DVD ?
My answer to your main question is: yep, its a tough problem and you're not going to crack it without special measures. One such special measure is to generate an installer using one of the many installer generators you can find with Google. -
I wouldn't do that. Even if it is allowed, which I doubt, you're shipping unfinished and potentially dangerous software. I would also stick to the runtime only if I were you.I know, Sorry I meant shipping JRE only not JDK.My answer to your main question is: yep, its a tough problem and you're not going to crack it without special measures. One such special measure is to generate an installer using one of the many installer generators you can >find with Google.Yes I thought about installers but it would copy my jar and resource files to hard disk which I don't want to avoid piracy. Is there any way to access the rest of the files from DVD directly ?
PS. My DVD vendor promisssed that he would burn them such a way that whole thing can't be copied to hard disk or imaged, I am yet to verify this. -
Neil Ghosh wrote:Distributing your program on a DVD is a bad idea if you want to avoid piracy.
Yes I thought about installers but it would copy my jar and resource files to hard disk which I don't want to avoid piracy.
This discussion has been closed.