facebook

XDoclet Failing Part II WebSpherewebxml portion

  1. MyEclipse IDE
  2.  > 
  3. Java EE Development (EJB, JSP, Struts, XDoclet, etc.)
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #264678 Reply

    Russ
    Member

    We are porting projects over to MyEclipse and regenerating binding and extentsion files for WebSphere. I have the EJB Project generating the files using XDoclet’s websphere subtask. Now, I am trying to generate the ibm-web-bnd.xmi and ibm.web-ext.xmi files using the webspherewebxml subtask. I have not changed any of the original XDoclet commands within the source code as it was working within WSAD. However, I Run XDoclet within MyEclipse for the web project and I get the following error:

    
    [webdoclet] (XDocletMain.start                   53  ) Running XDoclet failed.
    [webdoclet] (XDocletMain.start                   54  ) <<XDtWebSphere.forAllResourceRefs can only be used inside XDtWebSphere.forAllTags>>
    [webdoclet] C:\ProjectWorkSpaceForMyEclipse\ProjectWeb\.xdoclet-build.tmp.xml:99: XDoclet failed.
    [webdoclet] at xdoclet.DocletTask.start(DocletTask.java:471)
    [webdoclet] at xjavadoc.ant.XJavadocTask.execute(XJavadocTask.java:105)
    [webdoclet] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
    [webdoclet] at org.apache.tools.ant.Task.perform(Task.java:364)
    [webdoclet] at org.apache.tools.ant.Target.execute(Target.java:341)
    [webdoclet] at org.apache.tools.ant.Target.performTasks(Target.java:369)
    [webdoclet] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
    [webdoclet] at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
    [webdoclet] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40)
    [webdoclet] at org.eclipse.ant.internal.ui.antsupport.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
    [webdoclet] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
    [webdoclet] at org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.run(InternalAntRunner.java:423)
    [webdoclet] at org.eclipse.ant.internal.ui.antsupport.InternalAntRunner.main(InternalAntRunner.java:137)
    [webdoclet] Caused by: xdoclet.XDocletException: XDtWebSphere.forAllResourceRefs can only be used inside XDtWebSphere.forAllTags
    [webdoclet] at xdoclet.modules.ibm.websphere.ejb.WebSphereTagsHandler.forAllResourceRefs(WebSphereTagsHandler.java:38)
    
    
    [webdoclet] --- Nested Exception ---
    [webdoclet] xdoclet.XDocletException: XDtWebSphere.forAllResourceRefs can only be used inside XDtWebSphere.forAllTags
    [webdoclet] at xdoclet.modules.ibm.websphere.ejb.WebSphereTagsHandler.forAllResourceRefs(WebSphereTagsHandler.java:38)
    

    Are u aware of any errors with XDoclet’s webspherewebxml subtask?

    Thank you as always for taking the time to read my post.

    Russ

    #264680

    Russ
    Member

    This is the binding file generated:

    
    <webappbnd:WebAppBinding xmi:version="2.0"
       xmlns:xmi="http://www.omg.org/XMI"
       xmlns:webappbnd="webappbnd.xmi"
       xmlns:webapplication="webapplication.xmi"
       xmlns:commonbnd="commonbnd.xmi"
       xmlns:common="common.xmi"
       xmi:id="WebApp_ID_Bnd"
       virtualHostName="default_host"
    >
    
       <webapp href="WEB-INF/web.xml#web-app_1"/>
    
       <resRefBindings xmi:id="ResRefBnd_1" jndiName="">
          <bindingResourceRef href="WEB-INF/web.xml#ResRef_1"/>
       </resRefBindings>
    
       <resRefBindings xmi:id="ResRefBnd_2" jndiName="">
          <bindingResourceRef href="WEB-INF/web.xml#ResRef_2"/>
       </resRefBindings>
    
       <resRefBindings xmi:id="ResRefBnd_3" jndiName="java:/mydatabase">
          <bindingResourceRef href="WEB-INF/web.xml#ResRef_3"/>
       </resRefBindings>
    
    </webappbnd:WebAppBinding>
    
    
    It does not seem to difficult.
    

    This sis the extension xmi

    
    <?xml version="1.0"?>
    
    <webappext:WebAppExtension
        xmi:version="2.0"
        xmlns:xmi="http://www.omg.org/XMI"
        xmlns:webappext="webappext.xmi"
        xmlns:webapplication="webapplication.xmi"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmi:id="WebApp_ID_Ext"
        reloadInterval="3"
        reloadingEnabled="true"
        fileServingEnabled="true"
        directoryBrowsingEnabled="true"
        serveServletsByClassnameEnabled="true"
        preCompileJSPs="true"
        autoRequestEncoding="false"
        autoResponseEncoding="false"
        autoLoadFilters="false">
    
        <webApp href="WEB-INF/web.xml#web-app_1"/>
    
        <resourceRefExtensions xmi:id="ResourceRef_ext_1"
    

    I’ve concluded it is having a hard time finding the first resource reference.

    #264681

    Russ
    Member

    Looks like another bug in XDoclet. This time it’s for webspherewebxml.

    XDT-1595 Unable to generate websphere deploymentdescriptor (ibm-web-ext.xmi)

    http://opensource.atlassian.com/projects/xdoclet/browse/XDT-1595

    #265236

    <?xml version=”1.0″?>

    <webappext:WebAppExtension
    xmi:version=”2.0″
    xmlns:xmi=”http://www.omg.org/XMI&#8221;
    xmlns:webappext=”webappext.xmi”
    xmlns:webapplication=”webapplication.xmi”
    xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance&#8221;
    xmi:id=”WebApp_ID_Ext”
    <XDtConfig:ifConfigParamNotEquals paramName=”reloadInterval” value=””>
    reloadInterval=”<XDtConfig:configParameterValue paramName=”reloadInterval”/>”
    </XDtConfig:ifConfigParamNotEquals>
    reloadingEnabled=”<XDtConfig:configParameterValue paramName=”reloadingEnabled”/>”
    <XDtConfig:ifConfigParamNotEquals paramName=”defaultErrorPage” value=””>
    defaultErrorPage=”<XDtConfig:configParameterValue paramName=”defaultErrorPage”/>”
    </XDtConfig:ifConfigParamNotEquals>
    <XDtConfig:ifConfigParamNotEquals paramName=”additionalClassPath” value=””>
    additionalClassPath=”<XDtConfig:configParameterValue paramName=”additionalClassPath”/>”
    </XDtConfig:ifConfigParamNotEquals>
    fileServingEnabled=”<XDtConfig:configParameterValue paramName=”fileServingEnabled”/>”
    directoryBrowsingEnabled=”<XDtConfig:configParameterValue paramName=”directoryBrowsingEnabled”/>”
    serveServletsByClassnameEnabled=”<XDtConfig:configParameterValue paramName=”serveServletsByClassnameEnabled”/>”
    preCompileJSPs=”<XDtConfig:configParameterValue paramName=”preCompileJSPs”/>”
    autoRequestEncoding=”<XDtConfig:configParameterValue paramName=”autoRequestEncoding”/>”
    autoResponseEncoding=”<XDtConfig:configParameterValue paramName=”autoResponseEncoding”/>”
    autoLoadFilters=”<XDtConfig:configParameterValue paramName=”autoLoadFilters”/>”>

    <webApp href=”WEB-INF/web.xml#<XDtId:prefixedId prefix=’web-app’ wrapInIdEquals=’false’/>”/>

    <XDtComment:comment>
    |
    | resource-ref extensions
    |
    </XDtComment:comment>

    <XDtClass:forAllClasses>
    <XDtWebSphere:forAllTags tagName=”web.resource-ref”>
    <resourceRefExtensions xmi:<XDtId:prefixedId prefix=”ResourceRef_ext”/>
    <XDtWebSphere:forAllResourceRefs nameParam=”name”>
    <XDtClass:ifHasClassTag tagName=”websphere.resource-ref” paramName=”isolation-level”>
    isolationLevel=”<XDtClass:classTagValue tagName=”websphere.resource-ref” paramName=”isolation-level”/>”
    </XDtClass:ifHasClassTag>
    <XDtClass:ifHasClassTag tagName=”websphere.resource-ref” paramName=”connection-management-policy”>
    connectionManagementPolicy=”<XDtClass:classTagValue tagName=”websphere.resource-ref” paramName=”connection-management-policy”/>”
    </XDtClass:ifHasClassTag>
    </XDtWebSphere:forAllResourceRefs>
    >
    <resourceRef href=”WEB-INF/web.xml#<XDtId:prefixedId prefix=’ResRef’ wrapInIdEquals=’false’/>”/>
    </resourceRefExtensions>
    </XDtWebSphere:forAllTags>
    </XDtClass:forAllClasses>

    </webappext:WebAppExtension>

    #265238

    The above xml is the corrected version of the ibm-web-ext_xmi.xdt file in the xdoclet-ibm-module-1.2.3.jar

Viewing 5 posts - 1 through 5 (of 5 total)
Reply To: XDoclet Failing Part II WebSpherewebxml portion

You must be logged in to post in the forum log in