Added new file for task config
parent
059c2545c9
commit
12cb672c6d
|
@ -0,0 +1,35 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright 2013 The MITRE Corporation
|
||||
and the MIT Kerberos and Internet Trust Consortium
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
-->
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:task="http://www.springframework.org/schema/task"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-3.1.xsd
|
||||
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
|
||||
|
||||
<!-- Configuration for scheduled tasks -->
|
||||
<task:scheduler id="taskScheduler" pool-size="10" />
|
||||
<task:executor id="taskExecutor" pool-size="5" />
|
||||
<task:annotation-driven scheduler="taskScheduler" executor="taskExecutor" />
|
||||
|
||||
<!-- Schedule the token service and approved site service to clear out expired tokens and sites every 5 minutes -->
|
||||
<task:scheduled-tasks scheduler="taskScheduler">
|
||||
<task:scheduled ref="defaultOAuth2ProviderTokenService" method="clearExpiredTokens" fixed-rate="300000"/>
|
||||
<task:scheduled ref="defaultApprovedSiteService" method="clearExpiredSites" fixed-rate="300000"/>
|
||||
</task:scheduled-tasks>
|
||||
|
||||
</beans>
|
Loading…
Reference in New Issue