title: How can I set a WebSphere classloader policy to PARENT_LAST for an app created in Eclipse?
body: <p>Our company is currently using RAD to develop our Java apps, but we're looking to move to Eclipse with the WebSphere Developer Tools. The pilot for our transition is going pretty well, except we're running into a classloader policy issue for new applications that are originally created in Eclipse, not RAD. Our projects that were originally created by RAD are deployed with the correct classloader policy (PARENT_LAST) when published via Eclipse because we originally used the Deployment Descriptor Editor in RAD which set the proper classloader policy in <code>/src/main/application/META-INF/ibmconfig/cells/defaultCell/applications/defaultApp/deployments/defaultApp/deployment.xml</code>. But now with Eclipse &amp; WebSphere Developer Tools, we no longer have the nice Deployment Descriptor Editor UI to create or modify this file for us (apparently <a href="https://www.ibm.com/developerworks/community/forums/html/topic?id=72758e1c-8868-4b5e-9c99-f539882db6ca">it's not included with the WDT plugin</a>).</p>
  
  <p>So, my question then is what is the best way to go about setting this classloader policy? We still need some new apps to have the classloader policy of PARENT_LAST set when we deploy them to our local servers. Our team has though about this a bit and we can see 4 options at the moment.</p>
  
  <ol>
  <li>Open the Admin Console after every publish and change it. This would be a huge pain, and is pretty much not even a real option.</li>
  <li>Change the server profile setting to use a PARENT_LAST classloader policy for all apps. This however is not the case for all the apps at our company, and would not work for all groups.</li>
  <li>Run a jython script after every publish to set the classloader policy. This is slightly better than option 1, but not by much.</li>
  <li>Manually create a deployment.xml file in the same location as the other apps created by RAD with the same structure as the deployment.xml files created by RAD, and modify it as necessary for each app.</li>
  </ol>
  
  <p>Option 4 seems to be the best of the bunch, but it's still a manual process and somewhat error prone. Even if most of our developers can grok this approach for new apps, it would be most ideal if this were a simple one button click type process.</p>
  
  <p>So given the fact that IBM has omitted the Deployment Descriptor Editor from the WDT plugin it would seem as if option 4 is our only hope, but I'll ask once more, is there any other better way to set a WebSphere classloader policy to PARENT_LAST for an app when that app is created in Eclipse? Any help is appreciated, thanks.</p>