Upgrade Elasticsearch from 7.8.1 to 7.14.2

Hello, I am having two issues with the upgrade from 7.8.1 to 7.14.2

  1. I downloaded the tar.gz file for 7.14.2 and launched the Elasticsearch instance by running /bin/Elasticsearch. The instance updates existing indices and uses them. However, it seems like I am unable to go back and launch 7.8.1 Elasticsearch since it returns an exception: IndexFormatTooNewException. Is there a way to rollback to 7.8.1?
  2. there is an issue with this import
    import org.elasticsearch.common.unit.TimeValue;
    when changing the version in pom.xml maven dependency from 7.8.1 to 7.14.2
    The code does not compile and I cannot find a solution. A part of the code is dependent on this import. Please help!
        <properties>
            <es.version>7.14.2</es.version>
        </properties>
        <dependency>
            <groupId>org.elasticsearch</groupId>
            <artifactId>elasticsearch</artifactId>
            <version>${es.version}</version>
        </dependency>
        <dependency>
            <groupId>org.elasticsearch</groupId>
            <artifactId>elasticsearch-core</artifactId>
            <version>${es.version}</version>
        </dependency>

That would require you to restore a snapshot taken prior to the upgrade. Elasticsearch does otherwise not support downgrading.

what about the second question? I think the import uses Elasticsearch-core as a dependency. But it fails to compile.

Have a look at

import org.elasticsearch.common.unit.TimeValue;
should be replaced by:
import org.elasticsearch.core.TimeValue;

This should solve the problem. Let me try. Thank you.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.