-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Ignite 27473 #12642
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Ignite 27473 #12642
Conversation
|
|
||
| DataStorageConfiguration dsCfg = ctx.config().getDataStorageConfiguration(); | ||
|
|
||
| if (dsCfg != null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if (dsCfg != null) | |
| if (CU.isPersistenceEnabled(dsCfg)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To avoid test failures in IgniteKernalSelfTestSuite, let’s do the following:
ctx.addNodeAttribute(ATTR_WAL_MODE,
dsCfg != null ? dsCfg.getWalMode().ordinal() : DataStorageConfiguration.DFLT_WAL_MODE.ordinal());
|
|
||
| GridTestUtils.assertThrowsWithCause(() -> startGrid(1), IgniteCheckedException.class); | ||
|
|
||
| assertTrue(walModeErrorLsnr.check()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I propose getting rid of LogListener and simply checking the error message, for example:
String errMsg = GridTestUtils.assertThrowsWithCause(() -> startGrid(1), IgniteCheckedException.class)
.getCause().getMessage();
assertTrue(errMsg.startsWith("Remote node has WAL mode different from local") &&
errMsg.contains("locWalMode=FSYNC") && errMsg.contains("rmtWalMode=LOG_ONLY"));
| DataStorageConfiguration dsCfg = ctx.config().getDataStorageConfiguration(); | ||
|
|
||
| if (dsCfg != null) | ||
| ctx.addNodeAttribute(ATTR_WAL_MODE, dsCfg.getWalMode()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| ctx.addNodeAttribute(ATTR_WAL_MODE, dsCfg.getWalMode()); | |
| ctx.addNodeAttribute(ATTR_WAL_MODE, dsCfg.getWalMode().ordinal()); |
|
|
||
| Boolean locSecurityCompatibilityEnabled = locNode.attribute(ATTR_SECURITY_COMPATIBILITY_MODE); | ||
|
|
||
| WALMode locWalMode = locNode.attribute(ATTR_WAL_MODE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| WALMode locWalMode = locNode.attribute(ATTR_WAL_MODE); | |
| WALMode locWalMode = locNode.attribute(ATTR_WAL_MODE) == null ? null : WALMode.fromOrdinal(locNode.attribute(ATTR_WAL_MODE)); |
| } | ||
| } | ||
|
|
||
| WALMode rmtWalMode = n.attribute(ATTR_WAL_MODE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| WALMode rmtWalMode = n.attribute(ATTR_WAL_MODE); | |
| WALMode rmtWalMode = n.attribute(ATTR_WAL_MODE) == null ? null : WALMode.fromOrdinal(n.attribute(ATTR_WAL_MODE)); |
|
|
||
| WALMode rmtWalMode = n.attribute(ATTR_WAL_MODE); | ||
|
|
||
| if (locWalMode != rmtWalMode) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if (locWalMode != rmtWalMode) { | |
| if (!Objects.equals(locWalMode, rmtWalMode)) { |
Thank you for submitting the pull request to the Apache Ignite.
In order to streamline the review of the contribution
we ask you to ensure the following steps have been taken:
The Contribution Checklist
The description explains WHAT and WHY was made instead of HOW.
The following pattern must be used:
IGNITE-XXXX Change summarywhereXXXX- number of JIRA issue.(see the Maintainers list)
the
green visaattached to the JIRA ticket (see TC.Bot: Check PR)Notes
If you need any help, please email [email protected] or ask anу advice on http://asf.slack.com #ignite channel.