Changeset 613


Ignore:
Timestamp:
Mar 13, 2015, 3:24:44 PM (9 years ago)
Author:
djay
Message:

Fix typo and update the Java part of the documentation.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/docs/services/howtos.txt

    r596 r613  
    204204----
    205205
     206Specifically for the Java support, you may add the following two
     207sections to your ``main.cfg`` file:
     208
     209:[javaxx]:
     210   This section is used to pass -XX:* parameters to the JVM  created by the
     211   ZOO-Kernel to handle your ZOO-Service (see `ref. 1
     212   <http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html#BehavioralOptions>`__
     213   or `ref. 2
     214   <http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html#PerformanceTuning>`__
     215   for sample available).
     216   For each map ``a = b`` available in the ``[javaxx]`` section, the
     217   option ``-XX:a=b`` will be passed to the JVM. In case of a map ``a =
     218   minus`` (respectively ``a=plus``) then the option ``-XX:-a``
     219   (respectivelly ``-XX:+a``) will be passed.
     220:[javax]:
     221   The section is used to pass -X* options to the JVM (see
     222   `ref. <http://docs.oracle.com/cd/E22289_01/html/821-1274/configuring-the-default-jvm-and-java-arguments.html>`__). For
     223   each map ``a = b`` available in the ``[javax]`` section, the option
     224   ``-Xab`` will be passed to the JVM (ie. set ``mx=2G`` to pass
     225   ``-Xmx2G``).
     226
    206227ZOO-API
    207228*******
    208229
    209 Before you build your first ZOO-Service implemented inn Java, it is
     230Before you build your first ZOO-Service implemented in Java, it is
    210231recommended that you first build the ZOO class of the Java ZOO-API.
    211232
     
    228249
    229250.. Note:: For each Service provided by your ZOO Java Services Provider
    230           (your corresponding Java class), the ZCFG File must be
    231           named the same as the Java public method name (also the
    232           case of characters is important).
     251          (your corresponding Java class), the ZCFG File should have
     252          the name of the Java public method corresponding to the
     253          service (case-sensitive).
    233254
    234255The ZCFG file should contain the following :
     
    239260    The name of the Java class to use as a ZOO Service Provider. For instance, if your
    240261    java class, located in the same directory as your ZOO-Kernel, was
    241     named ``HelloWorld.class`` then you should use ``HelloWorld``.
     262    named ``HelloJava.class`` then you should use ``HelloJava``.
    242263
    243264Java Data Structure used
  • trunk/zoo-project/zoo-kernel/service_internal_java.c

    r580 r613  
    303303 * Create a string containing the JVM -XX:* option for a given map
    304304 * Depending on the map' name:
    305  *  - in case the value is minus then the reult will be : -XX:-name
    306  *  - in case the value is plus then the reult will be : -XX:+name
    307  *  - in other cases the reult will be : -XX:name=value
     305 *  - in case the value is minus then the result will be : -XX:-name
     306 *  - in case the value is plus then the result will be : -XX:+name
     307 *  - in other cases the result will be : -XX:name=value
    308308 *
    309309 * @param m the map containing the option
     
    322322
    323323/**
    324  * Create a string containing the JVM -X*:* option for a given map.
    325  * The reult will be in the following format: -Xname:value
     324 * Create a string containing the JVM -X** option for a given map.
     325 * The result will be in the following format: -Xnamevalue
    326326 *
    327327 * @param m the map containing the option
    328  * @return a char* containing the valide JVM option (-XX:*)
     328 * @return a char* containing the valide JVM option (-X**)
    329329 */
    330330char *parseJVMXOption(map* m){
    331331  char *res=(char*)malloc((strlen(m->name)+strlen(m->value)+5)*sizeof(char));
    332   sprintf(res,"-X%s:%s",m->name,m->value);
     332  sprintf(res,"-X%s%s",m->name,m->value);
    333333  return res;
    334334}
Note: See TracChangeset for help on using the changeset viewer.

Search

Context Navigation

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png