gora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rmarroq...@apache.org
Subject svn commit: r1576726 - in /gora/trunk/gora-cassandra/src: main/java/org/apache/gora/cassandra/store/ test/conf/
Date Wed, 12 Mar 2014 13:08:25 GMT
Author: rmarroquin
Date: Wed Mar 12 13:08:25 2014
New Revision: 1576726

URL: http://svn.apache.org/r1576726
Log:
GORA-154

Modified:
    gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraClient.java
    gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMapping.java
    gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
    gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/HectorUtils.java
    gora/trunk/gora-cassandra/src/test/conf/gora-cassandra-mapping.xml

Modified: gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraClient.java
URL: http://svn.apache.org/viewvc/gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraClient.java?rev=1576726&r1=1576725&r2=1576726&view=diff
==============================================================================
--- gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraClient.java
(original)
+++ gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraClient.java
Wed Mar 12 13:08:25 2014
@@ -244,6 +244,10 @@ public class CassandraClient<K, T extend
     ByteBuffer byteBuffer = toByteBuffer(value);
     String columnFamily = this.cassandraMapping.getFamily(fieldName);
     String columnName = this.cassandraMapping.getColumn(fieldName);
+    String ttlAttr = this.cassandraMapping.getColumnsAttribs().get(fieldName);
+    if (ttlAttr == null) {
+      ttlAttr = CassandraMapping.DEFAULT_COLUMNS_TTL;
+    }
 
     if (columnName == null) {
       LOG.warn("Column name is null for field=" + fieldName + " with value=" + value.toString());
@@ -251,7 +255,7 @@ public class CassandraClient<K, T extend
     }
 
     synchronized(mutator) {
-      HectorUtils.insertColumn(mutator, key, columnFamily, columnName, byteBuffer);
+      HectorUtils.insertColumn(mutator, key, columnFamily, columnName, byteBuffer, ttlAttr);
     }
   }
 
@@ -271,9 +275,13 @@ public class CassandraClient<K, T extend
 
     String columnFamily = this.cassandraMapping.getFamily(fieldName);
     String superColumnName = this.cassandraMapping.getColumn(fieldName);
+    String ttlAttr = this.cassandraMapping.getColumnsAttribs().get(fieldName);
+    if (ttlAttr  == null) {
+      ttlAttr = CassandraMapping.DEFAULT_COLUMNS_TTL;
+    }
 
     synchronized(mutator) {
-      HectorUtils.insertSubColumn(mutator, key, columnFamily, superColumnName, columnName,
byteBuffer);
+      HectorUtils.insertSubColumn(mutator, key, columnFamily, superColumnName, columnName,
byteBuffer, ttlAttr);
     }
   }
 
@@ -316,10 +324,36 @@ public class CassandraClient<K, T extend
     }
   }
 
+  /**
+   * Deletes a subColumn which is a field inside a column.
+   * @param key Identifying the row.
+   * @param fieldName The field's name.
+   * @param columnName The column's name.
+   */
   public void deleteSubColumn(K key, String fieldName, String columnName) {
     deleteSubColumn(key, fieldName, StringSerializer.get().toByteBuffer(columnName));
   }
 
+  /**
+   * Delete a row within the keyspace.
+    * @param key
+    * @param fieldName
+    * @param columnName
+    */
+  public void deleteColumn(K key, String familyName, ByteBuffer columnName) {
+    synchronized(mutator) {
+      HectorUtils.deleteColumn(mutator, key, familyName, columnName);
+      }
+    }
+
+  /**
+   * Delete all content related to a key.
+   * @param key
+   */
+  public void deleteByKey(K key) {
+    Map<String, String> familyMap = this.cassandraMapping.getFamilyMap();
+    deleteColumn(key, familyMap.values().iterator().next().toString(), null);
+  }
 
   public void addGenericArray(K key, String fieldName, GenericArray<?> array) {
     if (isSuper( cassandraMapping.getFamily(fieldName) )) {
@@ -336,7 +370,6 @@ public class CassandraClient<K, T extend
             continue;
           }
         }
-
         addSubColumn(key, fieldName, i++, itemValue);
       }
     }
@@ -365,7 +398,6 @@ public class CassandraClient<K, T extend
             continue;
           }
         }
-
         addSubColumn(key, fieldName, mapKey.toString(), mapValue);
       }
     }
@@ -428,7 +460,6 @@ public class CassandraClient<K, T extend
     QueryResult<OrderedRows<K, ByteBuffer, ByteBuffer>> queryResult = rangeSlicesQuery.execute();
     OrderedRows<K, ByteBuffer, ByteBuffer> orderedRows = queryResult.get();
 
-
     return orderedRows.getList();
   }
 
@@ -495,7 +526,6 @@ public class CassandraClient<K, T extend
 
       map.put(family + ":" + column, field);
     }
-
     return map;
   }
 
@@ -522,7 +552,6 @@ public class CassandraClient<K, T extend
     rangeSuperSlicesQuery.setRowCount(limit);
     rangeSuperSlicesQuery.setColumnNames(columnNames);
 
-
     QueryResult<OrderedSuperRows<K, String, ByteBuffer, ByteBuffer>> queryResult
= rangeSuperSlicesQuery.execute();
     OrderedSuperRows<K, String, ByteBuffer, ByteBuffer> orderedRows = queryResult.get();
     return orderedRows.getList();

Modified: gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMapping.java
URL: http://svn.apache.org/viewvc/gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMapping.java?rev=1576726&r1=1576725&r2=1576726&view=diff
==============================================================================
--- gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMapping.java
(original)
+++ gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraMapping.java
Wed Mar 12 13:08:25 2014
@@ -44,12 +44,15 @@ public class CassandraMapping {
   private static final String CLUSTER_ATTRIBUTE = "cluster";
   private static final String HOST_ATTRIBUTE = "host";
 
+  private static final String GCGRACE_SECONDS_ATTRIBUTE = "gc_grace_seconds";
+  private static final String COLUMNS_TTL_ATTRIBUTE = "ttl";
+  public static final String DEFAULT_COLUMNS_TTL = "60";
+  public static final int DEFAULT_GCGRACE_SECONDS = 30;
 
   private String hostName;
   private String clusterName;
   private String keyspaceName;
   
-  
   /**
    * List of the super column families.
    */
@@ -66,6 +69,11 @@ public class CassandraMapping {
   private Map<String, String> columnMap = new HashMap<String, String>();
 
   /**
+   * Helps storing attributes defined for each field.
+   */
+  private Map<String, String> columnAttrMap = new HashMap<String, String>();
+  
+  /**
    * Look up the column family from its name.
    */
   private Map<String, BasicColumnFamilyDefinition> columnFamilyDefinitions = 
@@ -117,7 +125,7 @@ public class CassandraMapping {
     }
     this.keyspaceName = keyspace.getAttributeValue(NAME_ATTRIBUTE);
     if (this.keyspaceName == null) {
-    	LOG.error("Error locating Cassandra Keyspace name attribute!");
+      LOG.error("Error locating Cassandra Keyspace name attribute!");
     } else {
       if (LOG.isDebugEnabled()) {
         LOG.debug("Located Cassandra Keyspace name: '" + keyspaceName + "'");
@@ -154,6 +162,15 @@ public class CassandraMapping {
           LOG.debug("Located column family: '" + familyName + "'" );
         }
       }
+      String gcgrace_scs = element.getAttributeValue(GCGRACE_SECONDS_ATTRIBUTE);
+      if (gcgrace_scs == null) {
+        LOG.warn("Error locating gc_grace_seconds attribute for '" + familyName + "' column
family");
+        LOG.warn("Using default set to: " + DEFAULT_GCGRACE_SECONDS);
+      } else {
+        if (LOG.isDebugEnabled()) {
+          LOG.debug("Located gc_grace_seconds: '" + gcgrace_scs + "'" );
+        }
+      }
       String superAttribute = element.getAttributeValue(SUPER_ATTRIBUTE);
       if (superAttribute != null) {
         if (LOG.isDebugEnabled()) {
@@ -171,7 +188,7 @@ public class CassandraMapping {
       cfDef.setName(familyName);
       cfDef.setComparatorType(ComparatorType.BYTESTYPE);
       cfDef.setDefaultValidationClass(ComparatorType.BYTESTYPE.getClassName());
-      
+      cfDef.setGcGraceSeconds(gcgrace_scs!=null?Integer.parseInt(gcgrace_scs):DEFAULT_GCGRACE_SECONDS);
       this.columnFamilyDefinitions.put(familyName, cfDef);
 
     }
@@ -182,6 +199,8 @@ public class CassandraMapping {
       String fieldName = element.getAttributeValue(NAME_ATTRIBUTE);
       String familyName = element.getAttributeValue(FAMILY_ATTRIBUTE);
       String columnName = element.getAttributeValue(COLUMN_ATTRIBUTE);
+      String ttlValue = element.getAttributeValue(COLUMNS_TTL_ATTRIBUTE);
+
       if (fieldName == null) {
        LOG.error("Field name is not declared.");
         continue;
@@ -194,6 +213,9 @@ public class CassandraMapping {
         LOG.warn("Column name (qualifier) is not declared for \"" + fieldName + "\" field.");
         columnName = fieldName;
       }
+      if (ttlValue == null) {
+        LOG.warn("TTL value is not defined for \"" + fieldName + "\" field. \n Using default
value: " + DEFAULT_COLUMNS_TTL);
+      }
 
       BasicColumnFamilyDefinition columnFamilyDefinition = this.columnFamilyDefinitions.get(familyName);
       if (columnFamilyDefinition == null) {
@@ -202,8 +224,9 @@ public class CassandraMapping {
       
       this.familyMap.put(fieldName, familyName);
       this.columnMap.put(fieldName, columnName);
-      
-    }    
+      // TODO we should find a way of storing more values into this map i.e. more column
attributes
+      this.columnAttrMap.put(columnName, ttlValue!=null?ttlValue:DEFAULT_COLUMNS_TTL);
+    }
   }
 
   /**
@@ -217,15 +240,41 @@ public class CassandraMapping {
     this.columnMap.put(pFieldName, pColumnName);
   }
 
+  /**
+   * Gets the columnFamily related to the column name.
+   * @param name
+   * @return
+   */
   public String getFamily(String name) {
     return this.familyMap.get(name);
   }
 
+  /**
+   * Gets the column related to a field.
+   * @param name
+   * @return
+   */
   public String getColumn(String name) {
     return this.columnMap.get(name);
   }
 
   /**
+   * Gets all the columnFamilies defined.
+   * @return
+   */
+  public Map<String,String> getFamilyMap(){
+    return this.familyMap;
+  }
+
+  /**
+   * Gets all attributes related to a column.
+   * @return
+   */
+  public Map<String, String> getColumnsAttribs(){
+    return this.columnAttrMap;
+  }
+
+  /**
    * Read family super attribute.
    * @param family the family name
    * @return true is the family is a super column family

Modified: gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
URL: http://svn.apache.org/viewvc/gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java?rev=1576726&r1=1576725&r2=1576726&view=diff
==============================================================================
--- gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
(original)
+++ gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
Wed Mar 12 13:08:25 2014
@@ -144,7 +144,8 @@ public class CassandraStore<K, T extends
   @Override
   public boolean delete(K key) {
     LOG.debug("delete " + key);
-    return false;
+    this.cassandraClient.deleteByKey(key);
+    return true;
   }
 
   @Override

Modified: gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/HectorUtils.java
URL: http://svn.apache.org/viewvc/gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/HectorUtils.java?rev=1576726&r1=1576725&r2=1576726&view=diff
==============================================================================
--- gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/HectorUtils.java
(original)
+++ gora/trunk/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/HectorUtils.java
Wed Mar 12 13:08:25 2014
@@ -27,6 +27,7 @@ import me.prettyprint.cassandra.serializ
 import me.prettyprint.hector.api.beans.HColumn;
 import me.prettyprint.hector.api.beans.HSuperColumn;
 import me.prettyprint.hector.api.factory.HFactory;
+import me.prettyprint.hector.api.mutation.MutationResult;
 import me.prettyprint.hector.api.mutation.Mutator;
 
 import org.apache.gora.persistency.Persistent;
@@ -38,59 +39,65 @@ import org.apache.gora.persistency.Persi
  */
 public class HectorUtils<K,T extends Persistent> {
 
-  public static<K> void insertColumn(Mutator<K> mutator, K key, String columnFamily,
ByteBuffer columnName, ByteBuffer columnValue) {
-    mutator.insert(key, columnFamily, createColumn(columnName, columnValue));
+  /** Methods to insert columns. */
+  public static<K> void insertColumn(Mutator<K> mutator, K key, String columnFamily,
ByteBuffer columnName, ByteBuffer columnValue, String ttlAttr) {
+    mutator.insert(key, columnFamily, createColumn(columnName, columnValue, ttlAttr));
   }
 
-  public static<K> void insertColumn(Mutator<K> mutator, K key, String columnFamily,
String columnName, ByteBuffer columnValue) {
-    mutator.insert(key, columnFamily, createColumn(columnName, columnValue));
+  public static<K> void insertColumn(Mutator<K> mutator, K key, String columnFamily,
String columnName, ByteBuffer columnValue, String ttlAttr) {
+    mutator.insert(key, columnFamily, createColumn(columnName, columnValue, ttlAttr));
   }
 
-
-  public static<K> HColumn<ByteBuffer,ByteBuffer> createColumn(ByteBuffer name,
ByteBuffer value) {
-    return HFactory.createColumn(name, value, ByteBufferSerializer.get(), ByteBufferSerializer.get());
+  /** Methods to create columns. */
+  public static<K> HColumn<ByteBuffer,ByteBuffer> createColumn(ByteBuffer name,
ByteBuffer value, String ttlAttr) {
+    return HFactory.createColumn(name, value, ByteBufferSerializer.get(), ByteBufferSerializer.get()).setTtl(Integer.parseInt(ttlAttr));
   }
 
-  public static<K> HColumn<String,ByteBuffer> createColumn(String name, ByteBuffer
value) {
-    return HFactory.createColumn(name, value, StringSerializer.get(), ByteBufferSerializer.get());
+  public static<K> HColumn<String,ByteBuffer> createColumn(String name, ByteBuffer
value, String ttlAttr) {
+    return HFactory.createColumn(name, value, StringSerializer.get(), ByteBufferSerializer.get()).setTtl(Integer.parseInt(ttlAttr));
   }
 
-  public static<K> HColumn<Integer,ByteBuffer> createColumn(Integer name, ByteBuffer
value) {
-    return HFactory.createColumn(name, value, IntegerSerializer.get(), ByteBufferSerializer.get());
+  public static<K> HColumn<Integer,ByteBuffer> createColumn(Integer name, ByteBuffer
value, String ttlAttr) {
+    return HFactory.createColumn(name, value, IntegerSerializer.get(), ByteBufferSerializer.get()).setTtl(Integer.parseInt(ttlAttr));
   }
 
-
-  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, ByteBuffer columnName, ByteBuffer columnValue) {
-    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue));
+  /** Methods to create subColumns. */
+  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, ByteBuffer columnName, ByteBuffer columnValue, String ttlAttr) {
+    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue,
ttlAttr));
   }
 
-  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, String columnName, ByteBuffer columnValue) {
-    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue));
+  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, String columnName, ByteBuffer columnValue, String ttlAttr) {
+    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue,
ttlAttr));
   }
 
-  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, Integer columnName, ByteBuffer columnValue) {
-    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue));
+  public static<K> void insertSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, Integer columnName, ByteBuffer columnValue, String ttlAttr) {
+    mutator.insert(key, columnFamily, createSuperColumn(superColumnName, columnName, columnValue,
ttlAttr));
   }
 
-
+  /** Methods to delete subColumns. */
   public static<K> void deleteSubColumn(Mutator<K> mutator, K key, String columnFamily,
String superColumnName, ByteBuffer columnName) {
     mutator.subDelete(key, columnFamily, superColumnName, columnName, StringSerializer.get(),
ByteBufferSerializer.get());
   }
 
+  /** Methods do delete columns. */
+  public static<K> void deleteColumn(Mutator<K> mutator, K key, String columnFamily,
ByteBuffer columnName){
+    MutationResult mr = mutator.delete(key, columnFamily, columnName, ByteBufferSerializer.get());
+    System.out.println(mr.toString());
+  }
 
+  /** Methods to create superColumns. */
   @SuppressWarnings("unchecked")
-  public static<K> HSuperColumn<String,ByteBuffer,ByteBuffer> createSuperColumn(String
superColumnName, ByteBuffer columnName, ByteBuffer columnValue) {
-    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue)), StringSerializer.get(), ByteBufferSerializer.get(), ByteBufferSerializer.get());
+  public static<K> HSuperColumn<String,ByteBuffer,ByteBuffer> createSuperColumn(String
superColumnName, ByteBuffer columnName, ByteBuffer columnValue, String ttlAttr) {
+    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue, ttlAttr)), StringSerializer.get(), ByteBufferSerializer.get(), ByteBufferSerializer.get());
   }
 
   @SuppressWarnings("unchecked")
-  public static<K> HSuperColumn<String,String,ByteBuffer> createSuperColumn(String
superColumnName, String columnName, ByteBuffer columnValue) {
-    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue)), StringSerializer.get(), StringSerializer.get(), ByteBufferSerializer.get());
+  public static<K> HSuperColumn<String,String,ByteBuffer> createSuperColumn(String
superColumnName, String columnName, ByteBuffer columnValue, String ttlAttr) {
+    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue, ttlAttr)), StringSerializer.get(), StringSerializer.get(), ByteBufferSerializer.get());
   }
 
   @SuppressWarnings("unchecked")
-  public static<K> HSuperColumn<String,Integer,ByteBuffer> createSuperColumn(String
superColumnName, Integer columnName, ByteBuffer columnValue) {
-    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue)), StringSerializer.get(), IntegerSerializer.get(), ByteBufferSerializer.get());
+  public static<K> HSuperColumn<String,Integer,ByteBuffer> createSuperColumn(String
superColumnName, Integer columnName, ByteBuffer columnValue, String ttlAttr) {
+    return HFactory.createSuperColumn(superColumnName, Arrays.asList(createColumn(columnName,
columnValue, ttlAttr)), StringSerializer.get(), IntegerSerializer.get(), ByteBufferSerializer.get());
   }
-
 }

Modified: gora/trunk/gora-cassandra/src/test/conf/gora-cassandra-mapping.xml
URL: http://svn.apache.org/viewvc/gora/trunk/gora-cassandra/src/test/conf/gora-cassandra-mapping.xml?rev=1576726&r1=1576725&r2=1576726&view=diff
==============================================================================
--- gora/trunk/gora-cassandra/src/test/conf/gora-cassandra-mapping.xml (original)
+++ gora/trunk/gora-cassandra/src/test/conf/gora-cassandra-mapping.xml Wed Mar 12 13:08:25
2014
@@ -19,39 +19,39 @@
 
 <gora-orm>
   <keyspace name="Employee" host="localhost" cluster="Gora Cassandra Test Cluster">
-    <family name="p"/>
+    <family name="p" gc_grace_seconds="5"/>
      <family name="sc" type="super" />
   </keyspace>
 
   <keyspace name="WebPage" host="localhost" cluster="Gora Cassandra Test Cluster">
-    <family name="p"/>
+    <family name="p" gc_grace_seconds="5"/>
     <family name="sc" type="super"/>
   </keyspace>
 
   <keyspace name="TokenDatum" host="localhost" cluster="Gora Cassandra Test Cluster">
-    <family name="p"/>
+    <family name="p" gc_grace_seconds="5"/>
     <family name="sc" type="super"/>
   </keyspace>
 
   <class name="org.apache.gora.examples.generated.Employee" keyClass="java.lang.String"
keyspace="Employee">
-    <field name="name"  family="p" qualifier="info:nm"/>
-    <field name="dateOfBirth"  family="p" qualifier="info:db"/>
-    <field name="ssn"  family="p" qualifier="info:sn"/>
-    <field name="salary"  family="p" qualifier="info:sl"/>
-    <field name="boss" family="p" qualifier="info:bs"/>
-    <field name="webpage" family="p" qualifier="info:wp"/>
+    <field name="name"  family="p" qualifier="info:nm" ttl="10"/>
+    <field name="dateOfBirth"  family="p" qualifier="info:db" ttl="10"/>
+    <field name="ssn"  family="p" qualifier="info:sn" ttl="10"/>
+    <field name="salary"  family="p" qualifier="info:sl" ttl="10"/>
+    <field name="boss" family="p" qualifier="info:bs" ttl="10"/>
+    <field name="webpage" family="p" qualifier="info:wp" ttl="10"/>
   </class>
 
   <class name="org.apache.gora.examples.generated.WebPage" keyClass="java.lang.String"
keyspace="WebPage">
-    <field name="url" family="p" qualifier="c:u"/>
-    <field name="content" family="p" qualifier="p:cnt:c"/>
-    <field name="parsedContent" family="sc" qualifier="p:parsedContent"/>
-    <field name="outlinks" family="sc" qualifier="p:outlinks"/>
-    <field name="metadata" family="sc" qualifier="c:mt"/>
+    <field name="url" family="p" qualifier="c:u" ttl="10"/>
+    <field name="content" family="p" qualifier="p:cnt:c" ttl="10"/>
+    <field name="parsedContent" family="sc" qualifier="p:parsedContent" ttl="10"/>
+    <field name="outlinks" family="sc" qualifier="p:outlinks" ttl="10"/>
+    <field name="metadata" family="sc" qualifier="c:mt" ttl="10"/>
   </class>
 
   <class name="org.apache.gora.examples.generated.TokenDatum" keyClass="java.lang.String"
keyspace="TokenDatum">
-    <field name="count"  family="p" qualifier="common:count"/>
+    <field name="count"  family="p" qualifier="common:count" ttl="10"/>
   </class>
 
 </gora-orm>



Mime
View raw message