목차
回复内容:
데이터 베이스 MySQL 튜토리얼 Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용

Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용

Dec 05, 2016 pm 01:27 PM

       服务器-jBoss7.1.1 as final与MySql5.7.16的配置

服务器mysqljava eejboss

  • 由于学年论文设计的缘由,现在开始零基础学Java EE。在最近的一段时间内,我搭建了java EE的开发环境,我用的JDK和Eclipse环境分别是jdk-7u79-windows-i586 、eclipse-jee-kepler-SR2-win32,jboss的环境是jboss-as-7.1.1.Final,配置好环境后,jboss可以正常启动,然后,我安装了Mysql,环境是mysql-5.7.16-win32.zip,通过命令行配置后Mysql可以正常启动。最后是jboss与Mysql的配置启动,其中jboss中的standalone.xml文件如下:Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용
       在D:\jboss7.1.1\modules\com\mysql\main中,文件配置如下:
    Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용
    Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용
       鉴于我是初学者,不懂配置,求大神指导,以解决问题。

回复内容:

http://blog.csdn.net/u012705000/article/details/51408007

初次使用jboss7.1.1.final部署项目,遇到了很多困难,最终通过查看官方文档和网上资料得以解决,特此记录一下。

error information

2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  #############################################################
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  JRebel Legacy Agent 6.4.2a (201604061405)
2016-05-12 12:53:20 JRebel:  (c) Copyright ZeroTurnaround AS, Estonia, Tartu.
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  Over the last 5 days JRebel prevented
2016-05-12 12:53:20 JRebel:  at least 386 redeploys/restarts saving you about 15.7 hours.
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  Licensed to Lei Zhang (sinosoft)
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  License type: evaluation
2016-05-12 12:53:20 JRebel:  Valid from: April 26, 2016
2016-05-12 12:53:20 JRebel:  Valid until: May 10, 2016
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  Trial License expired.
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  To extend your evaluation or purchase a license,
2016-05-12 12:53:20 JRebel:  contact sales@zeroturnaround.com.
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  If you think this is an error, contact support@zeroturnaround.com.
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:  #############################################################
2016-05-12 12:53:20 JRebel: 
2016-05-12 12:53:20 JRebel:
2016-05-12 12:53:20 JRebel: A newer version '6.4.3' is available for download
2016-05-12 12:53:20 JRebel: from http://zeroturnaround.com/software/jrebel/download/
2016-05-12 12:53:20 JRebel:
WARNING: -logmodule is deprecated. Please use the system property 'java.util.logging.manager'or the '
java.util.logging.LogManager' service loader.
12:53:22,705 信息    [org.jboss.modules] JBoss Modules version 1.1.1.GA
12:53:22,941 INFO  [org.jboss.msc] JBoss MSC version 1.0.2.GA
12:53:23,032 INFO  [org.jboss.as] JBAS015899: JBoss AS 7.1.1.Final "Brontes" starting
12:53:29,465 INFO  [org.jboss.as.server] JBAS015888: 
Creating http management service using socket-binding 
(management-http)
12:53:29,514 INFO  [org.jboss.as.logging] JBAS011502: Removing bootstrap log handlers
12:53:29,531 INFO  [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 52) 
JBAS010280: Activating Infinispan subsystem.
12:53:29,561 INFO  [org.jboss.as.configadmin] (ServerService Thread Pool -- 47) JBAS016200: Activating 
ConfigAdmin Subsystem
12:53:29,563 INFO  [org.jboss.as.security] (ServerService Thread Pool -- 65) 
JBAS013101: Activating Security 
Subsystem
12:53:29,591 INFO  [org.jboss.as.naming] (ServerService Thread Pool -- 59) JBAS011800: Activating
 Naming 
Subsystem
12:53:29,593 INFO  [org.jboss.as.webservices] (ServerService Thread Pool -- 69) JBAS015537: Activating 
WebServices Extension
12:53:29,611 INFO  [org.jboss.as.osgi] (ServerService Thread Pool -- 60) JBAS011940: Activating OSGi
 Subsystem
12:53:29,613 INFO  [org.jboss.as.naming] (MSC service thread 1-1) JBAS011802: Starting Naming Service
12:53:29,624 INFO  [org.jboss.as.security] (MSC service thread 1-7) JBAS013100: Current PicketBox 
version=4.0.7.Final
12:53:29,770 INFO  [org.jboss.as.mail.extension] (MSC service thread 1-2) JBAS015400: Bound mail 
session [java:jboss/mail/Default]
12:53:29,945 INFO  [org.jboss.ws.common.management.AbstractServerConfig] (MSC service thread 1-1)
 JBoss Web Services - Stack CXF Server 4.0.2.GA
12:53:43,605 INFO  [org.xnio] (MSC service thread 1-3) XNIO Version 3.0.3.GA
12:53:43,612 INFO  [org.xnio.nio] (MSC service thread 1-6) XNIO NIO Implementation Version 
3.0.3.GA
12:53:43,623 INFO  [org.jboss.remoting] (MSC service thread 1-3) JBoss Remoting version 3.2.3.GA
12:53:50,679 INFO  [org.jboss.as.connector] (MSC service thread 1-2) JBAS010408: Starting JCA
 Subsystem 
(JBoss IronJacamar 1.0.9.Final)
12:53:50,912 WARN  [org.jboss.as.server.deployment.scanner] (MSC service thread 1-3) JBAS015005:
 Reliable
 deployment behaviour is not possible when auto-deployment of exploded content is enabled
  (i.e. deployment without use of ".dodeploy"' marker files). Configuration of auto-deployment
   of exploded 
  content is not recommended in any situation where reliability is desired. Configuring the
   deployment 
  scanner's auto-deploy-exploded setting to "false" is recommended.
12:53:50,916 INFO  [org.jboss.as.server.deployment.scanner] (MSC service thread 1-3) 
JBAS015012: 
Started FileSystemDeploymentService for directory E:\Server\jboss-as-7.1.1.Final\standalone\deployments
12:53:50,925 INFO  [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) 
JBAS015014: Re-attempting failed deployment CTPro.war
12:53:50,938 INFO  [org.jboss.as.remoting] (MSC service thread 1-4) JBAS017100:
 Listening on /127.0.0.1:4447
12:53:50,938 INFO  [org.jboss.as.remoting] (MSC service thread 1-7) JBAS017100:
 Listening on /127.0.0.1:9999
12:53:51,410 INFO  [org.apache.coyote.http11.Http11Protocol] (MSC service thread 1-3) Starting Coyote 
HTTP/1.1 on http--127.0.0.1-9090
12:53:59,503 INFO  [org.jboss.as.controller] (Controller Boot Thread) JBAS014774:
 Service status report
JBAS014775:    New missing/unsatisfied dependencies:
 service jboss.jdbc-driver.com_oracle (missing) 
 dependents: [service jboss.data-source.java:jboss/datasources/sinosoftDataSource]

12:53:59,515 ERROR [org.jboss.as.controller.management-operation] (DeploymentScanner-threads - 2) 
Operation ("add") failed - address: ([("deployment" => "CTPro.war")]) - failure description: 
"JBAS014803: Duplicate resource [(\"deployment\" => \"CTPro.war\")]"
12:53:59,517 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1)
 JBAS014654: Composite operation was rolled back
12:53:59,519 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1)
 {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" =>
  {"Operation step-1" => "JBAS014803: Duplicate resource [(\"deployment\" => \"CTPro.war\")]"}}
12:53:59,588 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015951: Admin console listening
 on http://127.0.0.1:10990
12:53:59,589 ERROR [org.jboss.as] (Controller Boot Thread) JBAS015875: JBoss AS 7.1.1.Final
 "Brontes" started (with errors) in 37474ms - Started 129 of 206 services
  (2 services failed or missing dependencies, 74 services are passive or on-demand)
로그인 후 복사

此时我的配置文件如下:

Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용

<module xmlns="urn:jboss:module:1.1" name="com.oracle">

    <resources>
        <resource-root path="ojdbc6.jar"/>
    </resources>

    <dependencies>
        <module name="javax.api"/>
        <module name="javax.transaction.api"/>
        <module name="javax.servlet.api" optional="true"/>
    </dependencies>

</module>
로그인 후 복사

standalone.xml

<subsystem xmlns="urn:jboss:domain:datasources:1.0">
            <datasources>
                <datasource jta="true" jndi-name="java:jboss/datasources/sinosoftDataSource"
                 pool-name="sinosoftDataSource" enabled="true" use-java-context="true">
                    <connection-url>jdbc:oracle:thin:@10.129.2.106:1521:devdb</connection-url>
                    <driver>oracle</driver>
                    <pool>
                        <prefill>false</prefill>
                        <use-strict-min>false</use-strict-min>
                        <flush-strategy>FailingConnectionOnly</flush-strategy>
                    </pool>
                    <security>
                        <user-name>NEWCORE</user-name>
                        <password>NEWCORE</password>
                    </security>
                </datasource>
                <drivers>
                    <driver name="oracle" module="com.oracle">
                        <driver-class>oracle.jdbc.OracleDriver</driver-class>
                        <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
                    </driver>
                </drivers>
            </datasources>
        </subsystem>
로그인 후 복사

step1: 更改standalone.xml oracle.jdbc.driver.OracleDriver

17:33:35,590 信息    [org.jboss.modules] JBoss Modules version 1.1.1.GA
17:33:36,594 INFO  [org.jboss.msc] JBoss MSC version 1.0.2.GA
17:33:36,716 INFO  [org.jboss.as] JBAS015899: JBoss AS 7.1.1.Final "Brontes" starting
17:33:40,571 INFO  [org.jboss.as.server] JBAS015888: Creating http management service using socket-binding (management-http)
17:33:40,581 INFO  [org.xnio] XNIO Version 3.0.3.GA
17:33:40,601 INFO  [org.xnio.nio] XNIO NIO Implementation Version 3.0.3.GA
17:33:40,611 INFO  [org.jboss.remoting] JBoss Remoting version 3.2.3.GA
17:33:40,669 INFO  [org.jboss.as.logging] JBAS011502: Removing bootstrap log handlers
17:33:40,712 INFO  [org.jboss.as.osgi] (ServerService Thread Pool -- 39) JBAS011940: Activating OSGi Subsystem
17:33:40,714 INFO  [org.jboss.as.configadmin] (ServerService Thread Pool -- 26) JBAS016200: Activating ConfigAdmin Subsystem
17:33:40,723 INFO  [org.jboss.as.security] (ServerService Thread Pool -- 44) JBAS013101: Activating Security Subsystem
17:33:40,951 INFO  [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 31) JBAS010280: Activating Infinispan subsystem.
17:33:40,955 INFO  [org.jboss.as.naming] (ServerService Thread Pool -- 38) JBAS011800: Activating Naming Subsystem
17:33:40,956 INFO  [org.jboss.as.security] (MSC service thread 1-8) JBAS013100: Current PicketBox version=4.0.7.Final
17:33:41,128 INFO  [org.jboss.as.webservices] (ServerService Thread Pool -- 48) JBAS015537: Activating WebServices Extension
17:33:41,455 INFO  [org.jboss.as.naming] (MSC service thread 1-6) JBAS011802: Starting Naming Service
17:33:41,465 INFO  [org.jboss.as.mail.extension] (MSC service thread 1-4) JBAS015400: Bound mail session [java:jboss/mail/Default]
17:33:41,465 INFO  [org.jboss.as.connector] (MSC service thread 1-7) JBAS010408: Starting JCA Subsystem (JBoss IronJacamar 1.0.9.Final)
17:33:42,594 INFO  [org.jboss.as.connector.subsystems.datasources] (ServerService Thread Pool -- 27) JBAS010403: Deploying JDBC-compliant driver class oracle.jdbc.driver.OracleDriver (version 11.2)
17:33:42,859 INFO  [org.apache.coyote.http11.Http11Protocol] (MSC service thread 1-3) Starting Coyote HTTP/1.1 on http--127.0.0.1-9090
17:33:44,122 INFO  [org.jboss.ws.common.management.AbstractServerConfig] (MSC service thread 1-6) JBoss Web Services - Stack CXF Server 4.0.2.GA
17:33:44,708 WARN  [org.jboss.as.server.deployment.scanner] (MSC service thread 1-7) JBAS015005: Reliable deployment behaviour is not possible when auto-deployment of exploded content is enabled (i.e. deployment without use of ".dodeploy"&#39; marker files). Configuration of auto-deployment of exploded content is not recommended in any situation where reliability is desired. Configuring the deployment scanner&#39;s auto-deploy-exploded setting to "false" is recommended.
17:33:44,711 INFO  [org.jboss.as.server.deployment.scanner] (MSC service thread 1-7) JBAS015012: Started FileSystemDeploymentService for directory E:\Server\jboss-as-7.1.1.Final\standalone\deployments
17:33:44,730 INFO  [org.jboss.as.remoting] (MSC service thread 1-4) JBAS017100: Listening on /127.0.0.1:4447
17:33:44,730 INFO  [org.jboss.as.remoting] (MSC service thread 1-8) JBAS017100: Listening on /127.0.0.1:9999
17:33:44,745 INFO  [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS015014: Re-attempting failed deployment CTPro.war
17:33:45,107 INFO  [org.jboss.as.controller] (Controller Boot Thread) JBAS014774: Service status report
JBAS014775:    New missing/unsatisfied dependencies:
      service jboss.jdbc-driver.oracle (missing) dependents: [service jboss.data-source.java:jboss/datasources/sinosoftDataSource]

17:33:45,128 ERROR [org.jboss.as.controller.management-operation] (DeploymentScanner-threads - 2) Operation ("add") failed - address: ([("deployment" => "CTPro.war")]) - failure description: "JBAS014803: Duplicate resource [(\"deployment\" => \"CTPro.war\")]"
17:33:45,130 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS014654: Composite operation was rolled back
17:33:45,132 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-1" => "JBAS014803: Duplicate resource [(\"deployment\" => \"CTPro.war\")]"}}
17:33:45,226 INFO  [org.jboss.as] (Controller Boot Thread) JBAS015951: Admin console listening on http://127.0.0.1:10990
17:33:45,227 ERROR [org.jboss.as] (Controller Boot Thread) JBAS015875: JBoss AS 7.1.1.Final "Brontes" started (with errors) in 10514ms - Started 130 of 207 services (2 services failed or missing dependencies, 74 services are passive or on-demand)
로그인 후 복사

STEP 2 ;

改web.xml

context-param>
              <param-name>log4jConfigLocation</param-name>
              <param-value>/WEB-INF//log4j.xml</param-value>
       </context-param>
로그인 후 복사

to:

 context-param>
              <param-name>log4jConfigLocation</param-name>
              <param-value>/WEB-INF/classes/log4j.xml</param-value>
       </context-param>
로그인 후 복사
19:02:28,784 ERROR [org.springframework.web.context.ContextLoader] (MSC service thread 1-5) Context initialization failed:org.springframework.beans.factory.BeanCreationException: Error creating bean with name &#39;dataSource&#39; defined in ServletContext resource [/WEB-INF/app-config-context.xml]: Invocation of init method failed; nested exception isjavax.naming.NameNotFoundException: sinosoftDataSource -- service jboss.naming.context.java.sinosoftDataSource
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]
       at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]
       at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
       at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
       at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) [rt.jar:1.6.0_45]
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) [rt.jar:1.6.0_45]
       at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_45]
Caused by:javax.naming.NameNotFoundException: sinosoftDataSource -- service jboss.naming.context.java.sinosoftDataSource
       at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:97)
       at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:178)
       at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:113)
       at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:214)
       at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_45]
       at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:154) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:87) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:152) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:178) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiLocatorSupport.lookup(JndiLocatorSupport.java:95) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectLocator.lookup(JndiObjectLocator.java:105) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectFactoryBean.lookupWithFallback(JndiObjectFactoryBean.java:201) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectFactoryBean.afterPropertiesSet(JndiObjectFactoryBean.java:187) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       ... 20 more

19:02:28,807 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/]] (MSC service thread 1-5) Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener:org.springframework.beans.factory.BeanCreationException: Error creating bean with name &#39;dataSource&#39; defined in ServletContext resource [/WEB-INF/app-config-context.xml]: Invocation of init method failed; nested exception isjavax.naming.NameNotFoundException: sinosoftDataSource -- service jboss.naming.context.java.sinosoftDataSource
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111) [org.springframework.web-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]
       at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]
       at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
       at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
       at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) [rt.jar:1.6.0_45]
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) [rt.jar:1.6.0_45]
       at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_45]
Caused by:javax.naming.NameNotFoundException: sinosoftDataSource -- service jboss.naming.context.java.sinosoftDataSource
       at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:97)
       at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:178)
       at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:113)
       at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:214)
       at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_45]
       at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:154) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:87) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:152) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:178) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiLocatorSupport.lookup(JndiLocatorSupport.java:95) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectLocator.lookup(JndiObjectLocator.java:105) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectFactoryBean.lookupWithFallback(JndiObjectFactoryBean.java:201) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.jndi.JndiObjectFactoryBean.afterPropertiesSet(JndiObjectFactoryBean.java:187) [org.springframework.context-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452) [org.springframework.beans-3.1.1.RELEASE.jar:3.1.1.RELEASE]
       ... 20 more
로그인 후 복사

STEP:3

几番周折最终部署成功 最终的配置文件

1)applicationContext.xml

<beanid="dataSource"class="org.springframework.jndi.JndiObjectFactoryBean">
              <propertyname="jndiName">
                     <value>java:jboss/datasources/test</value>
              </property>
 </bean>
로그인 후 복사

2)Server-jBoss7.1.1을 최종 및 MySql5.7.16 구성으로 사용

<module xmlns="urn:jboss:module:1.0" name="com.oracle.jdbc"> 
  <resources> 
    <resource-root path="ojdbc6.jar"/> 
  </resources> 
  <dependencies> 
    <module name="javax.api"/>
    <module name="javax.transaction.api"/>
    <module name="javax.servlet.api" optional="true"/>
  </dependencies> 
</module>
로그인 후 복사

3)standalone.xml

<datasources>
                <datasource jta="true" jndi-name="java:jboss/datasources/test" pool-name="test" 
                enabled="true" use-java-context="false">
                    <connection-url>jdbc:oracle:thin:@localhost:1521:orcl</connection-url>
                    <driver>oracle</driver>
                    <pool>
                        <min-pool-size>3</min-pool-size>
                        <max-pool-size>10</max-pool-size>
                    </pool>
                    <security>
                        <user-name>scott</user-name>
                        <password>tiger</password>
                    </security>
                </datasource>
                <drivers>
                   <!-- <driver name="mysql" module="com.mysql">
                        <driver-class>com.mysql.jdbc.Driver</driver-class>
                        <xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource
                        </xa-datasource-class>
                    </driver>-->
                    <driver name="oracle" module="com.oracle.jdbc">
                        <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
                        <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
                    </driver>
                </drivers>
     </datasources>
로그인 후 복사

4)web.xml

<resource-ref>
          <res-ref-name>test</res-ref-name>
          <res-type>javax.sql.DataSource</res-type>
          <res-auth>Container</res-auth>
              <lookup-name>java:jboss/datasources/test</lookup-name>
 </resource-ref>
 <context-param>
   <param-name>contextConfigLocation</param-name>
   <param-value>/WEB-INF/applicationContext.xml</param-value>
 </context-param>
로그인 후 복사

以上就是服务器-jBoss7.1.1 as final与MySql5.7.16的配置的内容,更多相关内容请关注PHP中文网(www.php.cn)!


본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.

핫 AI 도구

Undresser.AI Undress

Undresser.AI Undress

사실적인 누드 사진을 만들기 위한 AI 기반 앱

AI Clothes Remover

AI Clothes Remover

사진에서 옷을 제거하는 온라인 AI 도구입니다.

Undress AI Tool

Undress AI Tool

무료로 이미지를 벗다

Clothoff.io

Clothoff.io

AI 옷 제거제

Video Face Swap

Video Face Swap

완전히 무료인 AI 얼굴 교환 도구를 사용하여 모든 비디오의 얼굴을 쉽게 바꾸세요!

뜨거운 도구

메모장++7.3.1

메모장++7.3.1

사용하기 쉬운 무료 코드 편집기

SublimeText3 중국어 버전

SublimeText3 중국어 버전

중국어 버전, 사용하기 매우 쉽습니다.

스튜디오 13.0.1 보내기

스튜디오 13.0.1 보내기

강력한 PHP 통합 개발 환경

드림위버 CS6

드림위버 CS6

시각적 웹 개발 도구

SublimeText3 Mac 버전

SublimeText3 Mac 버전

신 수준의 코드 편집 소프트웨어(SublimeText3)

eMule 검색이 서버에 연결할 수 없는 문제를 해결하는 방법 eMule 검색이 서버에 연결할 수 없는 문제를 해결하는 방법 Jan 25, 2024 pm 02:45 PM

해결책: 1. eMule 설정을 확인하여 올바른 서버 주소와 포트 번호를 입력했는지 확인하십시오. 2. 네트워크 연결을 확인하고, 컴퓨터가 인터넷에 연결되어 있는지 확인하고, 라우터를 재설정하십시오. 설정이 온라인인 경우 네트워크 연결에 문제가 없으면 서버가 온라인인지 확인해야 합니다. 4. eMule 버전을 업데이트하고 eMule 공식 웹사이트를 방문하여 최신 버전의 eMule 소프트웨어를 다운로드합니다. 5. 도움을 구하세요.

RPC 서버 연결 불가 및 데스크탑 진입 불가 현상에 대한 해결 방법 RPC 서버 연결 불가 및 데스크탑 진입 불가 현상에 대한 해결 방법 Feb 18, 2024 am 10:34 AM

RPC 서버를 사용할 수 없고 데스크톱에서 접속할 수 없는 경우 어떻게 해야 합니까? 최근 몇 년 동안 컴퓨터와 인터넷이 우리 생활 곳곳에 침투했습니다. RPC(원격 프로시저 호출)는 중앙 집중식 컴퓨팅 및 리소스 공유를 위한 기술로서 네트워크 통신에서 중요한 역할을 합니다. 그러나 때때로 RPC 서버를 사용할 수 없어 데스크탑에 들어갈 수 없는 상황이 발생할 수 있습니다. 이 문서에서는 이 문제의 가능한 원인 중 일부를 설명하고 해결 방법을 제공합니다. 먼저 RPC 서버를 사용할 수 없는 이유를 이해해야 합니다. RPC 서버는

CentOS 설치 퓨즈 및 CentOS 설치 서버에 대한 자세한 설명 CentOS 설치 퓨즈 및 CentOS 설치 서버에 대한 자세한 설명 Feb 13, 2024 pm 08:40 PM

LINUX 사용자로서 CentOS에 다양한 소프트웨어와 서버를 설치해야 하는 경우가 많습니다. 이 글에서는 관련 작업을 원활하게 완료할 수 있도록 CentOS에 퓨즈를 설치하고 서버를 설정하는 방법을 자세히 소개합니다. CentOS 설치 퓨즈Fuse는 권한이 없는 사용자가 맞춤형 파일 시스템을 통해 파일 시스템에 액세스하고 작동할 수 있도록 하는 사용자 공간 파일 시스템 프레임워크입니다. CentOS에 퓨즈를 설치하는 것은 매우 간단합니다. 다음 단계를 따르십시오. 1. 터미널을 열고 다음 계정으로 로그인합니다. 루트 사용자. 2. 다음 명령을 사용하여 퓨즈 패키지를 설치합니다. ```yuminstallfuse3. 설치 프로세스 중 프롬프트를 확인하고 'y'를 입력하여 계속합니다. 4. 설치 완료

Dnsmasq를 DHCP 릴레이 서버로 구성하는 방법 Dnsmasq를 DHCP 릴레이 서버로 구성하는 방법 Mar 21, 2024 am 08:50 AM

DHCP 릴레이의 역할은 두 서버가 서로 다른 서브넷에 있더라도 수신된 DHCP 패킷을 네트워크의 다른 DHCP 서버로 전달하는 것입니다. DHCP 릴레이를 사용하면 네트워크 센터에 중앙 집중식 DHCP 서버를 배포하고 이를 사용하여 모든 네트워크 서브넷/VLAN에 IP 주소를 동적으로 할당할 수 있습니다. Dnsmasq는 네트워크에서 동적 호스트 구성을 관리하는 데 도움이 되도록 DHCP 릴레이 서버로 구성할 수 있는 일반적으로 사용되는 DNS 및 DHCP 프로토콜 서버입니다. 이 기사에서는 dnsmasq를 DHCP 릴레이 서버로 구성하는 방법을 보여줍니다. 내용 항목: 네트워크 토폴로지 중앙 집중식 DHCP 서버의 DHCP 릴레이 D에서 고정 IP 주소 구성

PHP를 사용한 IP 프록시 서버 구축을 위한 모범 사례 가이드 PHP를 사용한 IP 프록시 서버 구축을 위한 모범 사례 가이드 Mar 11, 2024 am 08:36 AM

네트워크 데이터 전송에서 IP 프록시 서버는 사용자가 실제 IP 주소를 숨기고 개인정보를 보호하며 액세스 속도를 향상시키는 데 도움을 주는 중요한 역할을 합니다. 이 기사에서는 PHP를 사용하여 IP 프록시 서버를 구축하는 방법에 대한 모범 사례 가이드를 소개하고 구체적인 코드 예제를 제공합니다. IP 프록시 서버란 무엇입니까? IP 프록시 서버는 사용자와 대상 서버 사이에 위치한 중간 서버로서 사용자와 대상 서버 사이의 전송 스테이션 역할을 하며 사용자의 요청과 응답을 전달합니다. IP 프록시 서버를 사용하여

서버 상태를 확인하는 방법 서버 상태를 확인하는 방법 Oct 09, 2023 am 10:10 AM

서버 상태를 보는 방법에는 명령줄 도구, 그래픽 인터페이스 도구, 모니터링 도구, 로그 파일 및 원격 관리 도구가 포함됩니다. 자세한 소개: 1. 명령줄 도구를 사용합니다. Linux 또는 Unix 서버에서는 명령줄 도구를 사용하여 서버 상태를 볼 수 있습니다. 2. 그래픽 인터페이스가 있는 서버 운영 체제의 경우 그래픽을 사용할 수 있습니다. 시스템에서 제공하는 인터페이스 도구를 사용하여 서버 상태를 확인합니다. 3. 모니터링 도구를 사용하여 실시간으로 서버 상태를 모니터링할 수 있습니다.

TFTP 서버를 활성화하는 방법 TFTP 서버를 활성화하는 방법 Oct 18, 2023 am 10:18 AM

TFTP 서버를 시작하는 단계에는 TFTP 서버 소프트웨어 선택, 소프트웨어 다운로드 및 설치, TFTP 서버 구성, 서버 시작 및 테스트가 포함됩니다. 자세한 소개: 1. TFTP 서버 소프트웨어를 선택할 때 먼저 필요에 맞는 TFTP 서버 소프트웨어를 선택해야 합니다. 현재 Tftpd32, PumpKIN, tftp-hpa 등과 같이 선택할 수 있는 TFTP 서버 소프트웨어가 많이 있습니다. 모두 간단하고 사용하기 쉬운 기능과 구성 옵션을 제공합니다. 2. TFTP 서버 소프트웨어 등을 다운로드하고 설치합니다.

에픽서버가 오프라인 상태일 때 게임에 접속할 수 없으면 어떻게 해야 하나요? 에픽게임즈가 오프라인으로 게임에 입장할 수 없는 이유에 대한 해결책 에픽서버가 오프라인 상태일 때 게임에 접속할 수 없으면 어떻게 해야 하나요? 에픽게임즈가 오프라인으로 게임에 입장할 수 없는 이유에 대한 해결책 Mar 13, 2024 pm 04:40 PM

에픽서버가 오프라인 상태일 때 게임에 접속할 수 없으면 어떻게 해야 하나요? 이 문제는 많은 친구들이 겪었을 것입니다. 이 메시지가 나타나면 정품 게임을 시작할 수 없습니다. 이 문제는 일반적으로 네트워크 및 보안 소프트웨어의 간섭으로 인해 발생합니다. 이 문제의 편집자는 어떻게 설명합니까? 저는 여러분과 솔루션을 공유하고 싶습니다. 오늘의 소프트웨어 튜토리얼이 문제 해결에 도움이 되기를 바랍니다. 에픽 서버가 오프라인일 때 게임에 들어갈 수 없는 경우 해결 방법: 1. 게임 플랫폼과 보안 소프트웨어의 방해를 받을 수 있습니다. 2. 두 번째는 네트워크 변동이 너무 심하다는 것입니다. 라우터를 다시 시작하여 작동하는지 확인해보세요. 조건이 괜찮다면 5g 모바일 네트워크를 사용해 작동해 보세요. 3. 그럼 더 있을 수도 있겠네요

See all articles