Skip to content

Commit f314e30

Browse files
fixed thread sleep
1 parent 85cc69b commit f314e30

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/main/java/com/datastax/cdm/CassandraDatasetManager.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,9 @@ void install(String name) throws IOException, InterruptedException, GitAPIExcept
243243

244244
System.out.println(createKeyspace);
245245
session.execute("DROP KEYSPACE IF EXISTS " + config.keyspace);
246+
Thread.sleep(2000);
246247
session.execute(createKeyspace.toString());
248+
247249
session.execute("USE " + config.keyspace);
248250

249251
System.out.println("Schema: " + schema);
@@ -252,6 +254,7 @@ void install(String name) throws IOException, InterruptedException, GitAPIExcept
252254
byte[] bytes = Files.readAllBytes(Paths.get(schema));
253255
String[] create_tables = new String(bytes).split(";");
254256
for(String c: create_tables) {
257+
Thread.sleep(2000);
255258
String tmp = c.trim();
256259
if(tmp.length() > 0) {
257260
session.execute(tmp);

0 commit comments

Comments
 (0)