Hi im using ELK stack V 8.13.3
i having an issue in my index:
i dont know why but I pushed 8 vectors and the mapper set them as dense_vector(no activity from my side to set this type was done)
now this 8 vectors can change the size and I got mapper error.
my goal is to change them into float.
i tried to create new index with new float mapping to problematic fields and reindex the data to new index excluding the dense vector(currently the data in dense_vector can be descarted)
but I got always 2 parameters with the same name but different types in new index:
1.float
2.dense vector
my devtoolcode:
PUT /rf_equipment_data_simple_new_2025
{
"mappings": {
"properties": {
"ES_FLATNESS_AVERAGE_RES": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"SEMASK_AVERAGE_SPECTRUM_OFR_TRACE": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"SEMASK_MAX_SPECTRUM_TRACE": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"TRACE_SE_MASK_AVG_RBW_100": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"TRACE_SE_MASK_AVG_RBW_1000": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"SEMASK_AVERAGE_SPECTRUM_TRACE": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"TRACE_SE_MASK_MAX_RBW_100": {
"type": "nested",
"properties": { "values": { "type": "float" } }
},
"TRACE_SE_MASK_MAX_RBW_1000": {
"type": "nested",
"properties": { "values": { "type": "float" } }
}
}
}
}
MAPPING SHOWS ONLY FLOATS:
GET rf_equipment_data_simple_new_2025/_mapping
REINDEX EXCLUDE DENSE_VECTOR
POST _reindex?wait_for_completion=false
{
"source": {
"index": ["rf_equipment_data-000001", "rf_equipment_data-000002", "rf_equipment_data-000003"],
"size": 1000
},
"dest": {
"index": "rf_equipment_data_simple_new_2025"
},
"script": {
"source": """
// Remove all fields that were previously dense_vector
def keysToRemove = [];
for (entry in ctx._source.entrySet()) {
// Check if the field was a dense_vector (by checking for an object with a "dims" key)
if (entry.getValue() instanceof Map && entry.getValue().containsKey("dims")) {
keysToRemove.add(entry.getKey());
}
}
// Remove all identified dense_vector fields
for (key in keysToRemove) {
ctx._source.remove(key);
}
// Add a success message to confirm reindexing
ctx._source["reindex_status"] = "SUCCESS";
"""
}
}
any help please?
in addition I want my current ILM will be applied to new index, is it possible?