Posted on 2006-04-26
Last Modified: 2013-11-23

I'm puzzled with when I need to install JDK, when JRE for a client.

I have a program written, but it seems to be only workable on a PC installed with JDK, not JRE. Can someone tell me why? What could have happened? What I should look out in my code such that I can make it to run only on JRE?

Question by:amai
    LVL 3

    Accepted Solution

    JDK = Java Development Kit

    JRE = Java Runtime Environment

    Use JDK To develop applications - it has a compiler (javac)

    Use JRE to run applications - it is simply the runtime environment for executing applications and applets.

    Some applications such as Apache Tomcat require a JDK to run because Tomcat itself uses the java compiler to compile servlets.
    LVL 92

    Assisted Solution

    > I have a program written, but it seems to be only workable on a PC installed with JDK, not JRE.

    That shouldn't be the case, what problems are you having running it on box with just JRE?

    Author Comment

    no errors... it just start, and then close by itself... but on the machines that i have JDK installed... it's running fine...
    LVL 92

    Expert Comment

    how are you starting it?

    Author Comment

    oh... i realized it's not the jdk/jre issue...

    it's the way the program is written... i can only run it on the PC that is the server..


    Author Comment

    oops.. so sorry everyone.. it's because of an error in the config file for connection to the MOM. Thanks for all your efforts!
    LVL 30

    Expert Comment

    Though in certain cases you will need a JDK (e.g. if you have an application which compiles some source-code on the fly and loads the newly compiled classes).

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
    Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
    Video by: Michael
    Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
    This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now