[teiid-commits] teiid SVN: r576 - in trunk: embedded/src/main/java/com/metamatrix/dqp/embedded/services and 1 other directories.
teiid-commits at lists.jboss.org
teiid-commits at lists.jboss.org
Wed Mar 18 14:34:06 EDT 2009
Author: rareddy
Date: 2009-03-18 14:34:06 -0400 (Wed, 18 Mar 2009)
New Revision: 576
Removed:
trunk/embedded/src/main/resources/configuration.xml
Modified:
trunk/client-jdbc/src/main/java/com/metamatrix/jdbc/EmbeddedDriver.java
trunk/embedded/src/main/java/com/metamatrix/dqp/embedded/services/EmbeddedDataService.java
Log:
TEIID-66
Modified: trunk/client-jdbc/src/main/java/com/metamatrix/jdbc/EmbeddedDriver.java
===================================================================
--- trunk/client-jdbc/src/main/java/com/metamatrix/jdbc/EmbeddedDriver.java 2009-03-18 18:25:16 UTC (rev 575)
+++ trunk/client-jdbc/src/main/java/com/metamatrix/jdbc/EmbeddedDriver.java 2009-03-18 18:34:06 UTC (rev 576)
@@ -37,6 +37,7 @@
import java.util.Iterator;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Logger;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@@ -74,6 +75,7 @@
static final String DQP_IDENTITY = "dqp.identity"; //$NON-NLS-1$
static final String MM_IO_TMPDIR = "mm.io.tmpdir"; //$NON-NLS-1$
+ private static Logger logger = Logger.getLogger("org.teiid.jdbc"); //$NON-NLS-1$
private static EmbeddedTransport currentTransport = null;
static Pattern urlPattern = Pattern.compile(URL_PATTERN);
@@ -111,6 +113,10 @@
parseURL(url, info);
conn = createConnection(info);
+ // logging
+ String logMsg = JDBCPlugin.Util.getString("JDBCDriver.Connection_sucess"); //$NON-NLS-1$
+ logger.info(logMsg);
+
return conn;
}
@@ -226,7 +232,7 @@
* @param jdbcURL
* @return default connection URL
*/
- String getDefaultConnectionURL() {
+ static String getDefaultConnectionURL() {
return "classpath:/deploy.properties"; //$NON-NLS-1$
}
@@ -349,15 +355,17 @@
//Load the properties from dqp.properties file
Properties props = loadDQPProperties(dqpURL);
props.putAll(info);
-
+
this.classLoader = this.getClass().getClassLoader();
// a non-delegating class loader will be created from where all third party dependent jars can be loaded
ArrayList<URL> runtimeClasspath = new ArrayList<URL>();
// find jars in the "lib" directory; patches is reverse alpaha and not case sensitive so small letters then capitals
- runtimeClasspath.addAll(libClassPath(dqpURL, "lib/patches/", MMURLConnection.REVERSEALPHA)); //$NON-NLS-1$
- runtimeClasspath.addAll(libClassPath(dqpURL, "lib/", MMURLConnection.DATE)); //$NON-NLS-1$
+ if (!EmbeddedDriver.getDefaultConnectionURL().equals(dqpURL.toString())) {
+ runtimeClasspath.addAll(libClassPath(dqpURL, "lib/patches/", MMURLConnection.REVERSEALPHA)); //$NON-NLS-1$
+ runtimeClasspath.addAll(libClassPath(dqpURL, "lib/", MMURLConnection.DATE)); //$NON-NLS-1$
+ }
URL[] dqpClassPath = runtimeClasspath.toArray(new URL[runtimeClasspath.size()]);
this.classLoader = new NonDelegatingClassLoader(dqpClassPath, Thread.currentThread().getContextClassLoader(), new MetaMatrixURLStreamHandlerFactory());
Modified: trunk/embedded/src/main/java/com/metamatrix/dqp/embedded/services/EmbeddedDataService.java
===================================================================
--- trunk/embedded/src/main/java/com/metamatrix/dqp/embedded/services/EmbeddedDataService.java 2009-03-18 18:25:16 UTC (rev 575)
+++ trunk/embedded/src/main/java/com/metamatrix/dqp/embedded/services/EmbeddedDataService.java 2009-03-18 18:34:06 UTC (rev 576)
@@ -585,7 +585,9 @@
ArrayList<URL> urlPath = new ArrayList<URL>();
urlPath.addAll(Arrays.asList(userPath));
- urlPath.addAll(Arrays.asList(commonExtensionPath));
+ if (commonExtensionPath != null) {
+ urlPath.addAll(Arrays.asList(commonExtensionPath));
+ }
ClassLoader classLoader = new URLFilteringClassLoader(urlPath.toArray(new URL[urlPath.size()]), Thread.currentThread().getContextClassLoader(), new MetaMatrixURLStreamHandlerFactory());
Class cmgrImplClass = classLoader.loadClass(CONNECTOR_MGR_IMPL);
Deleted: trunk/embedded/src/main/resources/configuration.xml
===================================================================
--- trunk/embedded/src/main/resources/configuration.xml 2009-03-18 18:25:16 UTC (rev 575)
+++ trunk/embedded/src/main/resources/configuration.xml 2009-03-18 18:34:06 UTC (rev 576)
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?><ConfigurationDocument>
- <Header>
- <ApplicationCreatedBy>ConfigurationAdministration</ApplicationCreatedBy>
- <ApplicationVersionCreatedBy>4.2</ApplicationVersionCreatedBy>
- <UserCreatedBy>Configuration</UserCreatedBy>
- <ConfigurationVersion>4.2</ConfigurationVersion>
- <MetaMatrixSystemVersion>4.2</MetaMatrixSystemVersion>
- <Time>2004-06-30T12:23:53.919-06:00</Time>
- </Header>
-
- <Configuration Name="Next Startup" ComponentType="Configuration" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup"><Properties/></Configuration>
-
- <Services>
- <Service Name="QueryService" ComponentType="QueryService" QueuedService="false" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup">
- <Properties>
- <Property Name="metamatrix.service.essentialservice">false</Property>
- <Property Name="ProcessPoolMaxThreads">64</Property>
- <Property Name="ProcessPoolThreadTTL">120000</Property>
- <Property Name="ServiceClassName">com.metamatrix.server.query.service.QueryService</Property>
- <Property Name="ProcessorTimeslice">2000</Property>
- <Property Name="MaxCodeTables">50</Property>
- <Property Name="MaxCodeTableRecords">10000</Property>
- <Property Name="MinFetchSize">100</Property>
- <Property Name="MaxFetchSize">20000</Property>
- <Property Name="ResultSetCacheEnabled">0</Property>
- <Property Name="ResultSetCacheMaxSize">0</Property>
- <Property Name="ResultSetCacheMaxAge">0</Property>
- <Property Name="ResultSetCacheScope">vdb</Property>
- <Property Name="MaxPlanCacheSize">100</Property>
- </Properties>
- </Service>
- </Services>
-
- <ProductTypes>
- <ProductType Name="Connectors" ComponentTypeCode="3" Deployable="false" Deprecated="false" Monitorable="false" SuperComponentType="Product" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup">
- </ProductType>
- </ProductTypes>
-
- <ComponentTypes>
- <ComponentType Name="Service" ComponentTypeCode="1" Deployable="false" Deprecated="false" Monitorable="false" ParentComponentType="VM" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup">
- <PropertyDefinition Name="ServiceClassName" DisplayName="Service Class Name" ShortDescription="" Multiplicity="1" PropertyType="String" ValueDelimiter="," IsConstrainedToAllowedValues="true" IsExpert="false" IsHidden="true" IsMasked="false" IsModifiable="true" IsPreferred="false"/>
- <PropertyDefinition Name="metamatrix.service.essentialservice" DisplayName="Essential Service" ShortDescription="Indicates if the service is essential to operation of the Integration Server" DefaultValue="false" Multiplicity="1" PropertyType="Boolean" ValueDelimiter="," IsConstrainedToAllowedValues="true" IsExpert="true" IsHidden="true" IsMasked="false" IsModifiable="true" IsPreferred="false"/>
- </ComponentType>
-
- <ComponentType Name="QueryService" ComponentTypeCode="1" Deployable="true" Deprecated="false" Monitorable="true" SuperComponentType="Service" ParentComponentType="Integration Server" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup">
- </ComponentType>
-
- <ComponentType Name="Configuration" ComponentTypeCode="0" Deployable="true" Deprecated="false" Monitorable="false" LastChangedBy="ConfigurationStartup" CreatedBy="ConfigurationStartup">
- </ComponentType>
- </ComponentTypes>
-</ConfigurationDocument>
\ No newline at end of file
More information about the teiid-commits
mailing list