|
131 | 131 | public class SemanticTextFieldMapper extends FieldMapper implements InferenceFieldMapper { |
132 | 132 | private static final Logger logger = LogManager.getLogger(SemanticTextFieldMapper.class); |
133 | 133 | // TODO: rewrite the warning and error messages below, just placeholders for now |
134 | | - static final String WARNING_MESSAGE_8X = "The [dense_vector] field type created by `semantic_text` uses default index settings which may not be optimal. " + |
135 | | - "Consider creating a new index ...."; |
136 | | - private static final String ERROR_MESSAGE_UNSUPPORTED_SPARSE_VECTOR = "The [sparse_vector] field type created by `semantic_text` is not supported on indices created on versions 8.0 to 8.10." + |
137 | | - "Try using a `dense_vector` model or upgrade your index to 8.11 or later. ..."; |
| 134 | + static final String WARNING_MESSAGE_8X = |
| 135 | + "The [dense_vector] field type created by `semantic_text` uses default index settings which may not be optimal. " |
| 136 | + + "Consider creating a new index ...."; |
| 137 | + private static final String ERROR_MESSAGE_UNSUPPORTED_SPARSE_VECTOR = |
| 138 | + "The [sparse_vector] field type created by `semantic_text` is not supported on indices created on versions 8.0 to 8.10." |
| 139 | + + "Try using a `dense_vector` model or upgrade your index to 8.11 or later. ..."; |
138 | 140 | public static final NodeFeature SEMANTIC_TEXT_IN_OBJECT_FIELD_FIX = new NodeFeature("semantic_text.in_object_field_fix"); |
139 | 141 | public static final NodeFeature SEMANTIC_TEXT_SINGLE_FIELD_UPDATE_FIX = new NodeFeature("semantic_text.single_field_update_fix"); |
140 | 142 | public static final NodeFeature SEMANTIC_TEXT_DELETE_FIX = new NodeFeature("semantic_text.delete_fix"); |
@@ -1308,7 +1310,7 @@ private static void configureDenseVectorMapperBuilder( |
1308 | 1310 | MinimalServiceSettings modelSettings, |
1309 | 1311 | SemanticTextIndexOptions indexOptions |
1310 | 1312 | ) { |
1311 | | - if (indexVersionCreated.onOrAfter(IndexVersions.V_8_0_0)){ |
| 1313 | + if (indexVersionCreated.onOrAfter(IndexVersions.V_8_0_0)) { |
1312 | 1314 | if (indexVersionCreated.before(INDEXED_BY_DEFAULT_INDEX_VERSION)) { |
1313 | 1315 | deprecationLogger.warn(DeprecationCategory.MAPPINGS, "semantic_text", WARNING_MESSAGE_8X); |
1314 | 1316 | } |
|
0 commit comments