Stripes

Actions not found on WebLogic 10.0

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: Release 1.5.2
  • Fix Version/s: Release 1.5.3, Release 1.6
  • Component/s: None
  • Labels:
    None

Description

Hi,

Deploying stripes 1.5.2 examples on WebLogic fails as Actions are not discovered at runtime.

Seems the problem is in ResolverUtil.findJarForResource method:

368 protected URL findJarForResource(URL url, String path) throws MalformedURLException {
...

373 for (; { 374 url = new URL(url.getFile()); 375 log.trace("Inner URL: ", url); 376 }

The incoming url might look like this on Tomcat:
jar:file:/C:/apps/tomcat/tmp/WEB-INF/lib/myjar.jar!/com.mycorp.actions

After line 374 is executed the url becomes:
file:/C:/apps/tomcat/tmp/WEB-INF/lib/myjar.jar!/com.mycorp.actions

For WebLogic the incoming url is:
zip:C:/apps/mywar/WEB-INF/lib/mylib.jar!/com.mycorp.actions

Line 374 fails on the first attempt and the url is unchanged.

Later on in the method a check is made whether the url is a jar and on WebLogic the check fails with a FileNotFoundException.
One possible fix is to check for the "zip:" prefix and strip it, creating a new URL:

String urlStr = jarUrl.toString();
if (urlStr.startsWith("zip:")) {
urlStr = urlStr.substring(4);
url = new File(urlStr).toURL();
if (isJar(testUrl)) { return testUrl; }
}

kind regards

bob

Activity

Hide
Bob Schellink added a comment - 31/Oct/09 9:27 PM

Alternatively, instead of checking for the zip prefix a check can be made against the url file attribute since it points to the underlying jar.

For example the WebLogic url might be:
zip:C:/apps/mywar/WEB-INF/lib/mylib.jar!/com.mycorp.actions

Calling url.getFile() returns:
C:/apps/mywar/WEB-INF/lib/mylib.jar!/com.mycorp.actions

Maybe a check can be done against the url.getFile() if isJar fails the first time?

415 // Try to open and test it
416 try {
417 URL testUrl = new URL(jarUrl.toString());
418 if (isJar(testUrl)) { 419 return testUrl; } else {
String pathToUrl = url.getFile();
pathToUrl = ...// extract jar path from string
testUrl = new File(pathToUrl).toURL();
if (isJar(testUrl)) { return testUrl; }
}
420 }
421 catch (MalformedURLException e) { 422 log.warn("Invalid JAR URL: ", jarUrl); 423 }

Show
Bob Schellink added a comment - 31/Oct/09 9:27 PM Alternatively, instead of checking for the zip prefix a check can be made against the url file attribute since it points to the underlying jar. For example the WebLogic url might be: zip:C:/apps/mywar/WEB-INF/lib/mylib.jar!/com.mycorp.actions Calling url.getFile() returns: C:/apps/mywar/WEB-INF/lib/mylib.jar!/com.mycorp.actions Maybe a check can be done against the url.getFile() if isJar fails the first time? 415 // Try to open and test it 416 try { 417 URL testUrl = new URL(jarUrl.toString()); 418 if (isJar(testUrl)) { 419 return testUrl; } else { String pathToUrl = url.getFile(); pathToUrl = ...// extract jar path from string testUrl = new File(pathToUrl).toURL(); if (isJar(testUrl)) { return testUrl; } } 420 } 421 catch (MalformedURLException e) { 422 log.warn("Invalid JAR URL: ", jarUrl); 423 }
Hide
Ben Gunter added a comment - 02/Nov/09 1:38 PM

Another report from the mailing list.
========================================
It seems the new Package Resolver in 1.5.2 doesn't work within
Weblogic 9.2 and 10gR3 when packaged in a war. I can unzip the war and
it works fine. Obviously Weblogic does weird things in deploying wars
and ears. Any Weblogic folks out there know a solution to this issue
to help the developers possibly resolve this?

<Nov 2, 2009 10:43:41 AM EST> <Info> <Deployer> <BEA-149060> <Module
stripes-examples.war of application_appsdir_stripes-examples_war
successfully transitioned from STATE_PREPARED to STATE_ADMIN on server
AdminServer.>
10:43:41,430 DEBUG ResolverUtil:250 - Listing classes in
zip:C:/bea/user_projects/domains/base_domain/servers/AdminServer/tmp/_WL_user/_appsdir_stripes-examples_war/ze9vq/war/WEB-INF/lib/_wl_cls_gen.jar!/net/sourceforge/stripes/examples
<Nov 2, 2009 10:43:41 AM EST> <Error> <HTTP> <BEA-101165> <Could not
load user defined filter in web.xml:
net.sourceforge.stripes.controller.StripesFilter.
net.sourceforge.stripes.exception.StripesRuntimeException: Problem
instantiating default configuration objects.
at net.sourceforge.stripes.config.DefaultConfiguration.init(DefaultConfiguration.java:220)
at net.sourceforge.stripes.config.RuntimeConfiguration.init(RuntimeConfiguration.java:272)
at net.sourceforge.stripes.controller.StripesFilter.init(StripesFilter.java:125)
at weblogic.servlet.internal.FilterManager$FilterInitAction.run(FilterManager.java:309)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
at weblogic.servlet.internal.FilterManager.loadFilter(FilterManager.java:88)
at weblogic.servlet.internal.FilterManager.preloadFilters(FilterManager.java:56)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1618)
at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2761)
at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:889)
at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:333)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:117)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:26)
at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:815)
at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1222)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:433)
at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67)
at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
java.lang.NullPointerException
at java.io.FilterInputStream.read(FilterInputStream.java:111)
at sun.nio.cs.StreamDecoder$CharsetSD.readBytes(StreamDecoder.java:411)
at sun.nio.cs.StreamDecoder$CharsetSD.implRead(StreamDecoder.java:453)
at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:183)
at java.io.InputStreamReader.read(InputStreamReader.java:167)
at java.io.BufferedReader.fill(BufferedReader.java:136)
at java.io.BufferedReader.readLine(BufferedReader.java:299)
at java.io.BufferedReader.readLine(BufferedReader.java:362)
at net.sourceforge.stripes.util.ResolverUtil.listClassResources(ResolverUtil.java:283)
at net.sourceforge.stripes.util.ResolverUtil.find(ResolverUtil.java:225)
at net.sourceforge.stripes.util.ResolverUtil.findImplementations(ResolverUtil.java:185)
at net.sourceforge.stripes.controller.AnnotatedClassActionResolver.findClasses(AnnotatedClassActionResolver.java:676)
at net.sourceforge.stripes.controller.AnnotatedClassActionResolver.init(AnnotatedClassActionResolver.java:115)
at net.sourceforge.stripes.controller.NameBasedActionResolver.init(NameBasedActionResolver.java:125)
at net.sourceforge.stripes.config.DefaultConfiguration.init(DefaultConfiguration.java:121)
at net.sourceforge.stripes.config.RuntimeConfiguration.init(RuntimeConfiguration.java:272)
at net.sourceforge.stripes.controller.StripesFilter.init(StripesFilter.java:125)
at weblogic.servlet.internal.FilterManager$FilterInitAction.run(FilterManager.java:309)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
at weblogic.servlet.internal.FilterManager.loadFilter(FilterManager.java:88)
at weblogic.servlet.internal.FilterManager.preloadFilters(FilterManager.java:56)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1618)
at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2761)
at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:889)
at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:333)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:117)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:26)
at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:815)
at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1222)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:433)
at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67)
at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)

Show
Ben Gunter added a comment - 02/Nov/09 1:38 PM Another report from the mailing list. ======================================== It seems the new Package Resolver in 1.5.2 doesn't work within Weblogic 9.2 and 10gR3 when packaged in a war. I can unzip the war and it works fine. Obviously Weblogic does weird things in deploying wars and ears. Any Weblogic folks out there know a solution to this issue to help the developers possibly resolve this? <Nov 2, 2009 10:43:41 AM EST> <Info> <Deployer> <BEA-149060> <Module stripes-examples.war of application_appsdir_stripes-examples_war successfully transitioned from STATE_PREPARED to STATE_ADMIN on server AdminServer.> 10:43:41,430 DEBUG ResolverUtil:250 - Listing classes in zip:C:/bea/user_projects/domains/base_domain/servers/AdminServer/tmp/_WL_user/_appsdir_stripes-examples_war/ze9vq/war/WEB-INF/lib/_wl_cls_gen.jar!/net/sourceforge/stripes/examples <Nov 2, 2009 10:43:41 AM EST> <Error> <HTTP> <BEA-101165> <Could not load user defined filter in web.xml: net.sourceforge.stripes.controller.StripesFilter. net.sourceforge.stripes.exception.StripesRuntimeException: Problem instantiating default configuration objects. at net.sourceforge.stripes.config.DefaultConfiguration.init(DefaultConfiguration.java:220) at net.sourceforge.stripes.config.RuntimeConfiguration.init(RuntimeConfiguration.java:272) at net.sourceforge.stripes.controller.StripesFilter.init(StripesFilter.java:125) at weblogic.servlet.internal.FilterManager$FilterInitAction.run(FilterManager.java:309) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) at weblogic.servlet.internal.FilterManager.loadFilter(FilterManager.java:88) at weblogic.servlet.internal.FilterManager.preloadFilters(FilterManager.java:56) at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1618) at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2761) at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:889) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:333) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60) at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200) at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:117) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60) at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:26) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:815) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1222) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:433) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67) at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:181) java.lang.NullPointerException at java.io.FilterInputStream.read(FilterInputStream.java:111) at sun.nio.cs.StreamDecoder$CharsetSD.readBytes(StreamDecoder.java:411) at sun.nio.cs.StreamDecoder$CharsetSD.implRead(StreamDecoder.java:453) at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:183) at java.io.InputStreamReader.read(InputStreamReader.java:167) at java.io.BufferedReader.fill(BufferedReader.java:136) at java.io.BufferedReader.readLine(BufferedReader.java:299) at java.io.BufferedReader.readLine(BufferedReader.java:362) at net.sourceforge.stripes.util.ResolverUtil.listClassResources(ResolverUtil.java:283) at net.sourceforge.stripes.util.ResolverUtil.find(ResolverUtil.java:225) at net.sourceforge.stripes.util.ResolverUtil.findImplementations(ResolverUtil.java:185) at net.sourceforge.stripes.controller.AnnotatedClassActionResolver.findClasses(AnnotatedClassActionResolver.java:676) at net.sourceforge.stripes.controller.AnnotatedClassActionResolver.init(AnnotatedClassActionResolver.java:115) at net.sourceforge.stripes.controller.NameBasedActionResolver.init(NameBasedActionResolver.java:125) at net.sourceforge.stripes.config.DefaultConfiguration.init(DefaultConfiguration.java:121) at net.sourceforge.stripes.config.RuntimeConfiguration.init(RuntimeConfiguration.java:272) at net.sourceforge.stripes.controller.StripesFilter.init(StripesFilter.java:125) at weblogic.servlet.internal.FilterManager$FilterInitAction.run(FilterManager.java:309) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) at weblogic.servlet.internal.FilterManager.loadFilter(FilterManager.java:88) at weblogic.servlet.internal.FilterManager.preloadFilters(FilterManager.java:56) at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1618) at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2761) at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:889) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:333) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60) at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200) at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:117) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60) at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:26) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:815) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1222) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:433) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67) at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
Hide
Ben Gunter added a comment - 03/Nov/09 1:04 PM

Bob, can you submit a stack trace for the problem you describe? These two sound similar, but you said you're seeing FileNotFoundException while I'm seeing a NullPointerException in my testing.

Show
Ben Gunter added a comment - 03/Nov/09 1:04 PM Bob, can you submit a stack trace for the problem you describe? These two sound similar, but you said you're seeing FileNotFoundException while I'm seeing a NullPointerException in my testing.
Hide
Ben Gunter added a comment - 03/Nov/09 1:09 PM

Also, Bob, what version of WebLogic are you having this problem on? I'm testing on 10.3.

Show
Ben Gunter added a comment - 03/Nov/09 1:09 PM Also, Bob, what version of WebLogic are you having this problem on? I'm testing on 10.3.
Hide
Ben Gunter added a comment - 03/Nov/09 2:10 PM

Nevermind. I see the FileNotFoundException. I was looking in the wrong place. I'll have a fix ready in a little while.

Show
Ben Gunter added a comment - 03/Nov/09 2:10 PM Nevermind. I see the FileNotFoundException. I was looking in the wrong place. I'll have a fix ready in a little while.
Hide
Ben Gunter added a comment - 03/Nov/09 2:30 PM

I fixed this pretty much as you suggested. Please test against the 1.5.x branch and let me know how it goes.

Show
Ben Gunter added a comment - 03/Nov/09 2:30 PM I fixed this pretty much as you suggested. Please test against the 1.5.x branch and let me know how it goes.
Hide
Bob Schellink added a comment - 03/Nov/09 3:27 PM

Hi Ben,

Thanks for the fix. I'll have a look later today at work. One issue with the fix might be the file.exists() check:

425 jarUrl.replace(0, jarUrl.length(), testUrl.getFile());
426 File file = new File(jarUrl.toString());
427 if (file.exists()) {

I think if jarUrl has spaces the file.exists() check might return false.

For example if WebLogic is installed under c:\Program Files the resulting jarUrl could have spaces encoded e.g: c:\Program%20Files

Decoding the url with URLDecoder should do the trick:

String path = URLDecoder(jarUrl.toString(), "UTF-8");
File file = new File(path);
if (file.exists()) {

kind regards

bob

Show
Bob Schellink added a comment - 03/Nov/09 3:27 PM Hi Ben, Thanks for the fix. I'll have a look later today at work. One issue with the fix might be the file.exists() check: 425 jarUrl.replace(0, jarUrl.length(), testUrl.getFile()); 426 File file = new File(jarUrl.toString()); 427 if (file.exists()) { I think if jarUrl has spaces the file.exists() check might return false. For example if WebLogic is installed under c:\Program Files the resulting jarUrl could have spaces encoded e.g: c:\Program%20Files Decoding the url with URLDecoder should do the trick: String path = URLDecoder(jarUrl.toString(), "UTF-8"); File file = new File(path); if (file.exists()) { kind regards bob
Hide
Ben Gunter added a comment - 04/Nov/09 9:52 AM

Thanks, Bob. I just put some code in to account for possible URL-encoded filenames.

Show
Ben Gunter added a comment - 04/Nov/09 9:52 AM Thanks, Bob. I just put some code in to account for possible URL-encoded filenames.
Hide
Bob Schellink added a comment - 05/Nov/09 2:59 AM

Hi Ben, just tested and it works great. I've tested on WebLogic 10.0 with JRockit 1.5.11.

Thanks again.

bob

Show
Bob Schellink added a comment - 05/Nov/09 2:59 AM Hi Ben, just tested and it works great. I've tested on WebLogic 10.0 with JRockit 1.5.11. Thanks again. bob

People

Vote (0)
Watch (0)

Dates

  • Created:
    31/Oct/09 6:12 AM
    Updated:
    04/Jan/11 1:29 PM
    Resolved:
    03/Nov/09 2:30 PM