Finally, I found the root cause of my problem! My fault.
Due a little bug when I starts standalone.sh on Cygwin environment for
JBoss EAP 6.4 I set a value $JBOSS_HOME/modules for JBOSS_MODULEPATH
variable. The problem was that when I run the following command:
JBOSS_HOME=$PWD/jboss-eap-6.4 jboss-eap-6.4/bin/standalone.sh
--server-config standalone-keycloak.xml
I also need change the value for JBOSS_MODULEPATH on this command line
Or alternatively unset JBOSS_MODULEPATH variable and get the previous
little bug:
$ JBOSS_HOME=$PWD/jboss-eap-6.4 jboss-eap-6.4/bin/standalone.sh
--server-config standalone-keycloak.xml
cygpath: can't convert empty path
Thats it! Keycloak 1.3.1 works with JBoss EAP 6.4. No doubt.
2015-06-24 17:23 GMT-03:00 Paulo Jerônimo <paulojeronimo(a)gmail.com>:
In my investigation of this problem, I identified that if I run the
steps
described to test the Keycloak 1.3.1 + JBoss EAP 6.4 on a Linux environment
with OpenJDK 8 I don't catch problems. So, it seems to be an execution
problem in Windows environment. I will keep doing my research to identify
the cause.
2015-06-24 16:04 GMT-03:00 Paulo Jerônimo <paulojeronimo(a)gmail.com>:
> Now I tried to downgrade to keycloak version 1.1.0.Final, executing the
> steps bellow. But, I still can´t start JBoss EAP 6.4 after my steps:
>
>
https://gist.github.com/paulojeronimo/3f5746b221a882cf6b24
>
> Any idea about what I´m doing wrong?
>
> I really need integrate Keycloak with JBoss EAP 6.4. This integration
> really works? (I´ve been using Keycloak only with Wildfly until now, but,
> as its documentation said, it works. How???)
>
>
> 2015-06-24 14:25 GMT-03:00 Paulo Jerônimo <paulojeronimo(a)gmail.com>:
>
>> Vineet,
>>
>> I did what you said (using my last configuration with keycloak 1.2.0):
>>
>> $ grep 'subsystem.*keycloak'
>> jboss-eap-6.4/standalone/configuration/standalone.xml
>> <subsystem xmlns="urn:jboss:domain:keycloak:1.1">
>>
>> The error persists.
>>
>> Some other idea?
>>
>> 2015-06-24 13:05 GMT-03:00 Vineet Chaudhary <
>> vineet.chaudhary(a)praxify.com>:
>>
>>> I might be sound crazy now but for last time can you just change
>>> standalone.xml
>>>
>>> <subsystem xmlns="urn:jboss:domain:keycloak:1.0"> to
>>> <subsystem xmlns="urn:jboss:domain:keycloak:1.1">
>>>
>>> On Wed, Jun 24, 2015 at 9:19 PM, Paulo Jerônimo <
>>> paulojeronimo(a)gmail.com> wrote:
>>>
>>>> Due this error with version 1.3.1, I also tried to use Keycloak
>>>> version 1.2.0 and put it to work on JBoss EAP 6.4.
>>>>
>>>> But I also did not succeed following this procedure:
>>>>
>>>> $ rm -rf jboss-eap-6.4
>>>> $ unzip -q jboss-eap-6.4.0.zip
>>>> $ unzip -q -d jboss-eap-6.4 keycloak-overlay-1.2.0.Final.zip
>>>> $ cd jboss-eap-6.4/standalone/configuration/
>>>> $ cp standalone.xml standalone.xml.original
>>>> $ cat << 'EOF' | patch standalone.xml
>>>> > --- standalone.xml.original 2015-06-24 09:41:43.018484800 -0300
>>>> > +++ standalone.xml 2015-06-24 09:45:49.245308500 -0300
>>>> > @@ -24,6 +24,7 @@
>>>> > <extension module="org.jboss.as.web"/>
>>>> > <extension
module="org.jboss.as.webservices"/>
>>>> > <extension module="org.jboss.as.weld"/>
>>>> > + <extension
module="org.keycloak.keycloak-subsystem"/>
>>>> > </extensions>
>>>> > <management>
>>>> > <security-realms>
>>>> > @@ -135,6 +136,14 @@
>>>> > <password>sa</password>
>>>> > </security>
>>>> > </datasource>
>>>> > + <datasource
>>>> jndi-name="java:jboss/datasources/KeycloakDS"
pool-name="KeycloakDS"
>>>> enabled="true" use-java-context="true">
>>>> > +
>>>>
<connection-url>jdbc:h2:${jboss.server.data.dir}/keycloak;AUTO_SERVER=TRUE</connection-url>
>>>> > + <driver>h2</driver>
>>>> > + <security>
>>>> > + <user-name>sa</user-name>
>>>> > + <password>sa</password>
>>>> > + </security>
>>>> > + </datasource>
>>>> > <drivers>
>>>> > <driver name="h2"
module="com.h2database.h2">
>>>> >
>>>>
<xa-datasource-class>org.h2.jdbcx.JdbcDataSource</xa-datasource-class>
>>>> > @@ -276,6 +285,16 @@
>>>> > <policy-module
code="Delegating"
>>>> flag="required"/>
>>>> > </authorization>
>>>> > </security-domain>
>>>> > + <security-domain name="keycloak">
>>>> > + <authentication>
>>>> > + <login-module
>>>> code="org.keycloak.adapters.jboss.KeycloakLoginModule"
flag="required"/>
>>>> > + </authentication>
>>>> > + </security-domain>
>>>> > + <security-domain name="sp"
cache-type="default">
>>>> > + <authentication>
>>>> > + <login-module
>>>>
code="org.picketlink.identity.federation.bindings.wildfly.SAML2LoginModule"
>>>> flag="required"/>
>>>> > + </authentication>
>>>> > + </security-domain>
>>>> > </security-domains>
>>>> > </subsystem>
>>>> > <subsystem
xmlns="urn:jboss:domain:threads:1.1"/>
>>>> > @@ -307,6 +326,12 @@
>>>> > <client-config
name="Standard-Client-Config"/>
>>>> > </subsystem>
>>>> > <subsystem
xmlns="urn:jboss:domain:weld:1.0"/>
>>>> > + <subsystem
xmlns="urn:jboss:domain:keycloak:1.0">
>>>> > + <auth-server name="main-auth-server">
>>>> > + <enabled>true</enabled>
>>>> > + <web-context>auth</web-context>
>>>> > + </auth-server>
>>>> > + </subsystem>
>>>> > </profile>
>>>> > <interfaces>
>>>> > <interface name="management">
>>>> > @@ -338,4 +363,4 @@
>>>> > <remote-destination host="localhost"
port="25"/>
>>>> > </outbound-socket-binding>
>>>> > </socket-binding-group>
>>>> > -</server>
>>>> > \ No newline at end of file
>>>> > +</server>
>>>> > EOF
>>>> patching file standalone.xml
>>>> $ cd ../../..
>>>>
>>>> $ JBOSS_HOME=$PWD/jboss-eap-6.4 jboss-eap-6.4/bin/standalone.sh
>>>>
>>>>
=========================================================================
>>>>
>>>> JBoss Bootstrap Environment
>>>>
>>>> JBOSS_HOME:
>>>> C:\desenv\projetos\stn\sigti\instalador-bpms\jboss-eap-6.4
>>>>
>>>> JAVA: /cygdrive/c/Program Files/Java/jdk1.7.0_75/bin/java
>>>>
>>>> JAVA_OPTS: -server -XX:+UseCompressedOops -verbose:gc
>>>>
-Xloggc:"C:\desenv\projetos\stn\sigti\instalador-bpms\jboss-eap-6.4\standalone\log/gc.log"
>>>> -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+UseGCLogFileRotation
>>>> -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=3M -XX:-TraceClassUnloading
>>>> -Xms1303m -Xmx1303m -XX:MaxPermSize=256m -Djava.net.preferIPv4Stack=true
>>>> -Duser.language=en -Djboss.modules.system.pkgs=org.jboss.byteman
>>>> -Djava.awt.headless=true -Djboss.modules.policy-permissions=true
>>>>
>>>>
>>>>
=========================================================================
>>>>
>>>> 12:45:03,381 INFO [org.jboss.modules] (main) JBoss Modules version
>>>> 1.3.6.Final-redhat-1
>>>> 12:45:03,527 INFO [org.jboss.msc] (main) JBoss MSC version
>>>> 1.1.5.Final-redhat-1
>>>> 12:45:03,585 INFO [org.jboss.as] (MSC service thread 1-6)
>>>> JBAS015899: JBoss EAP 6.4.0.GA (AS 7.5.0.Final-redhat-21) starting
>>>> 12:45:03,975 ERROR [org.jboss.as.server] (Controller Boot Thread)
>>>> JBAS015956: Caught exception during boot:
>>>> org.jboss.as.controller.persistence.ConfigurationPersistenceException:
>>>> JBAS014676: Failed to parse configuration
>>>> at
>>>>
org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:141)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>> org.jboss.as.server.ServerService.boot(ServerService.java:330)
>>>> [jboss-as-server-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:263)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
>>>> Caused by: javax.xml.stream.XMLStreamException: JBAS014674: Failed to
>>>> load module org.keycloak.keycloak-subsystem
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml.parseExtensions(ExtensionXml.java:154)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.server.parsing.StandaloneXml.readServerElement_1_4(StandaloneXml.java:435)
>>>> [jboss-as-server-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.server.parsing.StandaloneXml.readElement(StandaloneXml.java:145)
>>>> [jboss-as-server-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.server.parsing.StandaloneXml.readElement(StandaloneXml.java:107)
>>>> [jboss-as-server-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>> org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:110)
>>>> [staxmapper-1.1.0.Final-redhat-3.jar:1.1.0.Final-redhat-3]
>>>> at
>>>> org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:69)
>>>> [staxmapper-1.1.0.Final-redhat-3.jar:1.1.0.Final-redhat-3]
>>>> at
>>>>
org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:133)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> ... 3 more
>>>> Caused by: java.util.concurrent.ExecutionException:
>>>> javax.xml.stream.XMLStreamException: JBAS014674: Failed to load module
>>>> at java.util.concurrent.FutureTask.report(FutureTask.java:122)
>>>> [rt.jar:1.7.0_75]
>>>> at java.util.concurrent.FutureTask.get(FutureTask.java:188)
>>>> [rt.jar:1.7.0_75]
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml.parseExtensions(ExtensionXml.java:146)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> ... 9 more
>>>> Caused by: javax.xml.stream.XMLStreamException: JBAS014674: Failed to
>>>> load module
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml.loadModule(ExtensionXml.java:195)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml.access$000(ExtensionXml.java:68)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml$1.call(ExtensionXml.java:126)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml$1.call(ExtensionXml.java:123)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> at java.util.concurrent.FutureTask.run(FutureTask.java:262)
>>>> [rt.jar:1.7.0_75]
>>>> at
>>>>
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>>>> [rt.jar:1.7.0_75]
>>>> at
>>>>
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>>>> [rt.jar:1.7.0_75]
>>>> at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
>>>> at org.jboss.threads.JBossThread.run(JBossThread.java:122)
>>>> [jboss-threads-2.1.2.Final-redhat-1.jar:2.1.2.Final-redhat-1]
>>>> Caused by: org.jboss.modules.ModuleNotFoundException:
>>>> org.keycloak.keycloak-subsystem:main
>>>> at
>>>> org.jboss.modules.ModuleLoader.loadModule(ModuleLoader.java:240)
>>>> [jboss-modules.jar:1.3.6.Final-redhat-1]
>>>> at
>>>>
org.jboss.as.controller.parsing.ExtensionXml.loadModule(ExtensionXml.java:177)
>>>> [jboss-as-controller-7.5.0.Final-redhat-21.jar:7.5.0.Final-redhat-21]
>>>> ... 8 more
>>>>
>>>> 12:45:03,983 FATAL [org.jboss.as.server] (Controller Boot Thread)
>>>> JBAS015957: Server boot has failed in an unrecoverable manner; exiting.
See
>>>> previous messages for details.
>>>> 12:45:03,994 INFO [org.jboss.as] (MSC service thread 1-5)
>>>> JBAS015950: JBoss EAP 6.4.0.GA (AS 7.5.0.Final-redhat-21) stopped in
>>>> 2ms
>>>>
>>>>
>>>>
>>>> What I'm doing wrong?
>>>> I had a good experience using Keycloak with Widlfy but I still can't
>>>> put it to work with JBoss EAP 6.4.
>>>>
>>>> Please, help me.
>>>>
>>>>
>>>
>>
>>
>> --
>> Att,
>> Paulo Jerônimo
>>
>> Fone: (61) 9504-6178
>>
>
>
>
> --
> Att,
> Paulo Jerônimo
>
> Fone: (61) 9504-6178
>
--
Att,
Paulo Jerônimo
Fone: (61) 9504-6178