Pochatkin commented on code in PR #2109:
URL: https://github.com/apache/ignite-3/pull/2109#discussion_r1214162586


##########
modules/cli/src/integrationTest/java/org/apache/ignite/internal/cli/call/unit/ItDeployUndeployCallsTest.java:
##########
@@ -92,19 +101,21 @@ void deployListStatusUndeploy() {
         // Then
         assertThat(deployOutput.hasError()).isFalse();
         
assertThat(deployOutput.body()).isEqualTo(MessageUiComponent.from(UiElements.done()).render());
-        // And list is not empty
-        List<UnitStatusRecord> unisStatuses = 
listUnitCall.execute(urlInput).body();
-        assertThat(unisStatuses.size()).isEqualTo(1);
-        // And status is not empty
-        await().untilAsserted(() -> 
assertThat(unitStatusCall.execute(statusInput("test.id"))).isNotNull());
+
+        await().untilAsserted(() -> {
+            // And list is not empty
+            List<UnitStatusRecord> unisStatuses = 
listUnitCall.execute(listAllInput()).body();

Review Comment:
   unitsStatuses



##########
modules/code-deployment/src/main/java/org/apache/ignite/internal/deployunit/metastore/status/UnitKey.java:
##########
@@ -45,17 +44,24 @@ static String[] fromBytes(String prefix, byte[] key) {
         }
 
         String content = s.substring(prefix.length());
+        if (content.isEmpty()) {
+            return new String[0];
+        }
         return Arrays.stream(content.split(DELIMITER))
                 .map(e -> new String(Base64.getDecoder().decode(e), 
StandardCharsets.UTF_8))
                 .toArray(String[]::new);
     }
 
-    static ByteArray toByteArray(String prefix, String... args) {
+    static ByteArray toByteArray(String prefix, String id, String... args) {
         Encoder encoder = Base64.getEncoder();
-        String collect = Arrays.stream(args).filter(Objects::nonNull)
+
+        // Always add a delimiter if id is present so that the lookup on id 
will hapen on exact match

Review Comment:
   happen



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to