Skip to content
Open
Changes from 1 commit
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
764e68a
Add reindex entity
SammiChong Jul 17, 2025
8eae7a8
Add unit tests and metadata exception
SammiChong Jul 31, 2025
6c0017e
Add GET
SammiChong Aug 8, 2025
db33162
Add case_type
SammiChong Aug 8, 2025
c186109
Cleanup
SammiChong Aug 8, 2025
9e4eaa1
Add IT and clean up
SammiChong Aug 11, 2025
434db9c
Format error message
SammiChong Aug 11, 2025
0cb50c5
Revert testing
SammiChong Aug 11, 2025
46b8b3f
Cleanup
SammiChong Aug 11, 2025
8cecdf1
Merge branch 'master' into CME-239
SammiChong Aug 11, 2025
6d27919
Cleanup
SammiChong Aug 11, 2025
1b1835e
Add ActiveProfile to IT
SammiChong Aug 11, 2025
41708b4
Update ElasticsearchBaseTest.java
SammiChong Aug 11, 2025
b14b75b
Update ElasticsearchBaseTest.java
SammiChong Aug 12, 2025
36c9bb7
testing
SammiChong Aug 20, 2025
c9e1768
Add findByIndexName
SammiChong Aug 20, 2025
e3be5a6
Add ReindexPersistService
SammiChong Aug 20, 2025
aa1716a
Fix async transaction issue
SammiChong Aug 20, 2025
29a26fa
Clean up
SammiChong Aug 20, 2025
64d0e22
Replace overwrite with insert to DB
SammiChong Aug 22, 2025
2e585ef
Cleanup - rename and add tests
SammiChong Aug 22, 2025
d4aa313
Add reindex_response
SammiChong Aug 22, 2025
60fbf84
More cleanup
SammiChong Aug 29, 2025
3297c20
Merge branch 'master' into CME-239
SammiChong Aug 29, 2025
6ece42a
Add h2database
SammiChong Sep 2, 2025
3e773cd
Use testcontainers
SammiChong Sep 2, 2025
0d84d90
Add back ElasticsearchContainerInitializer
SammiChong Sep 2, 2025
1061029
Merge branch 'master' into CME-239
SammiChong Sep 3, 2025
6d68668
Return ReindexDTO instead of ReindexEntity
SammiChong Sep 3, 2025
c8bf2a9
Merge branch 'CME-239' of https://github.com/hmcts/ccd-definition-sto…
SammiChong Sep 3, 2025
b57eecb
Fix code smells
SammiChong Sep 3, 2025
d15f5d9
Revert !reindex
SammiChong Sep 3, 2025
3044cf3
Merge branch 'master' into CME-239
SammiChong Sep 8, 2025
a4aafd0
Remove null check
SammiChong Sep 8, 2025
453c3af
Address review comments
SammiChong Sep 10, 2025
5246cf8
Rename ReindexDTO
SammiChong Sep 11, 2025
aa5a82f
Merge branch 'master' into CME-239
SammiChong Sep 11, 2025
f2358dd
Merge branch 'master' into CME-239
SammiChong Sep 16, 2025
54b7265
Merge branch 'CME-238-patch' into CME-239
SammiChong Sep 30, 2025
4046b65
Cleanup, add tests
SammiChong Oct 1, 2025
956fa6b
Merge ReindexTaskService with ReindexService
SammiChong Oct 3, 2025
4ccb25b
Checkstyle
SammiChong Oct 3, 2025
35dbf88
Remove transactional
SammiChong Oct 6, 2025
3deab9b
Update ReindexServiceImpl.java
SammiChong Oct 6, 2025
20c2ffc
Merge branch 'CME-238-patch' into CME-239
SammiChong Oct 8, 2025
f7c1d3d
Fix tests, add reindexResponse
SammiChong Oct 8, 2025
576425f
Merge branch 'master' into CME-239
SammiChong Oct 8, 2025
283f295
Merge branch 'master' into CME-239
SammiChong Oct 8, 2025
82d0749
Merge branch 'CME-238-patch' into CME-239
kiran-yenigala-hmcts Oct 8, 2025
1a7d8bb
Clean import
SammiChong Oct 8, 2025
00e5241
Remove buildResponse, add logging
SammiChong Oct 28, 2025
73b2e5c
Remove reindex column
SammiChong Oct 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove transactional
  • Loading branch information
SammiChong committed Oct 6, 2025
commit 35dbf884ff6322af4cec0b878cd78ff8568045cd
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,7 @@ public String incrementIndexNumber(String indexName) {
int incremented = Integer.parseInt(numberStr) + 1;
String formattedNumber = StringUtils.leftPad(String.valueOf(incremented), numberStr.length(), '0');

String incrementedIndexName = prefix + formattedNumber;
return incrementedIndexName;
return prefix + formattedNumber;
}

@Override
Expand All @@ -168,7 +167,6 @@ public List<ReindexTask> getTasksByCaseType(String caseType) {
.toList();
}

@Transactional(propagation = Propagation.REQUIRES_NEW)
public ReindexEntity saveEntity(Boolean reindex, Boolean deleteOldIndex, CaseTypeEntity caseType,
String newIndexName) {
ReindexEntity entity = new ReindexEntity();
Expand All @@ -182,7 +180,6 @@ public ReindexEntity saveEntity(Boolean reindex, Boolean deleteOldIndex, CaseTyp
return reindexRepository.saveAndFlush(entity);
}

@Transactional(propagation = Propagation.REQUIRES_NEW)
public void updateEntity(String newIndexName, String response) {
ReindexEntity reindexEntity = reindexRepository.findByIndexName(newIndexName).orElse(null);
if (reindexEntity == null) {
Expand All @@ -197,7 +194,6 @@ public void updateEntity(String newIndexName, String response) {
reindexRepository.save(reindexEntity);
}

@Transactional(propagation = Propagation.REQUIRES_NEW)
public void updateEntity(String newIndexName, Exception ex) {
ReindexEntity reindexEntity = reindexRepository.findByIndexName(newIndexName).orElse(null);
if (reindexEntity == null) {
Expand Down