Skip to content

Commit

Permalink
Merge pull request #145 from soramitsu/scn/update_to_pre_rc_22.2
Browse files Browse the repository at this point in the history
update to 995da4ec, java-SDK version
  • Loading branch information
timofeevmd authored Sep 9, 2024
2 parents aa0ceef + 2ad8a5a commit d98519a
Show file tree
Hide file tree
Showing 9 changed files with 105,441 additions and 55,210 deletions.
3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
<maven-compiler-plugin.version>3.13.0</maven-compiler-plugin.version>
<maven-resources-plugin.version>3.3.1</maven-resources-plugin.version>
<maven-jar-plugin.version>3.4.2</maven-jar-plugin.version>
<!--iroha-java.version>f908546812</iroha-java.version-->
<iroha-java.version>e23b548</iroha-java.version>
<iroha-java.version>9aba55183e</iroha-java.version>
<jackson.versaion>2.14.1</jackson.versaion>
<commons-codec.version>1.15</commons-codec.version>
<lombok.version>1.18.24</lombok.version>
Expand Down
12 changes: 5 additions & 7 deletions src/test/java/FunctionalTest/SendQuery.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public class SendQuery {
//@Test
public void findAllAssets() {
Iroha2AsyncClient client;
try {
/*try {
client = builderAsyncClient("/peer-0");
QueryAndExtractor<List<Asset>> query = QueryBuilder
.findAllAssets()
Expand All @@ -28,17 +28,15 @@ public void findAllAssets() {
} catch (MalformedURLException | InterruptedException | ExecutionException e) {
System.out.println("EXEPTION: " + e.getMessage());
throw new RuntimeException(e);
}
}*/

}

private Iroha2AsyncClient builderAsyncClient(String targetPeer) throws MalformedURLException {
List<IrohaUrls> irohaUrls = new ArrayList<>();
irohaUrls.add(new IrohaUrls(
new URL("https://iroha2.test.tachi.soramitsu.co.jp" + targetPeer),
new URL("https://iroha2.test.tachi.soramitsu.co.jp"),
new URL("https://iroha2.test.tachi.soramitsu.co.jp" + targetPeer))
);
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", targetPeer));
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", ""));
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", targetPeer));

return new Iroha2AsyncClient(
irohaUrls,
Expand Down
22 changes: 11 additions & 11 deletions src/test/java/scenarious/irohaClient/BatchQueries.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,15 @@ public class BatchQueries {
}
).repeat(10).on(
CoreDsl.exec(session -> {
try {
client.sendQueryAsCompletableFuture(buildFindAllAssetsQuery(session)).get();
/*try {
//client.sendQueryAsCompletableFuture(buildFindAllAssetsQuery(session)).get();
return session;
} catch (InterruptedException | ExecutionException e) {
e.printStackTrace();
e.getMessage();
throw new RuntimeException(e);
}
}*/
return session;
}
)
);
Expand All @@ -60,14 +61,15 @@ public class BatchQueries {
}
).repeat(10).on(
CoreDsl.exec(session -> {
try {
/*try {
client.sendQueryAsCompletableFuture(buildFindAssetByIdQuery(session)).get();
return session;
} catch (InterruptedException | ExecutionException e) {
e.printStackTrace();
e.getMessage();
throw new RuntimeException(e);
}
}*/
return session;
}
)
);
Expand All @@ -91,12 +93,10 @@ private static QueryAndExtractor<List<Asset>> buildFindAllAssetsQuery(Session se

private static Iroha2AsyncClient builderAsyncClient(String targetPeer) throws MalformedURLException {
List<IrohaUrls> irohaUrls = new ArrayList<>();
irohaUrls.add(new IrohaUrls(
new URL("https://iroha2.test.tachi.soramitsu.co.jp" + targetPeer),
new URL("https://iroha2.test.tachi.soramitsu.co.jp"),
new URL("https://iroha2.test.tachi.soramitsu.co.jp" + targetPeer)
)
);
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", targetPeer));
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", ""));
irohaUrls.add(new IrohaUrls("https://iroha2.test.tachi.soramitsu.co.jp", targetPeer));

Iroha2AsyncClient client1 = new Iroha2AsyncClient(
irohaUrls,
true,
Expand Down
Loading

0 comments on commit d98519a

Please sign in to comment.