title: Mule Groovy script file location works in Studio but not standalone
body: <p>I have a groovy scripting transformer that is in a file stored under src\main\resources.<br>
      <code>&lt;scripting:transformer doc:name="myXform"&gt;<br>
          &lt;scripting:script engine="Groovy"
              file="src\main\resources\myTransform.groovy"&gt;<br>
          &lt;/scripting:script&gt;<br>
      &lt;/scripting:transformer&gt;</code><br>
  My project works as expected within Mule Studio. When I deploy it to the standalone Mule server it fails to deploy as it cannot find the relative file location.<br>
  <em>Failed to load "src\main\resources\myTransform.groovy" from classpath or file system</em>  </p>
  
  <p>I have a couple of questions:<br>
  - Is this the appropriate place to keep my groovy transforms?<br>
  - How do I fix the problem because in the deployed version the src\main\resources exists under META-INF?<br>
  - If it is a classpath setting then what do I change to fix it (.classpath, system variable on standalone server, etc.) ?  </p>
  
  <p>Thank you.  </p>
  
  <p>xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx<br>
  Ok, I reinstalled Mule Studio (Version: 3.5.0 Build Id: 201312091746) and built (using Maven) a vanilla project from scratch:<br>
      `</p>
  
  <pre><code>&lt;mule xmlns:scripting="http://www.mulesoft.org/schema/mule/scripting" xmlns:file="http://www.mulesoft.org/schema/mule/file" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
      xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.1"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
  http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
  http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/current/mule-file.xsd
  http://www.mulesoft.org/schema/mule/scripting http://www.mulesoft.org/schema/mule/scripting/current/mule-scripting.xsd"&gt;
      &lt;flow name="gpFlow1" doc:name="gpFlow1"&gt;
          &lt;file:inbound-endpoint path="H:\DCH_ESB_Test\InMuleTest" responseTimeout="10000" doc:name="FileIn"/&gt;
          &lt;byte-array-to-string-transformer doc:name="Byte Array to String"/&gt;
          &lt;scripting:transformer doc:name="Groovy"&gt;
              &lt;scripting:script engine="Groovy" file="myTransform.groovy"/&gt;
          &lt;/scripting:transformer&gt;
          &lt;file:outbound-endpoint path="H:\DCH_ESB_Test\OutMuleTest" responseTimeout="10000" doc:name="FileOut"/&gt;
      &lt;/flow&gt;
  &lt;/mule&gt;`  
  </code></pre>
  
  <p>myTransform.groovy simply contains <code>return payload.toUpperCase()</code><br>
    The first thing I see is Studio does not like the non-pathed file and flags an error  on the scripting transformer of: "<em>Path does not exist</em>".<br>
  However, when I run the project within Studio it works.<br>
  When deployed I still get:<br>
  `    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++<br>
      + New app 'gp'                                             +<br>
      ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++<br>
      INFO  2014-02-13 10:05:47,282 [Mule.app.deployer.monitor.1.thread.1] org.mule.module.launcher.MuleApplicationClassLoader: [gp] Loading the following jars:<br>
      =============================<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/asm-3.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/cloveretl-engine-3.4.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/commons-logging-1.1.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/ftplet-api-1.0.2.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/ftpserver-core-1.0.2.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/jaxb-impl-2.1.5.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/jaxb-xjc-2.2.5.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/jcl-over-slf4j-1.6.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/jsch-0.1.42.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/mina-core-2.0.0-M6.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/mockito-all-1.9.0.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/mockobjects-core-0.09.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/mule-core-ee-3.4.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/mule-module-boot-ee-3.4.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/slf4j-api-1.6.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/slf4j-log4j12-1.6.1.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/spring-tx-3.0.6.RELEASE.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/spring-web-3.0.6.RELEASE.jar<br>
      file:/C:/mule-enterprise-standalone-3.3.0/apps/gp/lib/sshd-core-0.6.0.jar<br>
      =============================  </p>
  
  <pre><code>ERROR 2014-02-13 10:05:49,294 [Mule.app.deployer.monitor.1.thread.1] org.mule.module.launcher.DeploymentService: Failed to deploy application archive: gp.zip  
  org.mule.module.launcher.DeploymentInitException: InitialisationException: Failed to load "myTransform.groovy" from classpath or file system  
      at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:220)  
      at org.mule.module.launcher.application.ApplicationWrapper.init(ApplicationWrapper.java:64)  
      at org.mule.module.launcher.DefaultMuleDeployer.deploy(DefaultMuleDeployer.java:46)  
      at org.mule.module.launcher.DeploymentService.guardedDeploy(DeploymentService.java:398)  
      at org.mule.module.launcher.DeploymentService.deploy(DeploymentService.java:365)  `  
  </code></pre>
  
  <p>My .classpath file within Studio looks like:<br>
      <code>&lt;classpath&gt;<br>
        &lt;classpathentry kind="src" path="src/main/app" excluding="**/*.java"/&gt;<br>
        &lt;classpathentry kind="src" path="src/main/java"/&gt;<br>
        &lt;classpathentry kind="src" path="src/main/resources" excluding="**/*.java"/&gt;<br>
        &lt;classpathentry kind="src" path="src/test/java" output="target/test-classes"/&gt;<br>
        &lt;classpathentry kind="src" path="src/test/resources" output="target/test-classes" excluding="**/*.java"/&gt;<br>
        &lt;classpathentry kind="output" path="target/classes"/&gt;<br>
        &lt;classpathentry kind="con" path="MULE_RUNTIME"/&gt;<br>
        &lt;classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/asm/asm/3.1/asm-3.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/cloveretl/cloveretl-engine/3.4.1/cloveretl-engine-3.4.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/apache/ftpserver/ftplet-api/1.0.2/ftplet-api-1.0.2.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/apache/ftpserver/ftpserver-core/1.0.2/ftpserver-core-1.0.2.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/sun/xml/bind/jaxb-impl/2.1.5/jaxb-impl-2.1.5.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/sun/xml/bind/jaxb-xjc/2.2.5.1/jaxb-xjc-2.2.5.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/slf4j/jcl-over-slf4j/1.6.1/jcl-over-slf4j-1.6.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/jcraft/jsch/0.1.42/jsch-0.1.42.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/apache/mina/mina-core/2.0.0-M6/mina-core-2.0.0-M6.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/mockito/mockito-all/1.9.0/mockito-all-1.9.0.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/mockobjects/mockobjects-core/0.09/mockobjects-core-0.09.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/mulesoft/muleesb/mule-core-ee/3.4.1/mule-core-ee-3.4.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/com/mulesoft/muleesb/modules/mule-module-boot-ee/3.4.1/mule-module-boot-ee-3.4.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/slf4j/slf4j-api/1.6.1/slf4j-api-1.6.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/slf4j/slf4j-log4j12/1.6.1/slf4j-log4j12-1.6.1.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/springframework/spring-tx/3.0.6.RELEASE/spring-tx-3.0.6.RELEASE.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/springframework/spring-web/3.0.6.RELEASE/spring-web-3.0.6.RELEASE.jar"/&gt;<br>
        &lt;classpathentry kind="var" path="M2_REPO/org/apache/sshd/sshd-core/0.6.0/sshd-core-0.6.0.jar"/&gt;<br>
      &lt;/classpath&gt;</code><br>
  In the export zip file, myTransform.groovy is found under:<br>
  gp.zip\META-INF\src\main\resources\<br>
  I did not reinstall my standalone.  </p>
  
  <p>Thanks,
  -- Don</p>