Fala galera, estou estudando java ee pelo livro da casa do código e me deparei com um problema na hora de subir o servidor widfly.
Após realizar uma configuração de xml para setar o meu banco de dados, o console do eclipse passou a retornar o seguinte log:
19:55:12,728 ERROR [org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService$AS7DataSourceDeployer] (MSC service thread 1-7) Error during the deployment of java:jboss/datasources/casadocodigoDS: javax.resource.ResourceException: IJ031103: At least one connection property must be defined for datasource-class: com.mysql.jdbc.Driver
at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.createConnectionFactory(LocalManagedConnectionFactory.java:108)
at org.jboss.jca.deployers.common.AbstractDsDeployer.deployDataSource(AbstractDsDeployer.java:772)
at > org.jboss.jca.deployers.common.AbstractDsDeployer.createObjectsAndInjectValue(AbstractDsDeployer.java:312)
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService$AS7DataSourceDeployer.deploy(AbstractDataSourceService.java:371)
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:149)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
19:55:12,745 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC000001: Failed to start service org.wildfly.data-source.casadocodigoDS: org.jboss.msc.service.StartException in service org.wildfly.data-source.casadocodigoDS: WFLYJCA0033: Error during the deployment of casadocodigoDS
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:163)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
Caused by: org.jboss.msc.service.StartException in anonymous service: WFLYJCA0032: Unable to start the ds because it generated more than one cf
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:151)
… 5 more
19:55:12,787 INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-2) WFLYJCA0001: Bound data source [java:jboss/datasources/ExampleDS]
19:55:13,610 WARN [org.jboss.as.domain.management.security] (MSC service thread 1-7) WFLYDM0111: Keystore /home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/configuration/application.keystore not found, it will be auto generated on first use with a self signed certificate for host localhost
19:55:13,870 INFO [org.jboss.as.server.deployment.scanner] (MSC service thread 1-6) WFLYDS0013: Started FileSystemDeploymentService for directory /home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/deployments
19:55:13,984 INFO [org.wildfly.iiop.openjdk] (MSC service thread 1-3) WFLYIIOP0009: CORBA ORB Service started
19:55:14,036 INFO [org.jboss.as.server.deployment] (MSC service thread 1-6) WFLYSRV0027: Starting deployment of “casadocodigo.war” (runtime-name: “casadocodigo.war”)
19:55:14,136 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221000: live Message Broker is starting with configuration Broker Configuration (clustered=false,journalDirectory=/home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/data/activemq/journal,bindingsDirectory=/home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/data/activemq/bindings,largeMessagesDirectory=/home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/data/activemq/largemessages,pagingDirectory=/home/damarium/Documents/Servers/wildfly-10.1.0.Final/standalone/data/activemq/paging)
19:55:15,017 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221012: Using AIO Journal
19:55:15,066 INFO [org.infinispan.factories.GlobalComponentRegistry] (MSC service thread 1-5) ISPN000128: Infinispan version: Infinispan ‘Chakra’ 8.2.4.Final
19:55:15,184 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 68) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,188 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 68) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,195 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 69) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,197 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 69) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,190 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 67) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,211 INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool – 67) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
19:55:15,430 INFO [org.wildfly.extension.undertow] (MSC service thread 1-4) WFLYUT0006: Undertow HTTPS listener https listening on 127.0.0.1:8443
19:55:15,835 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221043: Protocol module found: [artemis-server]. Adding protocol support for: CORE
19:55:15,894 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221043: Protocol module found: [artemis-amqp-protocol]. Adding protocol support for: AMQP
19:55:15,921 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221043: Protocol module found: [artemis-hornetq-protocol]. Adding protocol support for: HORNETQ
19:55:15,925 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221043: Protocol module found: [artemis-stomp-protocol]. Adding protocol support for: STOMP
19:55:16,010 INFO [org.jboss.ws.common.management] (MSC service thread 1-1) JBWS022052: Starting JBossWS 5.1.5.Final (Apache CXF 3.1.6)
19:55:16,974 INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-4) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor-throughput acceptor
19:55:16,974 INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-8) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor acceptor
19:55:16,973 INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-3) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor-throughput acceptor
19:55:16,984 INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-5) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor acceptor
19:55:17,578 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221007: Server is now live
19:55:17,578 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 64) AMQ221001: Apache ActiveMQ Artemis Message Broker version 1.1.0.wildfly-017 [nodeID=60b1a9d9-5373-11e7-ada5-c14c72e3fee7]
19:55:17,626 INFO [org.wildfly.extension.messaging-activemq] (ServerService Thread Pool – 64) WFLYMSGAMQ0002: Bound messaging object to jndi name java:jboss/exported/jms/RemoteConnectionFactory
19:55:17,668 INFO [org.wildfly.extension.messaging-activemq] (ServerService Thread Pool – 67) WFLYMSGAMQ0002: Bound messaging object to jndi name java:/ConnectionFactory
19:55:17,670 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 68) AMQ221003: trying to deploy queue jms.queue.DLQ
19:55:17,697 INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool – 65) AMQ221003: trying to deploy queue jms.queue.ExpiryQueue
19:55:17,847 INFO [org.jboss.as.jpa] (MSC service thread 1-1) WFLYJPA0002: Read persistence.xml for casadocodigo-dev
19:55:17,850 INFO [org.jboss.as.connector.deployment] (MSC service thread 1-4) WFLYJCA0007: Registered connection factory java:/JmsXA
19:55:18,018 INFO [org.apache.activemq.artemis.ra] (MSC service thread 1-4) Resource adaptor started
19:55:18,019 INFO [org.jboss.as.connector.services.resourceadapters.ResourceAdapterActivatorService$ResourceAdapterActivator] (MSC service thread 1-4) IJ020002: Deployed: file://RaActivatoractivemq-ra
19:55:18,023 INFO [org.jboss.as.connector.deployment] (MSC service thread 1-6) WFLYJCA0002: Bound JCA ConnectionFactory [java:/JmsXA]
19:55:18,024 INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-6) WFLYMSGAMQ0002: Bound messaging object to jndi name java:jboss/DefaultJMSConnectionFactory
19:55:18,205 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-8) MSC000001: Failed to start service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE: org.jboss.msc.service.StartException in service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE: WFLYSRV0153: Failed to process phase FIRST_MODULE_USE of deployment "casadocodigo.war"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:154)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:748)
Caused by: javax.persistence.PersistenceException: WFLYJPA0057: PersistenceProvider ‘
org.hibernate.ejb.HibernatePersistence
’ not found
at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.lookupProvider(PersistenceUnitServiceHandler.java:1009)
at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.addPuService(PersistenceUnitServiceHandler.java:270)
at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.handleWarDeployment(PersistenceUnitServiceHandler.java:203)
at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.deploy(PersistenceUnitServiceHandler.java:131)
at org.jboss.as.jpa.processor.PersistenceBeginInstallProcessor.deploy(PersistenceBeginInstallProcessor.java:52)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:147)
… 5 more
19:55:18,215 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation (“deploy”) failed - address: ([(“deployment” => “casadocodigo.war”)]) - failure description: {
“WFLYCTL0080: Failed services” => {“jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE” => "org.jboss.msc.service.StartException in service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE: WFLYSRV0153: Failed to process phase FIRST_MODULE_USE of deployment “casadocodigo.war"
Caused by: javax.persistence.PersistenceException: WFLYJPA0057: PersistenceProvider ‘
org.hibernate.ejb.HibernatePersistence
’ not found”},
“WFLYCTL0412: Required services that are not installed:” => [“jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE”],
“WFLYCTL0180: Services with missing/unavailable dependencies” => undefined
}
19:55:18,220 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation (“add”) failed - address: ([
(“subsystem” => “datasources”),
(“data-source” => “casadocodigoDS”)
]) - failure description: {
“WFLYCTL0080: Failed services” => {“org.wildfly.data-source.casadocodigoDS” => “org.jboss.msc.service.StartException in service org.wildfly.data-source.casadocodigoDS: WFLYJCA0033: Error during the deployment of casadocodigoDS
Caused by: org.jboss.msc.service.StartException in anonymous service: WFLYJCA0032: Unable to start the ds because it generated more than one cf”},
“WFLYCTL0412: Required services that are not installed:” => [“org.wildfly.data-source.casadocodigoDS”],
“WFLYCTL0180: Services with missing/unavailable dependencies” => undefined
}
19:55:18,227 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation (“add”) failed - address: ([
(“subsystem” => “datasources”),
(“data-source” => “casadocodigoDS”)
]) - failure description: {
“WFLYCTL0080: Failed services” => {“org.wildfly.data-source.casadocodigoDS” => “org.jboss.msc.service.StartException in service org.wildfly.data-source.casadocodigoDS: WFLYJCA0033: Error during the deployment of casadocodigoDS
Caused by: org.jboss.msc.service.StartException in anonymous service: WFLYJCA0032: Unable to start the ds because it generated more than one cf”},
“WFLYCTL0412: Required services that are not installed:” => [
“org.wildfly.data-source.casadocodigoDS”,
“org.wildfly.data-source.casadocodigoDS”
],
“WFLYCTL0180: Services with missing/unavailable dependencies” => undefined
}
19:55:18,280 INFO [org.jboss.as.server] (ServerService Thread Pool – 37) WFLYSRV0010: Deployed “casadocodigo.war” (runtime-name : “casadocodigo.war”)
19:55:18,318 INFO [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0183: Service status report
WFLYCTL0186: Services which failed to start: service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE: org.jboss.msc.service.StartException in service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE: WFLYSRV0153: Failed to process phase FIRST_MODULE_USE of deployment "casadocodigo.war"
service org.wildfly.data-source.casadocodigoDS: org.jboss.msc.service.StartException in service org.wildfly.data-source.casadocodigoDS: WFLYJCA0033: Error during the deployment of casadocodigoDS
19:55:18,593 INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0060: Http management interface listening on http://127.0.0.1:9990/management
19:55:18,594 INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0051: Admin console listening on http://127.0.0.1:9990
19:55:18,594 ERROR [org.jboss.as] (Controller Boot Thread) WFLYSRV0026: WildFly Full 10.1.0.Final (WildFly Core 2.2.0.Final) started (with errors) in 13697ms - Started 385 of 635 services (4 services failed or missing dependencies, 411 services are lazy, passive or on-demand)
19:55:18,683 INFO [org.jboss.as.server.deployment] (MSC service thread 1-5) WFLYSRV0028: Stopped deployment casadocodigo.war (runtime-name: casadocodigo.war) in 29ms
19:55:18,858 WARN [org.jboss.as.controller] (DeploymentScanner-threads - 2) WFLYCTL0357: Notification of type deployment-undeployed is not described for the resource at the address []
19:55:18,865 INFO [org.jboss.as.server] (DeploymentScanner-threads - 2) WFLYSRV0009: Undeployed “casadocodigo.war” (runtime-name: “casadocodigo.war”)
19:55:18,866 INFO [org.jboss.as.controller] (DeploymentScanner-threads - 2) WFLYCTL0183: Service status report
WFLYCTL0186: Services which failed to start: service jboss.deployment.unit.“casadocodigo.war”.FIRST_MODULE_USE
service org.wildfly.data-source.casadocodigoDS: org.jboss.msc.service.StartException in service org.wildfly.data-source.casadocodigoDS: WFLYJCA0033: Error during the deployment of casadocodigoDS
19:55:23,389 INFO [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) WFLYDS0004: Found casadocodigo.war in deployment directory. To trigger deployment create a file called casadocodigo.war.dodeploy
Alguém saberia me dizer exatamente o que fiz de errado? Até onde vi eu realizei os passos corretamente, mas creio que possa ser um detalhe qual tenha deixado escapar… Como estou acostumado a usar o tomcat, o log do wildfly tem sido um pouco confuso agora no inicio…