<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    Running Seam 2 archives on Jboss 7
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="http://community.jboss.org/people/matt.drees">Matt Drees</a> in <i>JBoss AS7 Development</i> - <a href="http://community.jboss.org/message/608573#608573">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>Hi all,</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>My app is a Seam 2 war.&#160; I've found I can deploy it to AS7 successfully as an exploded directory, but not as a war archive.&#160; When I try to deploy as an archive, I get a stacktrace like this:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><pre class="jive-pre"><code class="jive-code">15:31:21,837 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/ccp]] (MSC service thread 1-3) Exception sending context
initialized event to listener instance of class org.jboss.seam.servlet.SeamListener: java.lang.RuntimeException: Error handling file /content/ccp.war/WEB-INF/lib/jboss-seam-ui-2.2.2.Final.seam2jsf2.jar
&#160;&#160;&#160; at org.jboss.seam.deployment.URLScanner.handleArchiveByFile(URLScanner.java:134) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.jboss.seam.deployment.URLScanner.handle(URLScanner.java:107) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.jboss.seam.deployment.URLScanner.scanResources(URLScanner.java:90) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.jboss.seam.deployment.StandardDeploymentStrategy.scan(StandardDeploymentStrategy.java:119) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.jboss.seam.init.Initialization.create(Initialization.java:130) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.jboss.seam.servlet.SeamListener.contextInitialized(SeamListener.java:36) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3368) [jbossweb-7.0.0.CR1.jar:7.0.0.Beta4-SNAPSHOT]
&#160;&#160;&#160; at org.apache.catalina.core.StandardContext.start(StandardContext.java:3817) [jbossweb-7.0.0.CR1.jar:7.0.0.Beta4-SNAPSHOT]
&#160;&#160;&#160; at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:70) [jboss-as-web-7.0.0.Beta4-SNAPSHOT.jar:7.0.0.Beta4-SNAPSHOT]
&#160;&#160;&#160; at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1675)
&#160;&#160;&#160; at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_24]
&#160;&#160;&#160; at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_24]
&#160;&#160;&#160; at java.lang.Thread.run(Thread.java:680) [:1.6.0_24]
Caused by: java.util.zip.ZipException: error in opening zip file
&#160;&#160;&#160; at java.util.zip.ZipFile.open(Native Method) [:1.6.0_24]
&#160;&#160;&#160; at java.util.zip.ZipFile.&lt;init&gt;(ZipFile.java:127) [:1.6.0_24]
&#160;&#160;&#160; at java.util.zip.ZipFile.&lt;init&gt;(ZipFile.java:144) [:1.6.0_24]
&#160;&#160;&#160; at org.jboss.seam.deployment.URLScanner.handleArchiveByFile(URLScanner.java:123) [jboss-seam-2.2.2.Final.seam2jsf2-no-timer-service-dispatcher.jar:]
&#160;&#160;&#160; ... 12 more
</code></pre><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>The stacktrace doesn't show it, but the URLScanner is trying to handle this URL: </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><pre class="jive-pre"><code class="jive-code">vfs:/content/ccp.war/WEB-INF/lib/jboss-seam-ui-2.2.2.Final.seam2jsf2.jar/META-INF/components.xml
</code></pre><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>URLScanner is trying to treat this as if it's a file url, and of course ZipFile.open() can't find this file on the real filesystem.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>I believe Jboss AS 5 and 6 had a <a class="jive-link-external-small" href="http://anonsvn.jboss.org/repos/jbossas/projects/jboss-seam-int/tags/6.0.0.GA/jbossas/src/main/java/org/jboss/seam/integration/jbossas/vfs/VFSScanner.java">special Scanner implementation</a> to enable Seam to read archive deployments.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Is a similar scanner planned for AS 7?</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Thanks!</p><p>-Matt</p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/608573#608573">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss AS7 Development at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2225">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>