File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
klass-api/src/main/java/no/ssb/klass/api/services Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change 4646 - application : klass-mail
4747 openSearch :
4848 access : readwrite
49- instance : klass-search
49+ instance : klass-search-new
5050
5151 prometheus :
5252 enabled : true
Original file line number Diff line number Diff line change @@ -88,8 +88,12 @@ public void createIndexWithStemmingAnalyzer() {
8888 var indexOps = elasticsearchOperations .indexOps (getIndexCoordinates ());
8989
9090 if (indexOps .exists ()) {
91- log .info ("Index '{}' already exists — skipping creation." , elasticsearchIndex );
92- return ;
91+ log .info ("Index '{}' exists — deletes index." , elasticsearchIndex );
92+ boolean deleted = indexOps .delete ();
93+ if (!deleted ) {
94+ log .warn ("Failed to delete existing index '{}'. Aborting recreation." , elasticsearchIndex );
95+ return ;
96+ }
9397 }
9498
9599 Map <String , Object > settings =
You can’t perform that action at this time.
0 commit comments