Weblogic 12.1.3上下文路径已经被模块错误使用

时间:2015-06-26 14:25:05

标签: java deployment webserver weblogic weblogic12c

我正面临一个恼人的Weblogic问题。这是历史:

  1. 我们使用的是Weblogic 12.1.1(测试环境),部署工作正常
  2. 我进行了部署,但没有成功。我们的解决方案至少需要v12.1.2,因此我卸载了12.1.1并安装了Weblogic 12.1.3
  3. 在安装新版本之前,我完全删除了u01文件夹并从头开始创建
  4. 我以静默方式安装了Weblogic 12.1.3并创建了我的测试域。域中只有管理服务器和一个单独的托管服务器(没有集群,没有数量的托管服务器)
  5. 我进行了部署,但Weblogic保留了我"Error weblogic.application.ModuleException: Context path '/edys-web' is already in use by the module: edys-web application: edys-web-test"错误
  6. 我按照提到的here说明但我没有运气(BTW,Weblogic 12.1.3控制台中没有应用程序配置,或者我找不到链接)
  7. 现在,我不知道还有什么可做的。互联网上的信息不多。我该如何解决这个问题?

    PS:相同的应用程序在其他Weblogic 12.1.3环境中运行良好。

    编辑1:我正在添加我的config.xml

    <?xml version='1.0' encoding='UTF-8'?>
    <domain xmlns="http://xmlns.oracle.com/weblogic/domain" xmlns:sec="http://xmlns.oracle.com/weblogic/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wls="http://xmlns.oracle.com/weblogic/security/wls" xsi:schemaLocation="http://xmlns.oracle.com/weblogic/security/wls http://xmlns.oracle.com/weblogic/security/wls/1.0/wls.xsd http://xmlns.oracle.com/weblogic/domain http://xmlns.oracle.com/weblogic/1.0/domain.xsd http://xmlns.oracle.com/weblogic/security/xacml http://xmlns.oracle.com/weblogic/security/xacml/1.0/xacml.xsd http://xmlns.oracle.com/weblogic/security/providers/passwordvalidator http://xmlns.oracle.com/weblogic/security/providers/passwordvalidator/1.0/passwordvalidator.xsd http://xmlns.oracle.com/weblogic/security http://xmlns.oracle.com/weblogic/1.0/security.xsd">
      <name>oraworld_domain</name>
      <domain-version>12.1.3.0.0</domain-version>
      <security-configuration>
        <name>oraworld_domain</name>
        <realm>
          <sec:authentication-provider xsi:type="wls:default-authenticatorType">
            <sec:name>DefaultAuthenticator</sec:name>
          </sec:authentication-provider>
          <sec:authentication-provider xsi:type="wls:default-identity-asserterType">
            <sec:name>DefaultIdentityAsserter</sec:name>
            <sec:active-type>AuthenticatedUser</sec:active-type>
          </sec:authentication-provider>
          <sec:role-mapper xmlns:xac="http://xmlns.oracle.com/weblogic/security/xacml" xsi:type="xac:xacml-role-mapperType">
            <sec:name>XACMLRoleMapper</sec:name>
          </sec:role-mapper>
          <sec:authorizer xmlns:xac="http://xmlns.oracle.com/weblogic/security/xacml" xsi:type="xac:xacml-authorizerType">
            <sec:name>XACMLAuthorizer</sec:name>
          </sec:authorizer>
          <sec:adjudicator xsi:type="wls:default-adjudicatorType">
            <sec:name>DefaultAdjudicator</sec:name>
          </sec:adjudicator>
          <sec:credential-mapper xsi:type="wls:default-credential-mapperType">
            <sec:name>DefaultCredentialMapper</sec:name>
          </sec:credential-mapper>
          <sec:cert-path-provider xsi:type="wls:web-logic-cert-path-providerType">
            <sec:name>WebLogicCertPathProvider</sec:name>
          </sec:cert-path-provider>
          <sec:cert-path-builder>WebLogicCertPathProvider</sec:cert-path-builder>
          <sec:name>myrealm</sec:name>
          <sec:password-validator xmlns:pas="http://xmlns.oracle.com/weblogic/security/providers/passwordvalidator" xsi:type="pas:system-password-validatorType">
            <sec:name>SystemPasswordValidator</sec:name>
            <pas:min-password-length>8</pas:min-password-length>
            <pas:min-numeric-or-special-characters>1</pas:min-numeric-or-special-characters>
          </sec:password-validator>
        </realm>
        <default-realm>myrealm</default-realm>
        <credential-encrypted>{AES}XqD6eClO7wwKxv5mZUZC0PpR06elab9QCYfO9eovVjAWFIyvGlP/uYwcUZ+hNjeEpldGjr1PZABBKWSx5ZFlKSzUCkNr33T5YgdnZ1FC1fKaKGI/DG5iVuWNgHtb78Yt</credential-encrypted>
        <node-manager-username>weblogic</node-manager-username>
        <node-manager-password-encrypted>{AES}tA8QqN18hJTix40QCKTzl9DeqeKXx8qBWdVRU402Z7I=</node-manager-password-encrypted>
      </security-configuration>
      <server>
        <name>AdminServer</name>
        <ssl>
          <name>AdminServer</name>
          <enabled>true</enabled>
        </ssl>
        <listen-address></listen-address>
      </server>
      <server>
        <name>edys-web</name>
        <listen-port>8200</listen-port>
        <web-server>
          <web-server-log>
            <number-of-files-limited>false</number-of-files-limited>
          </web-server-log>
        </web-server>
        <listen-address></listen-address>
      </server>
      <embedded-ldap>
        <name>oraworld_domain</name>
        <credential-encrypted>{AES}VymYmNOZJKNXuopmGNayCRADs+iKI6Y/G1lG27Axik5eDs0wWfvrsak/eVXsq2Ja</credential-encrypted>
      </embedded-ldap>
      <configuration-version>12.1.3.0.0</configuration-version>
      <machine>
        <name>Machine-1</name>
      </machine>
      <admin-server-name>AdminServer</admin-server-name>
    </domain>
    

    编辑2:我正在添加weblogic.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <wls:weblogic-web-app xmlns:wls="http://xmlns.oracle.com/weblogic/weblogic-web-app" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd http://xmlns.oracle.com/weblogic/weblogic-web-app http://xmlns.oracle.com/weblogic/weblogic-web-app/1.0/weblogic-web-app.xsd">
        <wls:weblogic-version>12.1.3</wls:weblogic-version>
        <wls:context-root>edys-web</wls:context-root>
        <wls:container-descriptor>
    <!--        <wls:prefer-web-inf-classes>true</wls:prefer-web-inf-classes> -->
             <wls:prefer-application-packages>
                <wls:package-name>org.hibernate.*</wls:package-name>
                <wls:package-name>org.hibernate.hql.ast.*</wls:package-name>
                <wls:package-name>antlr.*</wls:package-name>
                <wls:package-name>javax.faces.*</wls:package-name>
                <wls:package-name>com.sun.faces.*</wls:package-name>
                            <package-name>javax.validation.*</package-name>
                            <package-name>org.hibernate.validator.*</package-name>
                <wls:package-name>javassist</wls:package-name>
                            <package-name>javax.persistence.*</package-name>
         </wls:prefer-application-packages>
    
    
    <wls:prefer-application-resources>
       <wls:resource-name>javax.faces.*</wls:resource-name>
          <wls:resource-name>com.sun.faces.*</wls:resource-name>
             <wls:resource-name>com.bea.faces.*</wls:resource-name>
    
    <wls:resource-name>META-INF/services/javax.servlet.ServletContainerInitializer</wls:resource-name>
    <wls:resource-name>META-INF/services/com.sun.faces.*</wls:resource-name>
    <resource-name>META-INF/validation-mapping-1.1.xsd</resource-name>
            <resource-name>META-INF/validation-configuration-1.1.xsd</resource-name>
       </wls:prefer-application-resources>
    
    
        <wls:show-archived-real-path-enabled>true</wls:show-archived-real-path-enabled>
        </wls:container-descriptor>
    </wls:weblogic-web-app>
    

1 个答案:

答案 0 :(得分:1)

我终于明白了。首先,我正在查看错误的日志,问题不在于上下文根,但它是关于Weblogic的,它无法找到Hibernate Validator。这个bug和Oracle为这个bug发布了一个临时补丁(20087183)。应用补丁后,问题解决了。