timoninmaxim commented on code in PR #11057:
URL: https://github.com/apache/ignite/pull/11057#discussion_r1399138538
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -176,10 +279,19 @@ public DumpReader(DumpReaderConfiguration cfg,
IgniteLogger log) {
finally {
cnsmr.stop();
}
+
+ runOk = true;
}
- catch (Exception e) {
- throw new IgniteException(e);
+ catch (Throwable e) {
+ log.error("Error running DumpReader", e);
+
+ e.printStackTrace();
Review Comment:
AFAIR, `log.error` already prints this.
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -176,10 +279,19 @@ public DumpReader(DumpReaderConfiguration cfg,
IgniteLogger log) {
finally {
cnsmr.stop();
}
+
+ runOk = true;
}
- catch (Exception e) {
- throw new IgniteException(e);
+ catch (Throwable e) {
+ log.error("Error running DumpReader", e);
Review Comment:
Log error status here.
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -176,10 +279,19 @@ public DumpReader(DumpReaderConfiguration cfg,
IgniteLogger log) {
finally {
cnsmr.stop();
}
+
+ runOk = true;
Review Comment:
just log "OK" here.
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -111,6 +120,62 @@ public DumpReader(DumpReaderConfiguration cfg,
IgniteLogger log) {
Map<Integer, Set<Integer>> groups = cfg.skipCopies() ? new
HashMap<>() : null;
+ if (groups != null)
Review Comment:
code duplication
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -225,10 +337,6 @@ private void ackAsciiLogo() {
if (log instanceof GridLoggerProxy)
U.quiet(false, " ^-- Logging by '" +
((GridLoggerProxy)log).getLoggerInfo() + '\'');
-
Review Comment:
Why this change?
##########
modules/core/src/main/java/org/apache/ignite/dump/DumpReader.java:
##########
@@ -111,6 +120,62 @@ public DumpReader(DumpReaderConfiguration cfg,
IgniteLogger log) {
Map<Integer, Set<Integer>> groups = cfg.skipCopies() ? new
HashMap<>() : null;
+ if (groups != null)
+ grpToNodes.keySet().forEach(grpId -> groups.put(grpId, new
HashSet<>()));
+
+ int partsCount = grpToNodes.entrySet().stream().mapToInt(e ->
Review Comment:
count -> cnt
--
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]