Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
import com.fasterxml.jackson.core.JsonToken;
import com.fasterxml.jackson.core.exc.InputCoercionException;
import com.fasterxml.jackson.core.exc.StreamConstraintsException;
import com.fasterxml.jackson.core.filter.FilteringParserDelegate;
import com.fasterxml.jackson.core.io.JsonEOFException;

import org.elasticsearch.core.IOUtils;
Expand All @@ -27,7 +26,6 @@
import org.elasticsearch.xcontent.XContentParserConfiguration;
import org.elasticsearch.xcontent.XContentString;
import org.elasticsearch.xcontent.XContentType;
import org.elasticsearch.xcontent.provider.OptimizedTextCapable;
import org.elasticsearch.xcontent.provider.XContentParserConfigurationImpl;
import org.elasticsearch.xcontent.support.AbstractXContentParser;

Expand Down Expand Up @@ -145,19 +143,7 @@ public String text() throws IOException {

@Override
public XContentString optimizedText() throws IOException {
if (currentToken().isValue() == false) {
throwOnNoText();
}
var parser = this.parser;
if (parser instanceof FilteringParserDelegate delegate) {
parser = delegate.delegate();
}
if (parser instanceof OptimizedTextCapable optimizedTextCapableParser) {
var bytesRef = optimizedTextCapableParser.getValueAsText();
if (bytesRef != null) {
return bytesRef;
}
}
// TODO: enable utf-8 parsing optimization once verified it is completely safe
return new Text(text());
}

Expand Down
48 changes: 0 additions & 48 deletions muted-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -618,48 +618,12 @@ tests:
- class: org.elasticsearch.search.vectors.CachingEnableFilterQueryTests
method: testBooleanQuery
issue: https://github.com/elastic/elasticsearch/issues/135124
- class: org.elasticsearch.xpack.logsdb.qa.LogsDbVersusLogsDbReindexedIntoStandardModeChallengeRestIT
method: testEsqlTermsAggregationByMethod
issue: https://github.com/elastic/elasticsearch/issues/135125
- class: org.elasticsearch.xpack.logsdb.qa.BulkStoredSourceChallengeRestIT
method: testEsqlTermsAggregationByMethod
issue: https://github.com/elastic/elasticsearch/issues/135126
- class: org.elasticsearch.xpack.logsdb.qa.StandardVersusStandardReindexedIntoLogsDbChallengeRestIT
method: testEsqlTermsAggregationByMethod
issue: https://github.com/elastic/elasticsearch/issues/135127
- class: org.elasticsearch.xpack.logsdb.qa.BulkChallengeRestIT
method: testEsqlTermsAggregationByMethod
issue: https://github.com/elastic/elasticsearch/issues/135128
- class: org.elasticsearch.xpack.test.rest.XPackRestIT
method: test {p0=transform/transforms_start_stop/Test stop transform with force and wait_for_checkpoint true}
issue: https://github.com/elastic/elasticsearch/issues/135135
- class: org.elasticsearch.compute.aggregation.SampleIntAggregatorFunctionTests
method: testSimpleWithCranky
issue: https://github.com/elastic/elasticsearch/issues/135137
- class: org.elasticsearch.xpack.logsdb.qa.BulkStoredSourceChallengeRestIT
method: testTermsAggregation
issue: https://github.com/elastic/elasticsearch/issues/135140
- class: org.elasticsearch.xpack.logsdb.qa.LogsDbVersusLogsDbReindexedIntoStandardModeChallengeRestIT
method: testTermsAggregation
issue: https://github.com/elastic/elasticsearch/issues/135141
- class: org.elasticsearch.xpack.logsdb.qa.BulkChallengeRestIT
method: testTermsAggregation
issue: https://github.com/elastic/elasticsearch/issues/135142
- class: org.elasticsearch.xpack.logsdb.qa.StandardVersusStandardReindexedIntoLogsDbChallengeRestIT
method: testTermsAggregation
issue: https://github.com/elastic/elasticsearch/issues/135143
- class: org.elasticsearch.xpack.logsdb.qa.BulkStoredSourceChallengeRestIT
method: testMatchAllQuery
issue: https://github.com/elastic/elasticsearch/issues/135144
- class: org.elasticsearch.xpack.logsdb.qa.BulkChallengeRestIT
method: testMatchAllQuery
issue: https://github.com/elastic/elasticsearch/issues/135145
- class: org.elasticsearch.xpack.logsdb.qa.LogsDbVersusLogsDbReindexedIntoStandardModeChallengeRestIT
method: testMatchAllQuery
issue: https://github.com/elastic/elasticsearch/issues/135146
- class: org.elasticsearch.xpack.logsdb.qa.StandardVersusStandardReindexedIntoLogsDbChallengeRestIT
method: testMatchAllQuery
issue: https://github.com/elastic/elasticsearch/issues/135147
- class: org.elasticsearch.lucene.RollingUpgradeSearchableSnapshotIndexCompatibilityIT
method: testSearchableSnapshotUpgrade {p0=[9.2.0, 9.2.0, 9.2.0]}
issue: https://github.com/elastic/elasticsearch/issues/135150
Expand All @@ -669,18 +633,6 @@ tests:
- class: org.elasticsearch.discovery.ClusterDisruptionIT
method: testAckedIndexing
issue: https://github.com/elastic/elasticsearch/issues/117024
- class: org.elasticsearch.xpack.logsdb.qa.BulkChallengeRestIT
method: testHistogramAggregation
issue: https://github.com/elastic/elasticsearch/issues/135153
- class: org.elasticsearch.xpack.logsdb.qa.LogsDbVersusLogsDbReindexedIntoStandardModeChallengeRestIT
method: testHistogramAggregation
issue: https://github.com/elastic/elasticsearch/issues/135154
- class: org.elasticsearch.xpack.logsdb.qa.StandardVersusStandardReindexedIntoLogsDbChallengeRestIT
method: testHistogramAggregation
issue: https://github.com/elastic/elasticsearch/issues/135155
- class: org.elasticsearch.xpack.logsdb.qa.BulkStoredSourceChallengeRestIT
method: testHistogramAggregation
issue: https://github.com/elastic/elasticsearch/issues/135156
- class: org.elasticsearch.compute.aggregation.SampleBytesRefAggregatorFunctionTests
method: testSimpleWithCranky
issue: https://github.com/elastic/elasticsearch/issues/135157
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ public void testOptimizedTextHasBytes() throws Exception {
assertSame(XContentParser.Token.FIELD_NAME, parser.nextToken());
assertTrue(parser.nextToken().isValue());
Text text = (Text) parser.optimizedText();
assertTrue(text.hasBytes());
// TODO: uncomment after utf8 optimized parsing has been enabled again:
// assertTrue(text.hasBytes());
assertThat(text.string(), equalTo("foo"));
}
}
Expand Down