@Override public Collection<PathCallInformation> retrieveTrackingIds( Date startTime, Date endTime ) { final QueryResult<OrderedRows<String, String, Long>> cResult = // HFactory.createRangeSlicesQuery( keyspace, // StringSerializer.get(), // StringSerializer.get(), // LongSerializer.get() ) // .setColumnNames( "trackingId", "nodeId", "className", "methodName", "startTime", "executionTime", "level" ) // .addEqualsExpression( "level", Long.valueOf( 1 ) ) // .addGteExpression( "startTime", startTime.getTime() ) // .setColumnFamily( family ) // .execute(); int size = cResult.get().getList().size(); Set<PathCallInformation> ids = new TreeSet<PathCallInformation>( PathCallInformation.COMPARATOR ); OrderedRows<String, String, Long> rows = cResult.get(); if ( rows == null ) { return ids; } for ( Row<String, String, Long> row : rows.getList() ) { ColumnSlice<String, Long> columnSlice = row.getColumnSlice(); PathTrackingEntry pathTrackingEntry = map( columnSlice ); ids.add( new PathCallInformation( pathTrackingEntry.getTrackingId(), new Date( pathTrackingEntry.getStartTime() / 1000000 ) ) ); } return ids; }
@Override public Collection<PathCallInformation> retrieveTrackingIds( Date startTime, Date endTime ) { final QueryResult<OrderedRows<String, String, Long>> cResult = // HFactory.createRangeSlicesQuery( keyspace, // StringSerializer.get(), // StringSerializer.get(), // LongSerializer.get() ) // .setColumnNames( "trackingId", "nodeId", "className", "methodName", "startTime", "executionTime", "level" ) // .addEqualsExpression( "level", Long.valueOf( 1 ) ) // .addGteExpression( "startTime", startTime.getTime() ) // .setColumnFamily( family ) // .execute(); int size = cResult.get().getList().size(); Set<PathCallInformation> ids = new TreeSet<PathCallInformation>( PathCallInformation.COMPARATOR ); OrderedRows<String, String, Long> rows = cResult.get(); if ( rows == null ) { return ids; } for ( Row<String, String, Long> row : rows.getList() ) { ColumnSlice<String, Long> columnSlice = row.getColumnSlice(); PathTrackingEntry pathTrackingEntry = map( columnSlice ); ids.add( new PathCallInformation( pathTrackingEntry.getTrackingId(), new Date( pathTrackingEntry.getStartTime() / 1000000 ) ) ); } return ids; }
query = query.addGteExpression( WHEN_GATHERED.toString(), startTime.getTime() );