• 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
  • Paul Clapham
  • Tim Cooke
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Frank Carver
  • Henry Wong
  • Ron McLeod
Saloon Keepers:
  • Tim Moores
  • Frits Walraven
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Himai Minh

JDK compatibilty

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There are ROCKIT JDK ,IBM JDK and our oracle JDK so is is there compatibility between this generated byte codes ?
for example if i compile my code on IBM JDK or ROCKIT JDK then will my oracle jdk execute that byte code ?
 
Bartender
Posts: 3225
34
IntelliJ IDE Oracle Spring Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We have OpenJDK as well which is the reference implementation for the Java language specifications. The different JDK flavours should follow the Java language specification in terms of supporting the language and the byte code format. So if your target platform has all the required libraries which are being used by your application then the compiled java code should run across the JVM platforms (for the same JDK version).

You might have seen that we can use OpenJDK and compile the code and run it on OracleJDK (though there are subtle differences between the two).

This is a most unlikely practical scenario where you develop and build against one JDK platform and deploy on another JDK platform. You should keep your development, test and production platforms similar so that you don't end up with surprises when your code goes into production.
 
kishan Jaiswal
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
are you trying to say that there is OPENJDK by which must be followed by IBM JDK,JROCKIT JDK,and ORACLE JDK ?
 
Saloon Keeper
Posts: 7413
170
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Any implementation that wants to call itself Java (like OpenJDK, JRockit, IBM) must pass Oracle's TCK - that guarantees wide-ranging compatibility. While I don't have experience with the latter two, IMO you're more likely to run into differences between operating systems (like developing on Windows or OS X and deploying on Linux) than differences between developing on, say, OpenJDK and deploying on JRockit.
 
Switching from electric heat to a rocket mass heater reduces your carbon footprint as much as parking 7 cars. Tiny ad:
Garden Master Course kickstarter
https://coderanch.com/t/754577/Garden-Master-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic