You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/elasticsearch/ElasticsearchInternalService.java
+14-9Lines changed: 14 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -150,6 +150,7 @@ public void parseRequestConfig(
150
150
config,
151
151
preferredModelVariant,
152
152
serviceSettingsMap,
153
+
true,
153
154
chunkingSettings,
154
155
modelListener
155
156
)
@@ -181,6 +182,7 @@ public void parseRequestConfig(
181
182
config,
182
183
preferredModelVariant,
183
184
serviceSettingsMap,
185
+
OLD_ELSER_SERVICE_NAME.equals(serviceName),
184
186
chunkingSettings,
185
187
modelListener
186
188
)
@@ -340,6 +342,7 @@ private void elserCase(
340
342
Map<String, Object> config,
341
343
PreferredModelVariantpreferredModelVariant,
342
344
Map<String, Object> serviceSettingsMap,
345
+
booleanisElserService,
343
346
ChunkingSettingschunkingSettings,
344
347
ActionListener<Model> modelListener
345
348
) {
@@ -370,15 +373,17 @@ private void elserCase(
370
373
}
371
374
}
372
375
373
-
DEPRECATION_LOGGER.warn(
374
-
DeprecationCategory.API,
375
-
"inference_api_elser_service",
376
-
"The [{}] service is deprecated and will be removed in a future release. Use the [{}] service instead, with"
377
-
+ " [model_id] set to [{}] in the [service_settings]",
378
-
OLD_ELSER_SERVICE_NAME,
379
-
ElasticsearchInternalService.NAME,
380
-
defaultModelId
381
-
);
376
+
if (isElserService) {
377
+
DEPRECATION_LOGGER.warn(
378
+
DeprecationCategory.API,
379
+
"inference_api_elser_service",
380
+
"The [{}] service is deprecated and will be removed in a future release. Use the [{}] service instead, with"
381
+
+ " [model_id] set to [{}] in the [service_settings]",
0 commit comments