Clean up a few instances of "MetaData"

We recently cleaned up the use of the word "metadata" across the
codebase. A few additional uses have trickled in, likely from
in-progress work. This commit cleans up these last few instances.

Relates #54519
This commit is contained in:
Jason Tedor 2020-04-04 10:45:34 -04:00
parent 2a94672c32
commit 05c5529b2d
No known key found for this signature in database
GPG Key ID: FA89F05560F16BC5
9 changed files with 40 additions and 40 deletions

View File

@ -124,9 +124,9 @@ public class CreateDataStreamAction extends ActionType<AcknowledgedResponse> {
@Inject
public TransportAction(TransportService transportService, ClusterService clusterService, ThreadPool threadPool,
ActionFilters actionFilters, IndexNameExpressionResolver indexNameExpressionResolver,
MetadataCreateIndexService metaDataCreateIndexService) {
MetadataCreateIndexService metadataCreateIndexService) {
super(NAME, transportService, clusterService, threadPool, actionFilters, Request::new, indexNameExpressionResolver);
this.metadataCreateIndexService = metaDataCreateIndexService;
this.metadataCreateIndexService = metadataCreateIndexService;
}
@Override

View File

@ -135,8 +135,8 @@ public abstract class AbstractPercentilesAggregationBuilder<T extends AbstractPe
}
AbstractPercentilesAggregationBuilder(AbstractPercentilesAggregationBuilder<T> clone,
AggregatorFactories.Builder factoriesBuilder, Map<String, Object> metaData) {
super(clone, factoriesBuilder, metaData);
AggregatorFactories.Builder factoriesBuilder, Map<String, Object> metadata) {
super(clone, factoriesBuilder, metadata);
this.percentilesConfig = clone.percentilesConfig;
this.keyed = clone.keyed;
this.values = clone.values;

View File

@ -65,13 +65,13 @@ public class PercentileRanksAggregationBuilder extends AbstractPercentilesAggreg
private PercentileRanksAggregationBuilder(PercentileRanksAggregationBuilder clone,
Builder factoriesBuilder,
Map<String, Object> metaData) {
super(clone, factoriesBuilder, metaData);
Map<String, Object> metadata) {
super(clone, factoriesBuilder, metadata);
}
@Override
protected AggregationBuilder shallowCopy(Builder factoriesBuilder, Map<String, Object> metaData) {
return new PercentileRanksAggregationBuilder(this, factoriesBuilder, metaData);
protected AggregationBuilder shallowCopy(Builder factoriesBuilder, Map<String, Object> metadata) {
return new PercentileRanksAggregationBuilder(this, factoriesBuilder, metadata);
}
/**

View File

@ -47,8 +47,8 @@ class PercentileRanksAggregatorFactory extends ValuesSourceAggregatorFactory<Val
QueryShardContext queryShardContext,
AggregatorFactory parent,
AggregatorFactories.Builder subFactoriesBuilder,
Map<String, Object> metaData) throws IOException {
super(name, config, queryShardContext, parent, subFactoriesBuilder, metaData);
Map<String, Object> metadata) throws IOException {
super(name, config, queryShardContext, parent, subFactoriesBuilder, metadata);
this.percents = percents;
this.percentilesConfig = percentilesConfig;
this.keyed = keyed;
@ -58,10 +58,10 @@ class PercentileRanksAggregatorFactory extends ValuesSourceAggregatorFactory<Val
protected Aggregator createUnmapped(SearchContext searchContext,
Aggregator parent,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return percentilesConfig.createPercentileRanksAggregator(name, null, searchContext, parent, percents, keyed,
config.format(), pipelineAggregators, metaData);
config.format(), pipelineAggregators, metadata);
}
@Override
@ -70,8 +70,8 @@ class PercentileRanksAggregatorFactory extends ValuesSourceAggregatorFactory<Val
Aggregator parent,
boolean collectsFromSingleBucket,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return percentilesConfig.createPercentileRanksAggregator(name, valuesSource, searchContext, parent, percents, keyed,
config.format(), pipelineAggregators, metaData);
config.format(), pipelineAggregators, metadata);
}
}

View File

@ -74,13 +74,13 @@ public class PercentilesAggregationBuilder extends AbstractPercentilesAggregatio
}
protected PercentilesAggregationBuilder(PercentilesAggregationBuilder clone,
Builder factoriesBuilder, Map<String, Object> metaData) {
super(clone, factoriesBuilder, metaData);
Builder factoriesBuilder, Map<String, Object> metadata) {
super(clone, factoriesBuilder, metadata);
}
@Override
protected AggregationBuilder shallowCopy(Builder factoriesBuilder, Map<String, Object> metaData) {
return new PercentilesAggregationBuilder(this, factoriesBuilder, metaData);
protected AggregationBuilder shallowCopy(Builder factoriesBuilder, Map<String, Object> metadata) {
return new PercentilesAggregationBuilder(this, factoriesBuilder, metadata);
}
/**

View File

@ -46,8 +46,8 @@ class PercentilesAggregatorFactory extends ValuesSourceAggregatorFactory<ValuesS
PercentilesAggregatorFactory(String name, ValuesSourceConfig<ValuesSource> config, double[] percents,
PercentilesConfig percentilesConfig, boolean keyed, QueryShardContext queryShardContext,
AggregatorFactory parent, AggregatorFactories.Builder subFactoriesBuilder,
Map<String, Object> metaData) throws IOException {
super(name, config, queryShardContext, parent, subFactoriesBuilder, metaData);
Map<String, Object> metadata) throws IOException {
super(name, config, queryShardContext, parent, subFactoriesBuilder, metadata);
this.percents = percents;
this.percentilesConfig = percentilesConfig;
this.keyed = keyed;
@ -57,10 +57,10 @@ class PercentilesAggregatorFactory extends ValuesSourceAggregatorFactory<ValuesS
protected Aggregator createUnmapped(SearchContext searchContext,
Aggregator parent,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return percentilesConfig.createPercentilesAggregator(name, null, searchContext, parent, percents, keyed,
config.format(), pipelineAggregators, metaData);
config.format(), pipelineAggregators, metadata);
}
@Override
@ -69,9 +69,9 @@ class PercentilesAggregatorFactory extends ValuesSourceAggregatorFactory<ValuesS
Aggregator parent,
boolean collectsFromSingleBucket,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return percentilesConfig.createPercentilesAggregator(name, valuesSource, searchContext, parent, percents, keyed,
config.format(), pipelineAggregators, metaData);
config.format(), pipelineAggregators, metadata);
}
}

View File

@ -72,12 +72,12 @@ public abstract class PercentilesConfig implements ToXContent, Writeable {
abstract Aggregator createPercentilesAggregator(String name, ValuesSource valuesSource, SearchContext context, Aggregator parent,
double[] values, boolean keyed, DocValueFormat formatter,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException;
Map<String, Object> metadata) throws IOException;
abstract Aggregator createPercentileRanksAggregator(String name, ValuesSource valuesSource, SearchContext context,
Aggregator parent, double[] values, boolean keyed,
DocValueFormat formatter, List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException;
Map<String, Object> metadata) throws IOException;
@Override
public void writeTo(StreamOutput out) throws IOException {
@ -131,18 +131,18 @@ public abstract class PercentilesConfig implements ToXContent, Writeable {
Aggregator createPercentilesAggregator(String name, ValuesSource valuesSource, SearchContext context, Aggregator parent,
double[] values, boolean keyed, DocValueFormat formatter,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return new TDigestPercentilesAggregator(name, valuesSource, context, parent, values, compression, keyed, formatter,
pipelineAggregators, metaData);
pipelineAggregators, metadata);
}
@Override
Aggregator createPercentileRanksAggregator(String name, ValuesSource valuesSource, SearchContext context, Aggregator parent,
double[] values, boolean keyed, DocValueFormat formatter,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return new TDigestPercentileRanksAggregator(name, valuesSource, context, parent, values, compression, keyed,
formatter, pipelineAggregators, metaData);
formatter, pipelineAggregators, metadata);
}
@Override
@ -207,18 +207,18 @@ public abstract class PercentilesConfig implements ToXContent, Writeable {
Aggregator createPercentilesAggregator(String name, ValuesSource valuesSource, SearchContext context, Aggregator parent,
double[] values, boolean keyed, DocValueFormat formatter,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return new HDRPercentilesAggregator(name, valuesSource, context, parent, values, numberOfSignificantValueDigits, keyed,
formatter, pipelineAggregators, metaData);
formatter, pipelineAggregators, metadata);
}
@Override
Aggregator createPercentileRanksAggregator(String name, ValuesSource valuesSource, SearchContext context, Aggregator parent,
double[] values, boolean keyed, DocValueFormat formatter,
List<PipelineAggregator> pipelineAggregators,
Map<String, Object> metaData) throws IOException {
Map<String, Object> metadata) throws IOException {
return new HDRPercentileRanksAggregator(name, valuesSource, context, parent, values, numberOfSignificantValueDigits, keyed,
formatter, pipelineAggregators, metaData);
formatter, pipelineAggregators, metadata);
}
@Override

View File

@ -46,17 +46,17 @@ import static org.hamcrest.Matchers.equalTo;
public class InternalPercentilesBucketTests extends InternalAggregationTestCase<InternalPercentilesBucket> {
@Override
protected InternalPercentilesBucket createTestInstance(String name, Map<String, Object> metaData) {
return createTestInstance(name, metaData, randomPercents(), true);
protected InternalPercentilesBucket createTestInstance(String name, Map<String, Object> metadata) {
return createTestInstance(name, metadata, randomPercents(), true);
}
private static InternalPercentilesBucket createTestInstance(String name, Map<String, Object> metaData,
private static InternalPercentilesBucket createTestInstance(String name, Map<String, Object> metadata,
double[] percents, boolean keyed) {
final double[] percentiles = new double[percents.length];
for (int i = 0; i < percents.length; ++i) {
percentiles[i] = frequently() ? randomDouble() : Double.NaN;
}
return createTestInstance(name, metaData, percents, percentiles, keyed);
return createTestInstance(name, metadata, percents, percentiles, keyed);
}
private static InternalPercentilesBucket createTestInstance(String name, Map<String, Object> metadata,

View File

@ -353,8 +353,8 @@ public abstract class InternalAggregationTestCase<T extends InternalAggregation>
/** Return an instance on an unmapped field. */
protected final T createUnmappedInstance(String name) {
Map<String, Object> metadata = new HashMap<>();
int metaDataCount = randomBoolean() ? 0 : between(1, 10);
while (metadata.size() < metaDataCount) {
int metadataCount = randomBoolean() ? 0 : between(1, 10);
while (metadata.size() < metadataCount) {
metadata.put(randomAlphaOfLength(5), randomAlphaOfLength(5));
}
return createUnmappedInstance(name, metadata);