/** * Performs an insert/update for a row in Cassandra. * * @param rowKey * @param attributes */ public void upsert(String rowKey, Map<String, Object> attributes) { new HystrixCassandraPut<String>(keyspace, COLUMN_FAMILY, rowKey, attributes).execute(); }
@SuppressWarnings("unchecked") public HystrixCassandraPut(Keyspace keyspace, String columnFamilyName, RowKeyType rowKey, Map<String, Object> attributes, int ttlSeconds) { this.keyspace = keyspace; this.columnFamily = getColumnFamilyViaColumnName(columnFamilyName, rowKey); this.rowKey = rowKey; this.attributes = attributes; if(ttlSeconds > 0){ this.ttlSeconds = ttlSeconds; } }
/** * Performs an insert/update for a row in Cassandra. * * @param rowKey * @param attributes */ @Override public void upsert(String rowKey, Map<String, Object> attributes) { new HystrixCassandraPut<String>(keyspace, COLUMN_FAMILY, rowKey, attributes).execute(); }
@SuppressWarnings("unchecked") public HystrixCassandraPut(Keyspace keyspace, String columnFamilyName, RowKeyType rowKey, Map<String, Object> attributes, int ttlSeconds) { this.keyspace = keyspace; this.columnFamily = getColumnFamilyViaColumnName(columnFamilyName, rowKey); this.rowKey = rowKey; this.attributes = attributes; if(ttlSeconds > 0){ this.ttlSeconds = ttlSeconds; } }
public void updateFilterIndex(String rowKey, String filter_ids) { HashMap<String, Object> attributes = new HashMap<String, Object>(); attributes.put("index_name", rowKey); attributes.put("filter_ids", filter_ids); new HystrixCassandraPut<String>(keyspace, "zuul_filter_indices", rowKey, attributes).execute(); }
@Override public void updateFilterIndex(String rowKey, String filter_ids) { HashMap<String, Object> attributes = new HashMap<String, Object>(); attributes.put("index_name", rowKey); attributes.put("filter_ids", filter_ids); new HystrixCassandraPut<String>(keyspace, "zuul_filter_indices", rowKey, attributes).execute(); }