Skip to content

Commit bf0ed8e

Browse files
committed
Merge branch 'main' of github.com:elastic/elasticsearch into more-cohere-bits
2 parents e9339a6 + 3f021a1 commit bf0ed8e

File tree

937 files changed

+16585
-8721
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

937 files changed

+16585
-8721
lines changed

.buildkite/scripts/dra-update-staging.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ for BRANCH in "${BRANCHES[@]}"; do
3636
fi
3737

3838
if [[ "$SHOULD_TRIGGER" == "true" ]]; then
39+
if [[ "$BRANCH" == "9.0" ]]; then
40+
export VERSION_QUALIFIER="beta1"
41+
fi
3942
echo "Triggering DRA staging workflow for $BRANCH"
4043
cat << EOF | buildkite-agent pipeline upload
4144
steps:
@@ -46,6 +49,7 @@ steps:
4649
branch: "$BRANCH"
4750
env:
4851
DRA_WORKFLOW: staging
52+
VERSION_QUALIFIER: ${VERSION_QUALIFIER:-}
4953
EOF
5054
fi
5155
done

benchmarks/src/main/java/org/elasticsearch/benchmark/compute/operator/AggregatorBenchmark.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ private static Operator operator(DriverContext driverContext, String grouping, S
155155

156156
if (grouping.equals("none")) {
157157
return new AggregationOperator(
158-
List.of(supplier(op, dataType, filter, 0).aggregatorFactory(AggregatorMode.SINGLE).apply(driverContext)),
158+
List.of(supplier(op, dataType, filter).aggregatorFactory(AggregatorMode.SINGLE, List.of(0)).apply(driverContext)),
159159
driverContext
160160
);
161161
}
@@ -182,33 +182,33 @@ private static Operator operator(DriverContext driverContext, String grouping, S
182182
default -> throw new IllegalArgumentException("unsupported grouping [" + grouping + "]");
183183
};
184184
return new HashAggregationOperator(
185-
List.of(supplier(op, dataType, filter, groups.size()).groupingAggregatorFactory(AggregatorMode.SINGLE)),
185+
List.of(supplier(op, dataType, filter).groupingAggregatorFactory(AggregatorMode.SINGLE, List.of(groups.size()))),
186186
() -> BlockHash.build(groups, driverContext.blockFactory(), 16 * 1024, false),
187187
driverContext
188188
);
189189
}
190190

191-
private static AggregatorFunctionSupplier supplier(String op, String dataType, String filter, int dataChannel) {
191+
private static AggregatorFunctionSupplier supplier(String op, String dataType, String filter) {
192192
return filtered(switch (op) {
193-
case COUNT -> CountAggregatorFunction.supplier(List.of(dataChannel));
193+
case COUNT -> CountAggregatorFunction.supplier();
194194
case COUNT_DISTINCT -> switch (dataType) {
195-
case LONGS -> new CountDistinctLongAggregatorFunctionSupplier(List.of(dataChannel), 3000);
196-
case DOUBLES -> new CountDistinctDoubleAggregatorFunctionSupplier(List.of(dataChannel), 3000);
195+
case LONGS -> new CountDistinctLongAggregatorFunctionSupplier(3000);
196+
case DOUBLES -> new CountDistinctDoubleAggregatorFunctionSupplier(3000);
197197
default -> throw new IllegalArgumentException("unsupported data type [" + dataType + "]");
198198
};
199199
case MAX -> switch (dataType) {
200-
case LONGS -> new MaxLongAggregatorFunctionSupplier(List.of(dataChannel));
201-
case DOUBLES -> new MaxDoubleAggregatorFunctionSupplier(List.of(dataChannel));
200+
case LONGS -> new MaxLongAggregatorFunctionSupplier();
201+
case DOUBLES -> new MaxDoubleAggregatorFunctionSupplier();
202202
default -> throw new IllegalArgumentException("unsupported data type [" + dataType + "]");
203203
};
204204
case MIN -> switch (dataType) {
205-
case LONGS -> new MinLongAggregatorFunctionSupplier(List.of(dataChannel));
206-
case DOUBLES -> new MinDoubleAggregatorFunctionSupplier(List.of(dataChannel));
205+
case LONGS -> new MinLongAggregatorFunctionSupplier();
206+
case DOUBLES -> new MinDoubleAggregatorFunctionSupplier();
207207
default -> throw new IllegalArgumentException("unsupported data type [" + dataType + "]");
208208
};
209209
case SUM -> switch (dataType) {
210-
case LONGS -> new SumLongAggregatorFunctionSupplier(List.of(dataChannel));
211-
case DOUBLES -> new SumDoubleAggregatorFunctionSupplier(List.of(dataChannel));
210+
case LONGS -> new SumLongAggregatorFunctionSupplier();
211+
case DOUBLES -> new SumDoubleAggregatorFunctionSupplier();
212212
default -> throw new IllegalArgumentException("unsupported data type [" + dataType + "]");
213213
};
214214
default -> throw new IllegalArgumentException("unsupported op [" + op + "]");

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/ElasticsearchJavaBasePlugin.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ public class ElasticsearchJavaBasePlugin implements Plugin<Project> {
5858

5959
@Override
6060
public void apply(Project project) {
61-
project.getRootProject().getPlugins().apply(GlobalBuildInfoPlugin.class);
6261
// make sure the global build info plugin is applied to the root project
6362
project.getRootProject().getPluginManager().apply(GlobalBuildInfoPlugin.class);
6463
buildParams = project.getRootProject().getExtensions().getByType(BuildParameterExtension.class);

client/test/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ dependencies {
2828
api "org.hamcrest:hamcrest:${versions.hamcrest}"
2929

3030
// mockito
31-
api 'org.mockito:mockito-core:5.11.0'
32-
api 'org.mockito:mockito-subclass:5.11.0'
33-
api 'net.bytebuddy:byte-buddy:1.14.12'
31+
api 'org.mockito:mockito-core:5.15.2'
32+
api 'org.mockito:mockito-subclass:5.15.2'
33+
api 'net.bytebuddy:byte-buddy:1.15.11'
3434
api 'org.objenesis:objenesis:3.3'
3535
}
3636

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/AddFileKeyStoreCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ protected void executeCommand(Terminal terminal, OptionSet options, Environment
7474
keyStore.setFile(setting, Files.readAllBytes(file));
7575
}
7676

77-
keyStore.save(env.configFile(), getKeyStorePassword().getChars());
77+
keyStore.save(env.configDir(), getKeyStorePassword().getChars());
7878
}
7979

8080
@SuppressForbidden(reason = "file arg for cli")

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/AddStringKeyStoreCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ protected void executeCommand(Terminal terminal, OptionSet options, Environment
100100
}
101101
}
102102

103-
keyStore.save(env.configFile(), getKeyStorePassword().getChars());
103+
keyStore.save(env.configDir(), getKeyStorePassword().getChars());
104104
}
105105

106106
}

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/BaseKeyStoreCommand.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,14 @@ public BaseKeyStoreCommand(String description, boolean keyStoreMustExist) {
3939
@Override
4040
public final void execute(Terminal terminal, OptionSet options, Environment env, ProcessInfo processInfo) throws Exception {
4141
try {
42-
final Path configFile = env.configFile();
42+
final Path configFile = env.configDir();
4343
keyStore = KeyStoreWrapper.load(configFile);
4444
if (keyStore == null) {
4545
if (keyStoreMustExist) {
4646
throw new UserException(
4747
ExitCodes.DATA_ERROR,
4848
"Elasticsearch keystore not found at ["
49-
+ KeyStoreWrapper.keystorePath(env.configFile())
49+
+ KeyStoreWrapper.keystorePath(env.configDir())
5050
+ "]. Use 'create' command to create one."
5151
);
5252
} else if (options.has(forceOption) == false) {

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/ChangeKeyStorePasswordCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class ChangeKeyStorePasswordCommand extends BaseKeyStoreCommand {
3131
protected void executeCommand(Terminal terminal, OptionSet options, Environment env) throws Exception {
3232
try (SecureString newPassword = readPassword(terminal, true)) {
3333
final KeyStoreWrapper keyStore = getKeyStore();
34-
keyStore.save(env.configFile(), newPassword.getChars());
34+
keyStore.save(env.configDir(), newPassword.getChars());
3535
terminal.println("Elasticsearch keystore password changed successfully.");
3636
} catch (SecurityException e) {
3737
throw new UserException(ExitCodes.DATA_ERROR, e.getMessage());

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/CreateKeyStoreCommand.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,16 @@ class CreateKeyStoreCommand extends KeyStoreAwareCommand {
4040
@Override
4141
public void execute(Terminal terminal, OptionSet options, Environment env, ProcessInfo processInfo) throws Exception {
4242
try (SecureString password = options.has(passwordOption) ? readPassword(terminal, true) : new SecureString(new char[0])) {
43-
Path keystoreFile = KeyStoreWrapper.keystorePath(env.configFile());
43+
Path keystoreFile = KeyStoreWrapper.keystorePath(env.configDir());
4444
if (Files.exists(keystoreFile)) {
4545
if (terminal.promptYesNo("An elasticsearch keystore already exists. Overwrite?", false) == false) {
4646
terminal.println("Exiting without creating keystore.");
4747
return;
4848
}
4949
}
5050
KeyStoreWrapper keystore = KeyStoreWrapper.create();
51-
keystore.save(env.configFile(), password.getChars());
52-
terminal.println("Created elasticsearch keystore in " + KeyStoreWrapper.keystorePath(env.configFile()));
51+
keystore.save(env.configDir(), password.getChars());
52+
terminal.println("Created elasticsearch keystore in " + KeyStoreWrapper.keystorePath(env.configDir()));
5353
} catch (SecurityException e) {
5454
throw new UserException(ExitCodes.IO_ERROR, "Error creating the elasticsearch keystore.");
5555
}

distribution/tools/keystore-cli/src/main/java/org/elasticsearch/cli/keystore/HasPasswordKeyStoreCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public class HasPasswordKeyStoreCommand extends KeyStoreAwareCommand {
3232

3333
@Override
3434
public void execute(Terminal terminal, OptionSet options, Environment env, ProcessInfo processInfo) throws Exception {
35-
final Path configFile = env.configFile();
35+
final Path configFile = env.configDir();
3636
final KeyStoreWrapper keyStore = KeyStoreWrapper.load(configFile);
3737

3838
// We handle error printing here so we can respect the "--silent" flag

0 commit comments

Comments
 (0)