1 <?xml version="1.0" encoding="utf-8"?>
3 ============LICENSE_START=======================================================
5 ================================================================================
6 Copyright (C) 2017 AT&T Intellectual Property. All rights
8 ================================================================================
9 Licensed under the Apache License, Version 2.0 (the "License");
10 you may not use this file except in compliance with the License.
11 You may obtain a copy of the License at
13 http://www.apache.org/licenses/LICENSE-2.0
15 Unless required by applicable law or agreed to in writing, software
16 distributed under the License is distributed on an "AS IS" BASIS,
17 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 See the License for the specific language governing permissions and
19 limitations under the License.
20 ============LICENSE_END=========================================================
23 <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
24 xmlns:odl="http://opendaylight.org/xmlns/blueprint/v1.0.0"
25 odl:use-default-for-reference-types="true">
29 <bean id="rm.dataSource" class="org.onap.ccsdk.sli.adaptors.util.db.DataSourceWrap">
30 <property name="dataSource" ref="dblib.dataSource" />
33 <bean id="lock.dataSource" class="org.onap.ccsdk.sli.adaptors.util.db.CachedDataSourceWrap">
34 <property name="dataSource" ref="rm.dataSource" />
37 <bean id="rm.jdbcTemplate" class="org.springframework.jdbc.core.JdbcTemplate">
38 <property name="dataSource" ref="rm.dataSource" />
41 <bean id="lock.jdbcTemplate" class="org.springframework.jdbc.core.JdbcTemplate">
42 <property name="dataSource" ref="lock.dataSource" />
45 <!-- Resource Lock Configuration -->
47 <bean id="resourceLockDao" class="org.onap.ccsdk.sli.adaptors.lock.dao.ResourceLockDaoImpl">
48 <property name="jdbcTemplate" ref="lock.jdbcTemplate" />
51 <bean id="lockHelper" class="org.onap.ccsdk.sli.adaptors.lock.comp.LockHelperImpl">
52 <property name="resourceLockDao" ref="resourceLockDao" />
53 <property name="retryCount" value="10" />
54 <property name="lockWait" value="5" /> <!-- Seconds -->
57 <!-- RM Configuration -->
59 <bean id="resourceJdbcDao" class="org.onap.ccsdk.sli.adaptors.rm.dao.jdbc.ResourceJdbcDaoImpl">
60 <property name="jdbcTemplate" ref="rm.jdbcTemplate" />
63 <bean id="allocationItemJdbcDao" class="org.onap.ccsdk.sli.adaptors.rm.dao.jdbc.AllocationItemJdbcDaoImpl">
64 <property name="jdbcTemplate" ref="rm.jdbcTemplate" />
67 <bean id="resourceLoadJdbcDao" class="org.onap.ccsdk.sli.adaptors.rm.dao.jdbc.ResourceLoadJdbcDaoImpl">
68 <property name="jdbcTemplate" ref="rm.jdbcTemplate" />
71 <bean id="resourceDao" class="org.onap.ccsdk.sli.adaptors.rm.dao.jdbc.ResourceDaoImpl">
72 <property name="resourceJdbcDao" ref="resourceJdbcDao" />
73 <property name="allocationItemJdbcDao" ref="allocationItemJdbcDao" />
74 <property name="resourceLoadJdbcDao" ref="resourceLoadJdbcDao" />
77 <bean id="resourceManager" class="org.onap.ccsdk.sli.adaptors.rm.comp.ResourceManagerImpl">
78 <property name="lockHelper" ref="lockHelper" />
79 <property name="resourceDao" ref="resourceDao" />
80 <property name="lockTimeout" value="600" /> <!-- Seconds -->
83 <!-- Rule DAO Configuration -->
85 <bean id="resourceRuleDao" class="org.onap.ccsdk.sli.adaptors.ra.rule.dao.ResourceRuleDaoImpl">
86 <property name="jdbcTemplate" ref="rm.jdbcTemplate" />
89 <bean id="rangeRuleDao" class="org.onap.ccsdk.sli.adaptors.ra.rule.dao.RangeRuleDaoImpl">
90 <property name="jdbcTemplate" ref="rm.jdbcTemplate" />
93 <!-- ResourceAllocator Configuration -->
95 <bean id="resourceAllocator" class="org.onap.ccsdk.sli.adaptors.ra.ResourceAllocator">
96 <property name="resourceManager" ref="resourceManager" />
97 <property name="endPointAllocator" ref="endPointAllocator" />
98 <property name="speedUtil" ref="speedUtil" />
101 <bean id="resourceLockNode" class="org.onap.ccsdk.sli.adaptors.ra.ResourceLockNode">
102 <property name="lockHelper" ref="lockHelper" />
105 <bean id="speedUtil" class="org.onap.ccsdk.sli.adaptors.util.speed.SpeedUtil" />
107 <!-- EndPointAllocator Configuration -->
109 <bean id="endPointAllocator" class="org.onap.ccsdk.sli.adaptors.ra.comp.EndPointAllocatorImpl">
110 <property name="resourceManager" ref="resourceManager" />
111 <property name="allocationRuleMap">
113 <entry key="DEFAULT">
115 <ref component-id="dbAllocationRule" />
122 <!-- Resource Allocation Rule Configuration -->
124 <bean id="dbAllocationRule" class="org.onap.ccsdk.sli.adaptors.ra.alloc.DbAllocationRule">
125 <property name="resourceRuleDao" ref="resourceRuleDao" />
126 <property name="rangeRuleDao" ref="rangeRuleDao" />