Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Purge task descriptions cache #587

Merged
merged 2 commits into from
May 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ All notable changes to this project will be documented in this file.
- Add check for ContributeAndFinalize in `ReplicatesService`. (#576 #582)
- Add `running2Finalized2Completed` in `TaskUpdateManager`. (#577 #578)
- Disable `contributeAndFinalize` with CallBack. (#579 #581)
- Add purge cached task descriptions ability. (#587)
### Bug Fixes
- Prevent race condition on replicate update. (#568)
### Quality
Expand All @@ -20,7 +21,7 @@ All notable changes to this project will be documented in this file.
- Rearrange checks order to avoid call to database. (#585)
### Dependency Upgrades
- Upgrade to `iexec-common` 8.1.0-NEXT-SNAPSHOT. (#571 #575 #586)
- Add new `iexec-commons-poco` 2.0.0 dependency. (#571 #574 #586)
- Add new `iexec-commons-poco` 2.0.1 dependency. (#571 #574 #586 #587)

## [[8.0.1]](https://github.com/iExecBlockchainComputing/iexec-core/releases/tag/v8.0.1) 2023-03-20

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
version=8.0.1
iexecCommonVersion=8.1.0-NEXT-SNAPSHOT
iexecCommonsPocoVersion=2.0.0
iexecCommonsPocoVersion=2.0.1
iexecBlockchainAdapterVersion=8.0.1-NEXT-SNAPSHOT
iexecResultVersion=8.0.0-NEXT-SNAPSHOT
iexecSmsVersion=8.0.0-NEXT-SNAPSHOT
Expand Down
12 changes: 11 additions & 1 deletion src/main/java/com/iexec/core/chain/IexecHubService.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

package com.iexec.core.chain;

import com.iexec.common.lifecycle.purge.Purgeable;
import com.iexec.commons.poco.chain.*;
import com.iexec.commons.poco.contract.generated.IexecHubContract;
import io.reactivex.Flowable;
Expand All @@ -37,7 +38,7 @@

@Slf4j
@Service
public class IexecHubService extends IexecHubAbstractService {
public class IexecHubService extends IexecHubAbstractService implements Purgeable {

private final ThreadPoolExecutor executor;
private final CredentialsService credentialsService;
Expand Down Expand Up @@ -247,4 +248,13 @@ private ChainReceipt buildChainReceipt(TransactionReceipt receipt) {
.build();
}

@Override
public boolean purgeTask(String chainTaskId) {
return super.purgeTask(chainTaskId);
}

@Override
public void purgeAllTasksData() {
super.purgeAllTasksData();
}
}