Change to CCSDK and ODL Carbon
[appc.git] / appc-adapters / appc-netconf-adapter / appc-netconf-adapter-bundle / src / main / java / org / openecomp / appc / adapter / netconf / AppcNetconfAdapterActivator.java
index e6dbda4..c64fe8c 100644 (file)
@@ -1,10 +1,11 @@
 /*-
  * ============LICENSE_START=======================================================
- * openECOMP : APP-C
+ * ONAP : APPC
  * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights
- *                                             reserved.
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
  * ================================================================================
+ * Copyright (C) 2017 Amdocs
+ * =============================================================================
  * 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
  * 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.
+ * 
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
  * ============LICENSE_END=========================================================
  */
 
 package org.openecomp.appc.adapter.netconf;
 
 import org.openecomp.appc.adapter.netconf.internal.NetconfDataAccessServiceImpl;
-import org.openecomp.sdnc.sli.resource.dblib.DbLibService;
+import org.onap.ccsdk.sli.core.dblib.DbLibService;
 import org.openecomp.appc.i18n.Msg;
 import com.att.eelf.configuration.EELFLogger;
 import com.att.eelf.configuration.EELFManager;
@@ -69,7 +72,6 @@ public class AppcNetconfAdapterActivator implements BundleActivator {
      */
     @Override
     public void start(BundleContext context) throws Exception {
-
         if (registration == null) {
             clientFactory = new NetconfClientFactory();
             factoryRegistration = context.registerService(NetconfClientFactory.class, clientFactory, null);
@@ -78,7 +80,11 @@ public class AppcNetconfAdapterActivator implements BundleActivator {
             //set dblib service
             DbLibService dblibSvc = null;
             ServiceReference sref = context.getServiceReference(DbLibService.class.getName());
+            try{
             dblibSvc  = (DbLibService)context.getService(sref);
+            }catch(Exception e){
+               logger.error(e.getMessage());
+            }
             DAService.setDbLibService(dblibSvc);
             ///////////////////////////////////
             factoryRegistration = context.registerService(NetconfDataAccessService.class, DAService, null);