fixed creation of secondary index on ATTACHMENTS CF
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portal/social-networking-library@133058 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
036880784d
commit
872dd71b75
|
@ -254,7 +254,7 @@ public class CassandraClusterConnection {
|
|||
/**
|
||||
* define Attachments CF with FeedId as secondary index
|
||||
*/
|
||||
ColumnFamilyDefinition cfDefAttachments = getStaticCFDef(DBCassandraAstyanaxImpl.ATTACHMENTS, "Feedid");
|
||||
ColumnFamilyDefinition cfDefAttachments = getStaticCFDef(DBCassandraAstyanaxImpl.ATTACHMENTS, "feedId");
|
||||
|
||||
|
||||
//get dynamic column families, act as auxiliary indexes
|
||||
|
|
|
@ -2167,7 +2167,7 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
|||
}
|
||||
List<Attachment> toReturn = new ArrayList<Attachment>();
|
||||
|
||||
PreparedIndexExpression<String, String> clause = cf_Attachments.newIndexClause().whereColumn("Feedid").equals().value(feedId);
|
||||
PreparedIndexExpression<String, String> clause = cf_Attachments.newIndexClause().whereColumn("feedId").equals().value(feedId);
|
||||
OperationResult<Rows<String, String>> result;
|
||||
try {
|
||||
result = conn.getKeyspace().prepareQuery(cf_Attachments)
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
package org.gcube.portal.databook.server;
|
||||
import java.util.UUID;
|
||||
|
||||
import org.junit.AfterClass;
|
||||
import org.junit.BeforeClass;
|
||||
import org.junit.Test;
|
||||
|
@ -322,7 +324,7 @@ public class DatabookCassandraTest {
|
|||
// }
|
||||
// System.out.println("addStaticColumnFamily END");
|
||||
// }
|
||||
|
||||
//
|
||||
|
||||
// /**
|
||||
// * use exclusively to add a new (Dynamic) CF to a keyspace
|
||||
|
|
Loading…
Reference in New Issue