public void start() throws Exception {
  if (dbsvc != null) {
    return;
  }
  DataObjectScanner dataObjectScanner=new DataObjectScanner();
  dataObjectScanner.setPackages(modelPackages.toArray(new String[0]));
  dataObjectScanner.init();
  ServiceImpl dummyDBService=new ServiceImpl();
  dummyDBService.setName("dbsvc");
  dummyDBService.setVersion("1");
  dummyDBService.setEndpoint(URI.create("thrift://localhost:9170"));
  dummyDBService.setId("foobar");
  SchemaUtil schemaUtil=new SchemaUtil();
  schemaUtil.setKeyspaceName("Testing");
  schemaUtil.setService(dummyDBService);
  schemaUtil.setCoordinator(coordinatorClient);
  schemaUtil.setDataObjectScanner(dataObjectScanner);
  String config=createConfig(dataDir.getAbsolutePath());
  dbsvc=new DbServiceImpl();
  dbsvc.setConfig(config);
  dbsvc.setSchemaUtil(schemaUtil);
  dbsvc.setCoordinator(coordinatorClient);
  dbsvc.setService(dummyDBService);
  dbsvc.start();
}

public void start ( ) throws Exception { if ( dbsvc != null ) { return ; } DataObjectScanner dataObjectScanner = new DataObjectScanner ( ) ; dataObjectScanner . setPackages ( modelPackages . toArray ( new String [ 0 ] ) ) ; dataObjectScanner . init ( ) ; ServiceImpl dummyDBService = new ServiceImpl ( ) ; dummyDBService . setName ( "dbsvc" ) ; dummyDBService . setVersion ( "1" ) ; dummyDBService . setEndpoint ( URI . create ( "thrift://localhost:9170" ) ) ; dummyDBService . setId ( "foobar" ) ; SchemaUtil schemaUtil = new SchemaUtil ( ) ; schemaUtil . setKeyspaceName ( "Testing" ) ; schemaUtil . setService ( dummyDBService ) ; schemaUtil . setCoordinator ( coordinatorClient ) ; schemaUtil . setDataObjectScanner ( dataObjectScanner ) ; String config = createConfig ( dataDir . getAbsolutePath ( ) ) ; dbsvc = new DbServiceImpl ( ) ; dbsvc . setConfig ( config ) ; dbsvc . setSchemaUtil ( schemaUtil ) ; dbsvc . setCoordinator ( coordinatorClient ) ; dbsvc . setService ( dummyDBService ) ; dbsvc . start ( ) ; }
starts the cassandra db , using any persisted data files
