[infinispan-commits] Infinispan SVN: r1253 - in trunk/cachestore/jdbc/src: main/java/org/infinispan/loaders/jdbc/binary and 9 other directories.
infinispan-commits at lists.jboss.org
infinispan-commits at lists.jboss.org
Sat Dec 5 07:35:06 EST 2009
Author: sannegrinovero
Date: 2009-12-05 07:35:06 -0500 (Sat, 05 Dec 2009)
New Revision: 1253
Added:
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManipulationHelper.java
Modified:
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManiulationHelper.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/JdbcUtil.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/TableManipulation.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStore.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreConfig.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactory.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactoryConfig.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ManagedConnectionFactory.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/PooledConnectionFactory.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/SimpleConnectionFactory.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStore.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfig.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapper.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStore.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreConfig.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/Key2StringMapper.java
trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/UnsupportedKeyTypeException.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/config/parsing/JdbcConfigurationParserTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/ManagedConnectionFactoryTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/PooledConnectionFactoryTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableManipulationTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableNameUniquenessTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/BinaryStoreWithManagedConnectionTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfigTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest2.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/MixedStoreWithManagedConnectionTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapperTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest2.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/Person.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/PersonKey2StringMapper.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/StringStoreWithManagedConnectionTest.java
trunk/cachestore/jdbc/src/test/java/org/infinispan/test/fwk/UnitTestDatabaseManager.java
Log:
jdbc-store typos, serialUIDS, missing copyrights.
Added: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManipulationHelper.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManipulationHelper.java (rev 0)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManipulationHelper.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -0,0 +1,187 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.infinispan.loaders.jdbc;
+
+import org.infinispan.container.entries.InternalCacheEntry;
+import org.infinispan.loaders.CacheLoaderException;
+import org.infinispan.loaders.jdbc.connectionfactory.ConnectionFactory;
+import org.infinispan.marshall.Marshaller;
+import org.infinispan.util.logging.Log;
+import org.infinispan.util.logging.LogFactory;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.ObjectInput;
+import java.io.ObjectOutput;
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.util.HashSet;
+import java.util.Set;
+
+/**
+ * The purpose of this class is to factorize the repeating code between {@link org.infinispan.loaders.jdbc.stringbased.JdbcStringBasedCacheStore}
+ * and {@link org.infinispan.loaders.jdbc.binary.JdbcBinaryCacheStore}. This class implements GOF's template method pattern.
+ *
+ * @author Mircea.Markus at jboss.com
+ */
+public abstract class DataManipulationHelper {
+
+ private static Log log = LogFactory.getLog(DataManipulationHelper.class);
+
+ private ConnectionFactory connectionFactory;
+ private TableManipulation tableManipulation;
+ protected Marshaller marshaller;
+
+
+ public DataManipulationHelper(ConnectionFactory connectionFactory, TableManipulation tableManipulation, Marshaller marshaller) {
+ this.connectionFactory = connectionFactory;
+ this.tableManipulation = tableManipulation;
+ this.marshaller = marshaller;
+ }
+
+ public void clear() throws CacheLoaderException {
+ Connection conn = null;
+ PreparedStatement ps = null;
+ try {
+ String sql = tableManipulation.getDeleteAllRowsSql();
+ conn = connectionFactory.getConnection();
+ ps = conn.prepareStatement(sql);
+ int result = ps.executeUpdate();
+ if (log.isTraceEnabled())
+ log.trace("Successfully removed " + result + " rows.");
+ } catch (SQLException ex) {
+ logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
+ } finally {
+ JdbcUtil.safeClose(ps);
+ connectionFactory.releaseConnection(conn);
+ }
+ }
+
+
+ public final void fromStreamSupport(ObjectInput objectInput) throws CacheLoaderException {
+ Connection conn = null;
+ PreparedStatement ps = null;
+ try {
+ conn = connectionFactory.getConnection();
+ String sql = tableManipulation.getInsertRowSql();
+ ps = conn.prepareStatement(sql);
+
+ int readCount = 0;
+ int batchSize = tableManipulation.getBatchSize();
+
+ Object objFromStream = marshaller.objectFromObjectStream(objectInput);
+ while (fromStreamProcess(objFromStream, ps, objectInput)) {
+ ps.addBatch();
+ readCount++;
+ if (readCount % batchSize == 0) {
+ ps.executeBatch();
+ if (log.isTraceEnabled())
+ log.trace("Executing batch " + (readCount / batchSize) + ", batch size is " + batchSize);
+ }
+ objFromStream = marshaller.objectFromObjectStream(objectInput);
+ }
+ if (readCount % batchSize != 0)
+ ps.executeBatch();//flush the batch
+ if (log.isTraceEnabled())
+ log.trace("Successfully inserted " + readCount + " buckets into the database, batch size is " + batchSize);
+ } catch (IOException ex) {
+ logAndThrow(ex, "I/O failure while integrating state into store");
+ } catch (SQLException e) {
+ logAndThrow(e, "SQL failure while integrating state into store");
+ } catch (ClassNotFoundException e) {
+ logAndThrow(e, "Unexpected failure while integrating state into store");
+ } finally {
+ JdbcUtil.safeClose(ps);
+ connectionFactory.releaseConnection(conn);
+ }
+ }
+
+
+ public final void toStreamSupport(ObjectOutput objectOutput, byte streamDelimiter) throws CacheLoaderException {
+ //now write our data
+ Connection connection = null;
+ PreparedStatement ps = null;
+ ResultSet rs = null;
+ try {
+ String sql = tableManipulation.getLoadAllRowsSql();
+ if (log.isTraceEnabled()) log.trace("Running sql '" + sql);
+ connection = connectionFactory.getConnection();
+ ps = connection.prepareStatement(sql);
+ rs = ps.executeQuery();
+ rs.setFetchSize(tableManipulation.getFetchSize());
+ while (rs.next()) {
+ InputStream is = rs.getBinaryStream(1);
+ toStreamProcess(rs, is, objectOutput);
+ }
+ marshaller.objectToObjectStream(streamDelimiter, objectOutput);
+ } catch (SQLException e) {
+ logAndThrow(e, "SQL Error while storing string keys to database");
+ } catch (IOException e) {
+ logAndThrow(e, "I/O Error while storing string keys to database");
+ }
+ finally {
+ JdbcUtil.safeClose(rs);
+ JdbcUtil.safeClose(ps);
+ connectionFactory.releaseConnection(connection);
+ }
+ }
+
+ public final Set<InternalCacheEntry> loadAllSupport() throws CacheLoaderException {
+ Connection conn = null;
+ PreparedStatement ps = null;
+ ResultSet rs = null;
+ try {
+ String sql = tableManipulation.getLoadAllRowsSql();
+ conn = connectionFactory.getConnection();
+ ps = conn.prepareStatement(sql);
+ rs = ps.executeQuery();
+ rs.setFetchSize(tableManipulation.getFetchSize());
+ Set<InternalCacheEntry> result = new HashSet<InternalCacheEntry>();
+ while (rs.next()) {
+ loadAllProcess(rs, result);
+ }
+ return result;
+ } catch (SQLException e) {
+ String message = "SQL error while fetching all StoredEntries";
+ log.error(message, e);
+ throw new CacheLoaderException(message, e);
+ } finally {
+ JdbcUtil.safeClose(rs);
+ JdbcUtil.safeClose(ps);
+ connectionFactory.releaseConnection(conn);
+ }
+ }
+
+ public abstract void loadAllProcess(ResultSet rs, Set<InternalCacheEntry> result) throws SQLException, CacheLoaderException;
+
+ public abstract void toStreamProcess(ResultSet rs, InputStream is, ObjectOutput objectOutput) throws CacheLoaderException, SQLException, IOException;
+
+ public abstract boolean fromStreamProcess(Object objFromStream, PreparedStatement ps, ObjectInput objectInput) throws SQLException, CacheLoaderException, IOException, ClassNotFoundException;
+
+ public static void logAndThrow(Exception e, String message) throws CacheLoaderException {
+ log.error(message, e);
+ throw new CacheLoaderException(message, e);
+ }
+
+}
Property changes on: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManipulationHelper.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManiulationHelper.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManiulationHelper.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/DataManiulationHelper.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.container.entries.InternalCacheEntry;
@@ -24,6 +45,7 @@
*
* @author Mircea.Markus at jboss.com
*/
+ at Deprecated //use org.infinispan.loaders.jdbc.DataManipulationHelper instead
public abstract class DataManiulationHelper {
private static Log log = LogFactory.getLog(DataManiulationHelper.class);
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/JdbcUtil.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/JdbcUtil.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/JdbcUtil.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.io.ByteBuffer;
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/TableManipulation.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/TableManipulation.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/TableManipulation.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.loaders.CacheLoaderException;
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStore.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStore.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStore.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.binary;
import org.infinispan.Cache;
@@ -7,9 +28,9 @@
import org.infinispan.loaders.CacheLoaderException;
import org.infinispan.loaders.bucket.Bucket;
import org.infinispan.loaders.bucket.BucketBasedCacheStore;
+import org.infinispan.loaders.jdbc.DataManipulationHelper;
import org.infinispan.loaders.jdbc.JdbcUtil;
import org.infinispan.loaders.jdbc.TableManipulation;
-import org.infinispan.loaders.jdbc.DataManiulationHelper;
import org.infinispan.loaders.jdbc.connectionfactory.ConnectionFactory;
import org.infinispan.marshall.Marshaller;
import org.infinispan.util.logging.Log;
@@ -30,13 +51,13 @@
/**
* {@link BucketBasedCacheStore} implementation that will store all the buckets as rows in database, each row
- * coresponding to a bucket. This is in contrast to {@link org.infinispan.loaders.jdbc.stringbased.JdbcStringBasedCacheStore}
- * which stores each StoredEntry as an row in the database.
+ * corresponding to a bucket. This is in contrast to {@link org.infinispan.loaders.jdbc.stringbased.JdbcStringBasedCacheStore}
+ * which stores each StoredEntry as a row in the database.
* <p/>
* This class has the benefit of being able to store StoredEntries that do not have String keys, at the cost of coarser
* grained access granularity, and inherently performance.
* <p/>
- * All the DB releated configurations are described in {@link org.infinispan.loaders.jdbc.binary.JdbcBinaryCacheStoreConfig}.
+ * All the DB related configurations are described in {@link org.infinispan.loaders.jdbc.binary.JdbcBinaryCacheStoreConfig}.
*
* @author Mircea.Markus at jboss.com
* @see JdbcBinaryCacheStoreConfig
@@ -51,7 +72,7 @@
private JdbcBinaryCacheStoreConfig config;
private ConnectionFactory connectionFactory;
private TableManipulation tableManipulation;
- private DataManiulationHelper dmHelper;
+ private DataManipulationHelper dmHelper;
private String cacheName;
public void init(CacheLoaderConfig config, Cache cache, Marshaller m) throws CacheLoaderException {
@@ -70,7 +91,7 @@
factory.start(config.getConnectionFactoryConfig());
doConnectionFactoryInitialization(factory);
}
- dmHelper = new DataManiulationHelper(connectionFactory, tableManipulation, marshaller) {
+ dmHelper = new DataManipulationHelper(connectionFactory, tableManipulation, marshaller) {
@Override
public void loadAllProcess(ResultSet rs, Set<InternalCacheEntry> result) throws SQLException, CacheLoaderException {
InputStream binaryStream = rs.getBinaryStream(1);
@@ -127,7 +148,7 @@
throw new CacheLoaderException("Unexpected insert result: '" + insertedRows + "'. Expected values is 1");
}
} catch (SQLException ex) {
- DataManiulationHelper.logAndThrow(ex, "sql failure while inserting bucket: " + bucket);
+ DataManipulationHelper.logAndThrow(ex, "sql failure while inserting bucket: " + bucket);
} finally {
JdbcUtil.safeClose(ps);
connectionFactory.releaseConnection(conn);
@@ -153,7 +174,7 @@
throw new CacheLoaderException("Unexpected update result: '" + updatedRows + "'. Expected values is 1");
}
} catch (SQLException e) {
- DataManiulationHelper.logAndThrow(e, "sql failure while updating bucket: " + bucket);
+ DataManipulationHelper.logAndThrow(e, "sql failure while updating bucket: " + bucket);
} finally {
JdbcUtil.safeClose(ps);
connectionFactory.releaseConnection(conn);
@@ -237,7 +258,7 @@
//if something happens make sure buckets locks are being release
releaseLocks(expiredBuckets);
connectionFactory.releaseConnection(conn);
- DataManiulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
+ DataManipulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
} finally {
JdbcUtil.safeClose(ps);
JdbcUtil.safeClose(rs);
@@ -281,7 +302,7 @@
//if something happens make sure buckets locks are being release
releaseLocks(emptyBuckets);
connectionFactory.releaseConnection(conn);
- DataManiulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
+ DataManipulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
} finally {
//release locks for the updated buckets.This won't include empty buckets, as these were migrated to emptyBuckets
releaseLocks(expiredBuckets);
@@ -314,7 +335,7 @@
}
} catch (SQLException ex) {
//if something happens make sure buckets locks are being release
- DataManiulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
+ DataManipulationHelper.logAndThrow(ex, "Failed clearing JdbcBinaryCacheStore");
} finally {
releaseLocks(emptyBuckets);
JdbcUtil.safeClose(ps);
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreConfig.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreConfig.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreConfig.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.binary;
import org.infinispan.loaders.LockSupportCacheStoreConfig;
@@ -11,6 +32,9 @@
*/
public class JdbcBinaryCacheStoreConfig extends LockSupportCacheStoreConfig {
+ /** The serialVersionUID */
+ private static final long serialVersionUID = 7659899424935453635L;
+
private ConnectionFactoryConfig connectionFactoryConfig = new ConnectionFactoryConfig();
private TableManipulation tableManipulation = new TableManipulation();
private boolean createConnectionFatory = true;
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactory.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactory.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactory.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.connectionfactory;
import org.infinispan.loaders.CacheLoaderException;
@@ -30,7 +51,7 @@
public abstract void start(ConnectionFactoryConfig config) throws CacheLoaderException;
/**
- * Closes the connection factory, including all alocated connections etc.
+ * Closes the connection factory, including all allocated connections etc.
*/
public abstract void stop();
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactoryConfig.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactoryConfig.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ConnectionFactoryConfig.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.connectionfactory;
/**
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ManagedConnectionFactory.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ManagedConnectionFactory.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/ManagedConnectionFactory.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.connectionfactory;
import org.infinispan.loaders.CacheLoaderException;
@@ -11,12 +32,11 @@
import java.sql.SQLException;
/**
- * Connection factory that can be used when on managed environments, like applicatons servers. It knows how to look into
+ * Connection factory that can be used when on managed environments, like application servers. It knows how to look into
* the JNDI tree at a certain location (configurable) and delegate connection management to the DataSource. In order to
- * enable ti one should set the following two properties in any Jdbc cache store:
+ * enable it one should set the following two properties in any Jdbc cache store:
* <pre>
- * <property name="connectionFactoryClass"
- * value="org.infinispan.loaders.jdbc.connectionfactory.ManagedConnectionFactory"/>
+ * <property name="connectionFactoryClass" value="org.infinispan.loaders.jdbc.connectionfactory.ManagedConnectionFactory"/>
* <property name="datasourceJndiLocation" value="java:/ManagedConnectionFactoryTest/DS"/>
* </pre>
*
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/PooledConnectionFactory.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/PooledConnectionFactory.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/PooledConnectionFactory.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.connectionfactory;
import com.mchange.v2.c3p0.ComboPooledDataSource;
@@ -18,7 +39,7 @@
* href="http://www.mchange.com/projects/c3p0/index.html#configuration">here</a>. The connection pool can be configured
* in various ways, as described <a href="http://www.mchange.com/projects/c3p0/index.html#configuration_files">here</a>.
* The simplest way is by having an <tt>c3p0.properties</tt> file in the classpath. If no such file is found, default,
- * hardcoded valus will be used.
+ * hardcoded values will be used.
*
* @author Mircea.Markus at jboss.com
*/
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/SimpleConnectionFactory.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/SimpleConnectionFactory.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/connectionfactory/SimpleConnectionFactory.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.connectionfactory;
import org.infinispan.loaders.CacheLoaderException;
@@ -10,7 +31,7 @@
import java.sql.SQLException;
/**
- * Connection factory implementation that will create database connection on a per invocation basis. Not recommanded in
+ * Connection factory implementation that will create database connection on a per invocation basis. Not recommended in
* production, {@link org.infinispan.loaders.jdbc.connectionfactory.PooledConnectionFactory} should rather be used.
*
* @author Mircea.Markus at jboss.com
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStore.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStore.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStore.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.Cache;
@@ -22,7 +43,7 @@
* (sometimes both, see below) based on the passed in key. In order to determine which store to use it will rely on the
* configured {@link org.infinispan.loaders.jdbc.stringbased.Key2StringMapper} )(see configuration).
* <p/>
- * The advantage it brings is the possibility of effeciently storing string(able) keyd {@link
+ * The advantage it brings is the possibility of efficiently storing string(able) keyd {@link
* org.infinispan.container.entries.InternalCacheEntry}s, and at the same time being able to store any other keys, a la
* {@link org.infinispan.loaders.jdbc.binary.JdbcBinaryCacheStore}.
* <p/>
@@ -32,7 +53,7 @@
* startup for warm caches), so performance drawback shouldn't be significant (again, most of the cases).
* <p/>
* Resource sharing - both aggregated cache loaders have locks and connection pools. The locking is not shared, each
- * loader keeping its own {@link org.infinispan.util.concurrent.locks.StripedLock} instace. Also the tables (even though
+ * loader keeping its own {@link org.infinispan.util.concurrent.locks.StripedLock} instance. Also the tables (even though
* similar as definition) are different in order to avoid key collision. On the other hand, the connection pooling is a
* shared resource.
*
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfig.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfig.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfig.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.loaders.AbstractCacheStoreConfig;
@@ -8,12 +29,14 @@
import org.infinispan.loaders.jdbc.stringbased.JdbcStringBasedCacheStoreConfig;
/**
- * Configureation for {@link org.infinispan.loaders.jdbc.mixed.JdbcMixedCacheStore}.
+ * Configuration for {@link org.infinispan.loaders.jdbc.mixed.JdbcMixedCacheStore}.
*
* @author Mircea.Markus at jboss.com
*/
public class JdbcMixedCacheStoreConfig extends AbstractCacheStoreConfig {
+ private static final long serialVersionUID = -1343548133363285687L;
+
private ConnectionFactoryConfig connectionFactoryConfig = new ConnectionFactoryConfig();
private TableManipulation binaryTableManipulation = new TableManipulation();
private TableManipulation stringsTableManipulation = new TableManipulation();
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapper.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapper.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapper.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
/**
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStore.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStore.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStore.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.infinispan.Cache;
@@ -7,7 +28,7 @@
import org.infinispan.loaders.CacheLoaderConfig;
import org.infinispan.loaders.CacheLoaderException;
import org.infinispan.loaders.LockSupportCacheStore;
-import org.infinispan.loaders.jdbc.DataManiulationHelper;
+import org.infinispan.loaders.jdbc.DataManipulationHelper;
import org.infinispan.loaders.jdbc.JdbcUtil;
import org.infinispan.loaders.jdbc.TableManipulation;
import org.infinispan.loaders.jdbc.connectionfactory.ConnectionFactory;
@@ -45,7 +66,7 @@
private static Log log = LogFactory.getLog(JdbcStringBasedCacheStore.class);
/**
- * delimits the stram for stream trasfer operations
+ * delimits the stream for stream transfer operations
*/
private static final byte STRING_STREAM_DELIMITER = 100;
@@ -53,7 +74,7 @@
private Key2StringMapper key2StringMapper;
private ConnectionFactory connectionFactory;
private TableManipulation tableManipulation;
- private DataManiulationHelper dmHelper;
+ private DataManipulationHelper dmHelper;
private String cacheName;
public void init(CacheLoaderConfig config, Cache cache, Marshaller m) throws CacheLoaderException {
@@ -72,7 +93,7 @@
doConnectionFactoryInitialization(connectionFactory);
}
this.key2StringMapper = config.getKey2StringMapper();
- dmHelper = new DataManiulationHelper(connectionFactory, tableManipulation, marshaller) {
+ dmHelper = new DataManipulationHelper(connectionFactory, tableManipulation, marshaller) {
@Override
public void loadAllProcess(ResultSet rs, Set<InternalCacheEntry> result) throws SQLException, CacheLoaderException {
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreConfig.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreConfig.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreConfig.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.infinispan.loaders.LockSupportCacheStoreConfig;
@@ -13,6 +34,9 @@
*/
public class JdbcStringBasedCacheStoreConfig extends LockSupportCacheStoreConfig {
+ /** The serialVersionUID */
+ private static final long serialVersionUID = 8835350707132331983L;
+
private Key2StringMapper key2StringMapper;
private ConnectionFactoryConfig connectionFactoryConfig = new ConnectionFactoryConfig();
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/Key2StringMapper.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/Key2StringMapper.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/Key2StringMapper.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,7 +1,28 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
/**
- * Defines the logic of mapping an key object to a String. This is required {@link JdbcStringBasedCacheStore}, in order
+ * Defines the logic of mapping a key object to a String. This is required {@link JdbcStringBasedCacheStore}, in order
* to map each key as an single row within a database. It basically should generate a unique String PK based on the
* supplied key.
*
Modified: trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/UnsupportedKeyTypeException.java
===================================================================
--- trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/UnsupportedKeyTypeException.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/main/java/org/infinispan/loaders/jdbc/stringbased/UnsupportedKeyTypeException.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.infinispan.loaders.CacheLoaderException;
@@ -11,6 +32,9 @@
*/
public class UnsupportedKeyTypeException extends CacheLoaderException {
+ /** The serialVersionUID */
+ private static final long serialVersionUID = 1442739860198872706L;
+
public UnsupportedKeyTypeException(Object key) {
this("Unsupported key type: '" + key.getClass().getName() + "' on key: " + key);
}
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/config/parsing/JdbcConfigurationParserTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/config/parsing/JdbcConfigurationParserTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/config/parsing/JdbcConfigurationParserTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.config.parsing;
import org.infinispan.config.CacheLoaderManagerConfig;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/ManagedConnectionFactoryTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/ManagedConnectionFactoryTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/ManagedConnectionFactoryTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.loaders.BaseCacheStoreTest;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/PooledConnectionFactoryTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/PooledConnectionFactoryTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/PooledConnectionFactoryTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.loaders.jdbc.connectionfactory.ConnectionFactoryConfig;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableManipulationTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableManipulationTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableManipulationTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import static org.easymock.EasyMock.*;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableNameUniquenessTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableNameUniquenessTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/TableNameUniquenessTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc;
import org.infinispan.Cache;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/BinaryStoreWithManagedConnectionTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/BinaryStoreWithManagedConnectionTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/BinaryStoreWithManagedConnectionTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.binary;
import org.infinispan.Cache;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/binary/JdbcBinaryCacheStoreTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.binary;
import static org.easymock.classextension.EasyMock.*;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfigTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfigTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreConfigTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.loaders.LockSupportCacheStoreConfig;
@@ -20,7 +41,7 @@
}
/**
- * Just take some random props and check their corectness.
+ * Just take some random props and check their correctness.
*/
public void simpleTest() {
config = new JdbcMixedCacheStoreConfig();
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.CacheDelegate;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest2.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest2.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/JdbcMixedCacheStoreTest2.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.loaders.BaseCacheStoreTest;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/MixedStoreWithManagedConnectionTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/MixedStoreWithManagedConnectionTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/mixed/MixedStoreWithManagedConnectionTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.mixed;
import org.infinispan.Cache;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapperTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapperTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/DefaultKey2StringMapperTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.testng.annotations.Test;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import static org.easymock.classextension.EasyMock.*;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest2.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest2.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/JdbcStringBasedCacheStoreTest2.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.infinispan.container.entries.InternalCacheEntry;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/Person.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/Person.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/Person.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import java.io.Serializable;
@@ -8,6 +29,10 @@
* @author Mircea.Markus at jboss.com
*/
public class Person implements Serializable {
+
+ /** The serialVersionUID */
+ private static final long serialVersionUID = -835015913569270262L;
+
private String name;
private String surname;
private int age;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/PersonKey2StringMapper.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/PersonKey2StringMapper.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/PersonKey2StringMapper.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
/**
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/StringStoreWithManagedConnectionTest.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/StringStoreWithManagedConnectionTest.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/loaders/jdbc/stringbased/StringStoreWithManagedConnectionTest.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.loaders.jdbc.stringbased;
import org.infinispan.Cache;
Modified: trunk/cachestore/jdbc/src/test/java/org/infinispan/test/fwk/UnitTestDatabaseManager.java
===================================================================
--- trunk/cachestore/jdbc/src/test/java/org/infinispan/test/fwk/UnitTestDatabaseManager.java 2009-12-04 18:37:11 UTC (rev 1252)
+++ trunk/cachestore/jdbc/src/test/java/org/infinispan/test/fwk/UnitTestDatabaseManager.java 2009-12-05 12:35:06 UTC (rev 1253)
@@ -1,6 +1,26 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.infinispan.test.fwk;
-
import org.infinispan.loaders.jdbc.JdbcUtil;
import org.infinispan.loaders.jdbc.TableManipulation;
import org.infinispan.loaders.jdbc.connectionfactory.ConnectionFactory;
More information about the infinispan-commits
mailing list