Hiding custom Java services

Does anyone know any way how to hide custom Java services codes when it is used within the Integration Server via wM Developer?

Hi Kelvin,

Just remove the .frag,.java from the following locations packages\xyz\ns....*.frag and packages\xyz\code\source.…*.java or while exporting the package, exclude the *.frag, *.java using the filter. Remember that after removing these file, you will not be able to recompile java service.

Let me know if any questions



You can hide the source using ACL also. Create an Group. Add users to it to whom who you want to give the access to read the code. Create an ACL. Assign the new group to this ACL.
Put this ACL as the read ACL for the service you want to hide the source.


One other option, you can create a java service outside of the webMethods tool, make sure the code is in your server classpath (it can reside in a jar even), and place the following node.ndf file (make adjustments to the class and method elements) into your \folder\service directory (encoded):

<?xml version=“1.0”?>
<Values version=“2.0”>
<value name=“node_comment”>Hidden Java Service</value>
<value name=“svc_type”>java</value>
<value name=“svc_subtype”>unknown</value>
<value name=“stateless”>no</value>
<value name=“caching”>no</value>
<value name=“prefetch”>no</value>
<value name=“cache_ttl”>15</value>
<value name=“prefetch_level”>1</value>
<value name=“template_type”>html</value>
<value name=“svc_in_validator_options”>none</value>
<value name=“svc_out_validator_options”>none</value>
<record name=“java_data” javaclass=“com.wm.util.Values”>
<value name=“class”>fully.qualified.java.ClassName</value>
<value name=“method”>yourMethod</value>

You webMethods java service needs to have the following signature:

public static void methodName(com.wm.data.IData pipeline) throws ServiceException;

One other option is to add a file to the directories in your source tree to disable fragging of Java services. This is not a documented capability, but should work for most versions around.

Just add an empty file named .nojfrag to the directories where you have your services defined. It’ll still compile them, but will skip fragmentation of the Java source from that directory and all sub-directories.