Re: [jboss-dev-forums] [JBoss Microcontainer Development] - ShrinkWrapDeployer
by John Bailey
John Bailey [http://community.jboss.org/people/johnbailey] replied to the discussion
"ShrinkWrapDeployer"
To view the discussion, visit: http://community.jboss.org/message/540890#540890
--------------------------------------------------------------
ALR and I discussed this a couple weeks ago. One thought I had was to change the flow of the deployers to better handle/fit the VFS mounting model. This was also discussed during the VFS3 integration work. It would be ideal if the structure deployers were not forced to execute prior to invoking the rest of the deployers, but rather functioned as any other deployer based on inputs/outputs. The idea was to initiate the deployment with some specific metadata that describes deployment (file, directory, SWArchive, etc..). There would then be a series of deployers which look for these specific metadata types and would invoke the proper VFS mount/unmount operations for the deployment. Once the mount is performed, there would be an output that could be attached to inform the structure deployer to get fired. The structure deployes would get fired and the process would continue its normal flow.
The key change is to align the structure deployers with the Deployer API and actually have deploy and undeploy operations. Then you can introduce deployers in front of structure determination to handle proper mounting With this change, all that would be needed to integrate the ShrinkWrap Archive deployment would be to create the deployment (in embedded, TorqueBox, etc.) with an attachment that would cause a special mounting deployer to pick up and mount the ArchiveFileSystem as apposed to the normal filesystem based mounting deployers.
I realize this is a bit larger change than is being discussed with regard to the SW archives, but it also seems like it would better support the mount operations. Best of all, it would get rid of the Automounter.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/540890#540890]
Start a new discussion in JBoss Microcontainer Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 11 months
[JBoss Web Development] - Failed to load: org.jboss.ws.tools.jaxws.impl.JBossWSProviderFactoryImpl
by Todd Prickett
Todd Prickett [http://community.jboss.org/people/tprickett] created the discussion
"Failed to load: org.jboss.ws.tools.jaxws.impl.JBossWSProviderFactoryImpl"
To view the discussion, visit: http://community.jboss.org/message/540889#540889
--------------------------------------------------------------
All,
I'm using JBoss 5.1, JBossWS 3.3 (native), Sun Java 1.6, Windows XP, and Maven 2. Attempting to do a wsprovide in Maven I'm getting the error:
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error while running wsconsume
Embedded error: Failed to load: org.jboss.ws.tools.jaxws.impl.JBossWSProviderFactoryImpl
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error while running wsconsume
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:584)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:500)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:479)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:292)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error while running wsconsume
at org.jboss.ws.plugins.tools.AbstractWsProvideMojo.execute(AbstractWsProvideMojo.java:100)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
... 16 more
Caused by: java.lang.IllegalStateException: Failed to load: org.jboss.ws.tools.jaxws.impl.JBossWSProviderFactoryImpl
at org.jboss.wsf.spi.util.ServiceLoader.loadDefault(ServiceLoader.java:236)
at org.jboss.wsf.spi.util.ServiceLoader.loadFromSystemProperty(ServiceLoader.java:169)
at org.jboss.wsf.spi.util.ServiceLoader.loadService(ServiceLoader.java:77)
at org.jboss.wsf.spi.tools.WSContractProvider.newInstance(WSContractProvider.java:86)
at org.jboss.wsf.spi.tools.WSContractProvider.newInstance(WSContractProvider.java:70)
at org.jboss.ws.plugins.tools.AbstractWsProvideMojo.execute(AbstractWsProvideMojo.java:93)
... 18 more
Caused by: java.lang.ClassNotFoundException: org.jboss.ws.tools.jaxws.impl.JBossWSProviderFactoryImpl
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at org.jboss.wsf.spi.util.SecurityActions.loadClass(SecurityActions.java:123)
at org.jboss.wsf.spi.util.ServiceLoader.loadDefault(ServiceLoader.java:231)
... 23 more
My maven pom file contains the section:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<compilerargument>
-Djava.endorsed.dirs=C:/jboss-5.1.0.GA/lib/endorsed
</compilerargument>
</configuration>
</plugin>
<plugin>
<groupId>org.jboss.ws.plugins</groupId>
<artifactId>maven-jaxws-tools-plugin</artifactId>
<version>1.0.0.GA</version>
<configuration>
<verbose>true</verbose>
<endpointClass>com.sperbolink.ws.MyWebService</endpointClass>
<generateWsdl>true</generateWsdl>
<verbose>true</verbose>
<outputDirectory>src/main/resources</outputDirectory>
<sourceDirectory>src/main/java</sourceDirectory>
</configuration>
<executions>
<execution>
<goals>
<goal>wsprovide</goal>
</goals>
</execution>
</executions>
</plugin>
:
:
:
Try as I might, I cannot find the JBossWSProviderFactoryImpl class.
Can anyone help?
TIA
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/540889#540889]
Start a new discussion in JBoss Web Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 11 months
Re: [jboss-dev-forums] [JBoss Microcontainer Development] - ShrinkWrapDeployer
by Andrew Rubinger
Andrew Rubinger [http://community.jboss.org/people/ALRubinger] replied to the discussion
"ShrinkWrapDeployer"
To view the discussion, visit: http://community.jboss.org/message/540878#540878
--------------------------------------------------------------
Realtime discussion:
(04:10:23 PM) ALR@MSN: About ShrinkWrapDeployer: let me ask you:
(04:10:30 PM) Ales: shoot
(04:10:35 PM) ALR@MSN: Where's the component that bridges VFS inputs to the Deployers ?
(04:10:47 PM) Ales: vfs inputs?
(04:10:51 PM) ALR@MSN: VirtualFile.
(04:10:55 PM) ALR@MSN: How do you deploy one?
(04:11:07 PM) Ales: VFSDeployment extends Deployment
(04:11:17 PM) ALR@MSN: Right. Where does VFSDeployment live?
(04:11:27 PM) Ales: jboss-deployers-vfs-spi
(04:11:42 PM) ALR@MSN: Where should the component that bridges SW Archive inputs to Deployers be?
(04:12:02 PM) Ales: hmmm ...
(04:12:13 PM) ALR@MSN: Say it.
(04:12:16 PM) Ales: hehe
(04:12:16 PM) ALR@MSN: jboss-deployers-shrinkwrap. ;D
(04:12:19 PM) Ales: hmmmm ...
(04:12:21 PM) Ales: nope
(04:12:24 PM) ALR@MSN: Hahahahaha!
(04:12:33 PM) Ales: vfs spi is really a spi ... and it has actual impl
(04:12:45 PM) Ales: whereas your sw stuff is wrapper/facade
(04:12:50 PM) ALR@MSN: ShrinkWrapDeployers is just an impl.
(04:12:56 PM) ALR@MSN: The SPI part is yes, a wrapper.
(04:13:03 PM) ALR@MSN: But there's only one reason why:
(04:13:21 PM) ALR@MSN: I need to mount and unmount archives as VFS alongside the deployment/undeployment process
(04:13:36 PM) ALR@MSN: So I can't make the equivalent of VFSDeploymentFactory and call it a day.
(04:13:45 PM) Ales: true
(04:13:48 PM) ALR@MSN: On undeploy we need to unmount.
(04:14:18 PM) Ales: your SW is just another api for VFS
(04:14:27 PM) ALR@MSN: Correct.
(04:14:32 PM) Ales: hence it's a wrapper/facade
(04:14:39 PM) ALR@MSN: Well, no.
(04:14:45 PM) ALR@MSN: SW doesn't wrap VFS.
(04:14:47 PM) Ales: if we didn't have vfs, then I would say yes, put it into deployers
(04:14:51 PM) Ales: but we a;ready have vfs
(04:14:53 PM) ALR@MSN: We have, however, a VFS adaptor
(04:15:17 PM) Ales: yeah, you need to adapt Archive to VFSDeployment
(04:15:27 PM) ALR@MSN: Right.
(04:15:34 PM) Ales: == facade
(04:15:44 PM) ALR@MSN: And if not for the unmounting, I could do it the same way as in VFSDeploymentFactory
(04:15:58 PM) ALR@MSN: With no new deploy/undeploy APIs.
(04:16:18 PM) Ales: why's that?
(04:16:33 PM) Ales: why is mounting/unmoounting an issue?
(04:16:37 PM) ALR@MSN: VFSDeployment deployment = ShrinkWrapDeploymentFactory.createDeployment(archive); // Easy
(04:16:49 PM) ALR@MSN: Because I need to mount it using a ShrinkWrap extension.
(04:16:58 PM) ALR@MSN: ArchiveFileSystem.
(04:17:10 PM) ALR@MSN: Which is what enables VFS to read SW
(04:17:41 PM) ALR@MSN: You guys do inspection to mountReal or mountJar or something.
(04:17:47 PM) Ales: aha, so when asked if it's already mounted, it says true
(04:17:54 PM) Ales: hence it doesn't do mounting
(04:18:01 PM) ALR@MSN: "it"?
(04:18:17 PM) Ales: mounting mechanism inside deployers
(04:18:21 PM) ALR@MSN: After it comes into MainDeployer, nothing will mount it, yes.
(04:18:32 PM) ALR@MSN: We mount.
(04:18:56 PM) Ales: if you didn't?
(04:19:06 PM) ALR@MSN: Then something in deployers would need to.
(04:19:10 PM) Ales: i guess structiure deployers would try and fail?
(04:19:14 PM) ALR@MSN: And unmount it when undeployed.
(04:19:26 PM) ALR@MSN: Right. getChildren would return nothing.
(04:19:31 PM) Ales: no
(04:19:53 PM) Ales: see AbstractVFSArchiveStructureDeployer
(04:20:57 PM) ALR@MSN: http://fisheye.jboss.org/browse/JBossAS/projects/jboss-deployers/trunk/de... http://fisheye.jboss.org/browse/JBossAS/projects/jboss-deployers/trunk/de...
(04:21:01 PM) ALR@MSN: So why "no"?
(04:21:50 PM) Ales: it would try to mount
(04:21:53 PM) Ales: and probably fail
(04:21:55 PM) Ales: or not?
(04:21:58 PM) ALR@MSN: Oh, right
(04:22:05 PM) ALR@MSN: Because it'd be using the wrong FileSystem.
(04:22:09 PM) Ales: yes
(04:22:47 PM) ALR@MSN: I have no qualms with removing the wrapper API
(04:22:59 PM) ALR@MSN: If you wanna make structure deployers figure out how to mount it properly
(04:22:59 PM) Ales: perhaps this should made possible
(04:23:04 PM) Ales: yes
(04:23:05 PM) Ales: exactly
(04:23:10 PM) ALR@MSN: But I assumed you didn't wanna back that logic in.
(04:23:21 PM) Ales: didn't think of that
(04:23:41 PM) Ales: how would we recognize which FS we need to mount?
(04:23:43 PM) Ales: hmmm ...
(04:23:45 PM) ALR@MSN: No idea.
(04:23:48 PM) Ales: :-)
(04:24:07 PM) ALR@MSN: VirtualFile is just a pointer.
(04:24:15 PM) ALR@MSN: You'd have to rely on exceptions for flow control.
(04:24:25 PM) ALR@MSN: ie. try and catch the exception if it's not a SW archive.
(04:24:33 PM) ALR@MSN: Which is no good solution.
(04:25:07 PM) Ales: i'll think about it a bit
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/540878#540878]
Start a new discussion in JBoss Microcontainer Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 11 months