public ByteBuffer execute(ProtocolVersion protocolVersion, List<ByteBuffer> parameters) { return ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes()); } };
public ByteBuffer execute(ProtocolVersion protocolVersion, List<ByteBuffer> parameters) { return ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes()); } };
public ByteBuffer execute(ProtocolVersion protocolVersion, List<ByteBuffer> parameters) { return ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes()); } };
public ByteBuffer execute(List<ByteBuffer> parameters) { return ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes()); }
public LogEntry(String keyspace, ByteBuffer rowKey, ConsistencyLevel consistencyLevel, String host, long timestamp, Collection<String> columnNames) { this.keyspace = keyspace; this.rowKey = rowKey; this.uuid = UUIDGen.getUUID(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())).toString(); this.status = LogEntryStatus.PREPARING; this.consistencyLevel = consistencyLevel; this.timestamp = timestamp; this.host = host; this.columnNames = columnNames; }
public static CounterId generate() { return new CounterId(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); }
public static CounterId generate() { return new CounterId(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); }
public static CounterId generate() { return new CounterId(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); }
public static CounterId generate() { return new CounterId(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); }
public static CounterId generate() { return new CounterId(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); }
public UUID newSession(Map<String,ByteBuffer> customPayload) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), TraceType.QUERY, customPayload); }
public UUID newSession(TraceType traceType) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), traceType, Collections.EMPTY_MAP); }
public UUID newSession(TraceType traceType) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), traceType, Collections.EMPTY_MAP); }
public UUID newSession(Map<String,ByteBuffer> customPayload) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), TraceType.QUERY, customPayload); }
public UUID newSession(TraceType traceType) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), traceType, Collections.EMPTY_MAP); }
public UUID newSession() { return newSession(TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes()))); }
public UUID newSession(Map<String,ByteBuffer> customPayload) { return newSession( TimeUUIDType.instance.compose(ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())), TraceType.QUERY, customPayload); }
public void execute(DecoratedKey partitionKey, UpdateParameters params) throws InvalidRequestException { assert column.type.isMultiCell() : "Attempted to prepend to a frozen list"; Term.Terminal value = t.bind(params.options); if (value == null || value == UNSET_VALUE) return; long time = PrecisionTime.REFERENCE_TIME - (System.currentTimeMillis() - PrecisionTime.REFERENCE_TIME); List<ByteBuffer> toAdd = ((Value) value).elements; for (int i = toAdd.size() - 1; i >= 0; i--) { PrecisionTime pt = PrecisionTime.getNext(time); ByteBuffer uuid = ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes(pt.millis, pt.nanos)); params.addCell(column, CellPath.create(uuid), toAdd.get(i)); } } }
public CFRowAdder addListEntry(String cql3ColumnName, Object value) { ColumnDefinition def = getDefinition(cql3ColumnName); assert def.type instanceof ListType; CellName name = cf.getComparator().create(prefix, def, ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes())); return add(name, def, value); }
public void execute(ByteBuffer rowKey, ColumnFamily cf, Composite prefix, UpdateParameters params) throws InvalidRequestException { assert column.type.isMultiCell() : "Attempted to prepend to a frozen list"; Term.Terminal value = t.bind(params.options); if (value == null) return; assert value instanceof Lists.Value; long time = PrecisionTime.REFERENCE_TIME - (System.currentTimeMillis() - PrecisionTime.REFERENCE_TIME); List<ByteBuffer> toAdd = ((Lists.Value)value).elements; for (int i = toAdd.size() - 1; i >= 0; i--) { PrecisionTime pt = PrecisionTime.getNext(time); ByteBuffer uuid = ByteBuffer.wrap(UUIDGen.getTimeUUIDBytes(pt.millis, pt.nanos)); cf.addColumn(params.makeColumn(cf.getComparator().create(prefix, column, uuid), toAdd.get(i))); } } }