Update oauth-provider to use new OSGi APIs
[ccsdk/features.git] / sdnr / wt / oauth-provider / provider-osgi / src / main / resources / org / opendaylight / blueprint / impl-blueprint.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ~ ============LICENSE_START=======================================================
4   ~ ONAP : ccsdk features
5   ~ ================================================================================
6   ~ Copyright (C) 2019 highstreet technologies GmbH Intellectual Property.
7   ~ All rights reserved.
8   ~ ================================================================================
9   ~ Update Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
10   ~ ================================================================================
11   ~ Licensed under the Apache License, Version 2.0 (the "License");
12   ~ you may not use this file except in compliance with the License.
13   ~ You may obtain a copy of the License at
14   ~
15   ~     http://www.apache.org/licenses/LICENSE-2.0
16   ~
17   ~ Unless required by applicable law or agreed to in writing, software
18   ~ distributed under the License is distributed on an "AS IS" BASIS,
19   ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20   ~ See the License for the specific language governing permissions and
21   ~ limitations under the License.
22   ~ ============LICENSE_END=======================================================
23   ~
24   -->
25
26 <blueprint xmlns:odl="http://opendaylight.org/xmlns/blueprint/v1.0.0"
27            xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0" odl:use-default-for-reference-types="true">
28
29     <reference id="odlAuthenticator" interface="org.jolokia.osgi.security.Authenticator" />
30
31     <reference id="odlIdentityService" interface="org.opendaylight.aaa.api.IdMService" />
32
33     <reference id="dataBroker" interface="org.opendaylight.mdsal.binding.api.DataBroker" />
34
35     <bean id="provider" class="org.onap.ccsdk.features.sdnr.wt.oauthprovider.Helper" init-method="init" destroy-method="close">
36         <property ref="odlAuthenticator" name="odlAuthenticator" />
37         <property ref="odlIdentityService" name="odlIdentityService" />
38         <property ref="shiroConfiguration" name="shiroConfiguration" />
39         <property ref="dataBroker" name="dataBroker" />
40     </bean>
41
42     <reference id="onBindService" availability="mandatory" activation="eager" interface="org.osgi.service.http.HttpService">
43         <reference-listener ref="provider" bind-method="onBindService" unbind-method="onUnbindService"/>
44     </reference>
45
46     <odl:clustered-app-config
47           binding-class="org.opendaylight.yang.gen.v1.urn.opendaylight.aaa.app.config.rev170619.ShiroConfiguration"
48           id="shiroConfiguration" default-config-file-name="aaa-app-config.xml" />
49           
50     <bean id="authServlet" class="org.onap.ccsdk.features.sdnr.wt.oauthprovider.http.AuthHttpServlet">
51           <property ref="odlAuthenticator" name="odlAuthenticator" />
52           <property ref="odlIdentityService" name="odlIdentityService" />
53           <property ref="shiroConfiguration" name="shiroConfiguration" />
54           <property ref="dataBroker" name="dataBroker" />
55     </bean>
56
57 </blueprint>