• 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

Difference between -D and -X options while passing parameters to JVM.

 
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In maven we use maven_opts to pass parameters to the Java VM.

E.g. : set MAVEN_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000

I am aware of the -D option. It is used to send the java system property. What exactly '-X' option represent?

I am aware of the -Xms, -Xmx options which are used to set the heap size.

In the above example what exaclty the line/point "-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000" represent or what is does?

Thanks in advance.

Regards,
Naresh.
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
X stands for eXtension. Any "X" parameter is vendor-specific, and unlike the other options isn't guaranteed to be available on all JVM implementations - for example, IBM's jikes or the open-source IcedTea VMs.
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So if -X for eXtension, what does -D stands for?
 
Tim Holloway
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Mariana Costa wrote:So if -X for eXtension, what does -D stands for?



"define". I've used it in Kettle to pass in alternative package paths for custom plugins when I didn't want them in the main Kettle package hierarchy.
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The -D is used to set system properties. Any Java code can then access any property so defined via System.getProperty().
 
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And welcome to Javaranch Mariana!
 
Mariana Costa
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Tim Holloway wrote:

Mariana Costa wrote:So if -X for eXtension, what does -D stands for?



"define". I've used it in Kettle to pass in alternative package paths for custom plugins when I didn't want them in the main Kettle package hierarchy.



Ah, "Define"! Very creative =)
Thanks Tom.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic