Skip to content

Commit

Permalink
Add some more shutdown options
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmillar committed Sep 6, 2024
1 parent d74fd8a commit 1956e47
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1434,6 +1434,10 @@ public PagedTargetResult call() throws Exception {

private JdbcBulkArchiveDao archiveDao;

public void shutdown() {
executor.shutdown();
}

@Required
public void setActivityFactory(BulkActivityFactory activityFactory) {
this.activityFactory = activityFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,7 @@ public void shutdown() throws Exception {
requestJobs = null;
cancelledTargets = null;
requestStore.clearCache();
processorExecutorService.shutdown();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@
<property name="endpointStub" ref="ha-leader-stub"/>
</bean>

<bean id="admin-commands" class="org.dcache.services.bulk.BulkServiceCommands">
<bean id="admin-commands" class="org.dcache.services.bulk.BulkServiceCommands" destroy-method="shutdown">
<description>Holds the various commands for administrative purposes.</description>
<property name="service" ref="bulk-service"/>
<property name="activityFactory" ref="activity-factory"/>
Expand Down

0 comments on commit 1956e47

Please sign in to comment.