[
https://issues.apache.org/jira/browse/IGNITE-16523?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Amelchev Nikita updated IGNITE-16523:
-------------------------------------
Release Note: Fixed rollover by timeout that leads to node restart fail
> WALForceArchiveTimeout lead to node fails to restart
> ----------------------------------------------------
>
> Key: IGNITE-16523
> URL: https://issues.apache.org/jira/browse/IGNITE-16523
> Project: Ignite
> Issue Type: Improvement
> Reporter: Nikolay Izhikov
> Assignee: Nikolay Izhikov
> Priority: Blocker
> Labels: IEP-59
> Fix For: 2.13
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> When WALForceArchiveTimeout set node failed to restart.
> {code:java}
> /** */
> @RunWith(Parameterized.class)
> public class RestartWithWalForceArchiveTimeoutTest extends
> GridCommonAbstractTest {
> /** */
> @Parameterized.Parameter
> public WALMode walMode;
> /** {@inheritDoc} */
> @Override protected IgniteConfiguration getConfiguration(String
> igniteInstanceName) throws Exception {
> IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
> cfg.setConsistentId(igniteInstanceName);
> cfg.setDataStorageConfiguration(new DataStorageConfiguration()
> .setWalMode(walMode)
> .setWalForceArchiveTimeout(60 * 60 * 1000) // 1 hour to make sure
> auto archive will not work.
> .setDefaultDataRegionConfiguration(new
> DataRegionConfiguration().setPersistenceEnabled(true)));
> return cfg;
> }
> /** */
> @Parameterized.Parameters(name = "walMode={0}")
> public static Collection<?> parameters() {
> return EnumSet.of(WALMode.FSYNC, WALMode.LOG_ONLY,
> WALMode.BACKGROUND);
> }
> /** */
> @Test
> public void testRestart() throws Exception {
> stopAllGrids(true);
> cleanPersistenceDir();
> Supplier<IgniteEx> restart = () -> {
> stopAllGrids(true);
> try {
> IgniteEx ign = startGrid(getConfiguration("ignite-0"));
> ign.cluster().state(ACTIVE);
> return ign;
> }
> catch (Exception e) {
> throw new RuntimeException(e);
> }
> };
> IgniteEx ign = restart.get();
> IgniteCache<Integer, AbstractCdcTest.User> cache =
> ign.getOrCreateCache(DEFAULT_CACHE_NAME);
> addData(cache, 0, 100);
> ign = restart.get();
> cache = ign.getOrCreateCache(DEFAULT_CACHE_NAME);
> addData(cache, 100, 200);
> ign = restart.get();
> cache = ign.getOrCreateCache(DEFAULT_CACHE_NAME);
> addData(cache, 200, 300);
> restart.get();
> }
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.20.1#820001)