Win a copy of Programmers Guide to Apache Thrift this week in the Open Source forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

Re: JDK in WSAD  RSS feed

 
Ranch Hand
Posts: 104
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear all,

How can I know the versions of J2SE and J2EE used in WSAD installed on my PC?

Thanks,
Joe
 
author & internet detective
Posts: 39281
727
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Joe,
The versions of J2SE and J2EE are tied to the version of WSAD. The two most recent ones are posted below. If your WSAD version isn't one of these, post it. Someone (maybe even me) will know.

WSAD 5.1 - J2SE 1.3 - J2EE 1.4
WSAD 5.1.2 - J2SE 1.4 - J2EE 1.4
 
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Jeanne Boyarsky:
The versions of J2SE and J2EE are tied to the version of WSAD.



I think this is not really true. Even if there's a default JDK per version, there's also the possibility to change it according to your needs.

Window > Preferences > Java > Installed JRE's give the list of the available JREs. The one checked is used for both compilation and runtime.
 
Jeanne Boyarsky
author & internet detective
Posts: 39281
727
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Jean-Louis Marechaux:
I think this is not really true. Even if there's a default JDK per version, there's also the possibility to change it according to your needs.


Sort of. You can change the JDK for compiling and running code with as an application. However, you cannot change the JDK the server uses (in any way supported by IBM.) As J2EE programs use the server, this effectively restricts you to the version of java supported by that version of WSAD.
 
JeanLouis Marechaux
Ranch Hand
Posts: 906
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Jeanne Boyarsky:

Sort of. You can change the JDK for compiling and running code with as an application. However, you cannot change the JDK the server uses (in any way supported by IBM.) As J2EE programs use the server, this effectively restricts you to the version of java supported by that version of WSAD.



Fully agree with you Jeanne. I was refering to WSAD. As far as WAS itself is concerned, you cannot change the JDK
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the WSAD 5.1

I believe you choose the JDK you want.

In the PROJECT --> PROPERTIES --> Under Java Compiler CLICK on the Project Setting and CLick on the COMPLIANCE and CLASSIFIES you can select the JDK you want.

Hope this helpls!!.

Thanks
-Venky
 
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm a little confused about this.


WSAD 5.1 - J2SE 1.3 - J2EE 1.4
WSAD 5.1.2 - J2SE 1.4 - J2EE 1.4



I am running WSAD 5.1.2 and when I create a new J2EE project I can choose between J2EE 1.2 or 1.3. I have no option to create a J2EE 1.4 project. What am I missing?

I do see how you can change your compiler to switch between JDK 1.3 and 1.4. If you compile as 1.4, does this mean that you use anything from J2SE 1.4.0 - 1.4.2?

Jay
 
Jeanne Boyarsky
author & internet detective
Posts: 39281
727
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jay,
That should have read J2EE 1.3 for both. I had just heard Sun talk about 1.5 and got a bit confused.

Note that WSAD does support the version I mentioned and one lower so you can upgrade your IDE before your server.

Sorry,
Jeanne
 
J Haley
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok, thanks but I still have something that I don't 100% understand is this true?

I do see how you can change your compiler to switch between JDK 1.3 and 1.4. If you compile as JDK 1.4, does this mean that you use anything from J2SE 1.4.0 - 1.4.2?

Jay
 
Ranch Hand
Posts: 724
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
WSAD 5.1.2 uses J2EE 1.3

How differs J2SE 1.4.0 and 1.4.2 ?
 
J Haley
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not saying that it does. That's not the point I'm trying to understand. I'm not entirely clear what flipping the complier from 1.3 to 1.4 does. I'm guessing that if you compile as 1.4 that means that you are using j2se 1.4. I think I'm having confusing revolving around how j2se and jre version come into play.

I do understand that with WAS 5.1.2 you can run j2ee 1.2 or 1.3 projects.

Ray
 
Jeanne Boyarsky
author & internet detective
Posts: 39281
727
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jay/Ray, [are you two people sharing an account or is one a typo? ]

Note that we are discussing WSAD (the IDE), not WAS (the app server.) WAS doesn't have a compiler, so the point is moot there.

Let's try an example. You have been developing with WSAD 5.1. It only supports JDK 1.3. You decide to upgrade to WSAD 5.1.2. When you first import your code, you get errors. For example, the "assert" keyword is new in 1.4. So if that was in your code, it will cause problems. You do want to change the code, but you are busy now. So you compile in "1.3 mode." This uses a 1.3 compiler so things are backward compatible. Then when you have time, you upgrade the code and switch to the 1.4 compiler.

The JRE used by the server (WSAD test environment) is always 1.4. You can't swap this out.
 
J Haley
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Typo on my part.

Ok, I think I finally get it. But if I understand correctly based on your example if you were developing in WSAD 5.1 you could not have used "assert" since it did not come into play until jdk 1.4. So if you wanted to use "assert" you would need to move up to WSAD 5.1.2 and compile under 1.4 mode. Right?

Thanks for you help.

Jay
 
Jeanne Boyarsky
author & internet detective
Posts: 39281
727
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by J Haley:
Ok, I think I finally get it. But if I understand correctly based on your example if you were developing in WSAD 5.1 you could not have used "assert" since it did not come into play until jdk 1.4. So if you wanted to use "assert" you would need to move up to WSAD 5.1.2 and compile under 1.4 mode. Right?


Right!
 
Don't mess with me you fool! I'm cooking with gas! Here, read this tiny ad:
ScroogeXHTML - small and flexible RTF to HTML converter library
https://coderanch.com/t/710903/ScroogeXHTML-RTF-HTML-XHTML-converter
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!