<html>
<head>
<base href="https://docs.jboss.org/author">
<link rel="stylesheet" href="/author/s/en/2172/19/5/_/styles/combined.css?spaceKey=TEIID&forWysiwyg=true" type="text/css">
</head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
<h2><a href="https://docs.jboss.org/author/display/TEIID/Phoenix+Data+Sources?focusedCommentId=88703987#comment-88703987">Phoenix Data Sources</a></h2>
<h4>Comment edited by <a href="https://docs.jboss.org/author/display/~menchauser">Mukhamed Karanashev</a>
:</h4>
<br/>
<h4>Changes (1)</h4>
<div id="page-diffs">
<table class="diff" cellpadding="0" cellspacing="0">
<tr><td class="diff-snipped" >...<br></td></tr>
<tr><td class="diff-unchanged" >I've added dependency on system module "org.apache.commons.logging" and finally datasource worked, so I think you may add that to your article. <br> <br></td></tr>
<tr><td class="diff-added-lines" style="background-color: #dfd;">Final version of "module.xml": <br> <br></td></tr>
<tr><td class="diff-unchanged" >{code:language=html/xml}<?xml version="1.0" ?> <br> <br></td></tr>
<tr><td class="diff-snipped" >...<br></td></tr>
</table>
</div> <h4>Full Content</h4>
<div class="notificationGreySide">
<p>Hi.</p>
<p>Thank you for detailed explanation on Phoenix driver deployment! I could add some notes on that though.</p>
<p>I've tried to install Phoenix driver as module according to this documentation. Phoenix version is 4.3 and WildFly version is 8.2.</p>
<p>I kept getting exception on datasource connection retrieval:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Confluence; brush: java; gutter: false" style="font-size:12px; font-family: ConfluenceInstalledFont,monospace;">
Caused by: java.lang.ExceptionInInitializerError
at org.apache.phoenix.trace.util.Tracing$Frequency.<clinit>(Tracing.java:69)
at org.apache.phoenix.query.QueryServicesOptions.<clinit>(QueryServicesOptions.java:153)
at org.apache.phoenix.query.QueryServicesImpl.<init>(QueryServicesImpl.java:36)
at org.apache.phoenix.jdbc.PhoenixDriver.getQueryServices(PhoenixDriver.java:112)
at org.apache.phoenix.jdbc.PhoenixDriver.getConnectionQueryServices(PhoenixDriver.java:145)
at org.apache.phoenix.jdbc.PhoenixEmbeddedDriver.connect(PhoenixEmbeddedDriver.java:126)
at org.apache.phoenix.jdbc.PhoenixDriver.connect(PhoenixDriver.java:133)
at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.createLocalManagedConnection(LocalManagedConnectionFactory.java:322) [ironjacamar-jdbc-1.1.9.Final.jar:1.1.9.Final]
... 76 more
Caused by: org.apache.commons.logging.LogConfigurationException: The chosen LogFactory implementation does not extend LogFactory. Please check your configuration. (Caused by java.lang.UnsupportedOperationException: Operation [getClassLoader] is not supported in jcl-over-slf4j. See also http://www.slf4j.org/codes.html#unsupported_operation_in_jcl_over_slf4j)
at org.apache.commons.logging.LogFactory.createFactory(LogFactory.java:1271) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
at org.apache.commons.logging.LogFactory$2.run(LogFactory.java:1065) [commons-logging.jar:1.1.3]
at java.security.AccessController.doPrivileged(Native Method) [rt.jar:1.7.0_71]
at org.apache.commons.logging.LogFactory.newFactory(LogFactory.java:1062) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
at org.apache.commons.logging.LogFactory.getFactory(LogFactory.java:612) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:685) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
at org.apache.phoenix.trace.util.Tracing.<clinit>(Tracing.java:55)
... 84 more
Caused by: java.lang.UnsupportedOperationException: Operation [getClassLoader] is not supported in jcl-over-slf4j. See also http://www.slf4j.org/codes.html#unsupported_operation_in_jcl_over_slf4j
at org.apache.commons.logging.LogFactory.getClassLoader(LogFactory.java:377) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
at org.apache.commons.logging.impl.LogFactoryImpl.getClassLoader(LogFactoryImpl.java:392) [commons-logging.jar:1.1.3]
at org.apache.commons.logging.impl.LogFactoryImpl.initDiagnostics(LogFactoryImpl.java:420) [commons-logging.jar:1.1.3]
at org.apache.commons.logging.impl.LogFactoryImpl.<init>(LogFactoryImpl.java:87) [commons-logging.jar:1.1.3]
at com.netcracker.framework.logging.impl.commons.LogFactoryImpl.<init>(LogFactoryImpl.java:32) [cUtils-impl.jar:9.3.5.1_fix1_iter02 (date: 2015-02-12 11:27 GMT+0300)]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.7.0_71]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) [rt.jar:1.7.0_71]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) [rt.jar:1.7.0_71]
at java.lang.reflect.Constructor.newInstance(Constructor.java:526) [rt.jar:1.7.0_71]
at java.lang.Class.newInstance(Class.java:379) [rt.jar:1.7.0_71]
at org.apache.commons.logging.LogFactory.createFactory(LogFactory.java:1160) [jcl-over-slf4j-1.7.2.jbossorg-1.jar:1.7.2.jbossorg-1]
... 90 more
</pre>
</div></div>
<p>I've added dependency on system module "org.apache.commons.logging" and finally datasource worked, so I think you may add that to your article.</p>
<p>Final version of "module.xml":</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Confluence; brush: html/xml; gutter: false" style="font-size:12px; font-family: ConfluenceInstalledFont,monospace;"><?xml version="1.0" ?>
<module xmlns="urn:jboss:module:1.1" name="org.apache.phoenix">
<resources>
<resource-root path="phoenix-client-4.3.0-20150205.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="sun.jdk"/>
<module name="org.apache.log4j"/>
<module name="javax.transaction.api"/>
<module name="org.apache.commons.logging"/>
</dependencies>
</module></pre>
</div></div>
</div>
<div id="commentsSection" class="wiki-content pageSection">
<div style="float: right;" class="grey">
<a href="https://docs.jboss.org/author/users/removespacenotification.action?spaceKey=TEIID">Stop watching space</a>
<span style="padding: 0px 5px;">|</span>
<a href="https://docs.jboss.org/author/users/editmyemailsettings.action">Change email notification preferences</a>
</div>
<a href="https://docs.jboss.org/author/display/TEIID/Phoenix+Data+Sources?focusedCommentId=88703987#comment-88703987">View Online</a>
|
<a id="reply-88703987" href="https://docs.jboss.org/author/display/TEIID/Phoenix+Data+Sources?replyToComment=88703987#comment-88703987">Reply To This</a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>