The NoneStreamEsDAO implementation doesn't use real index name to insert. (#4796)

This commit is contained in:
吴晟 Wu Sheng 2020-05-16 22:54:28 +08:00 committed by GitHub
parent 544d419fc0
commit cffcc58f8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ public class NoneStreamEsDAO extends EsDAO implements INoneStreamDAO {
@Override
public void insert(Model model, NoneStream noneStream) throws IOException {
XContentBuilder builder = map2builder(storageBuilder.data2Map(noneStream));
String modelName = model.getName();
String modelName = TimeSeriesUtils.writeIndexName(model, noneStream.getTimeBucket());
getClient().forceInsert(modelName, noneStream.id(), builder);
}
}