diff --git a/appc-common/src/main/java/org/openecomp/appc/configuration/ConfigurationFactory.java b/appc-common/src/main/java/org/openecomp/appc/configuration/ConfigurationFactory.java
index a2dd557..fa8b5ee 100644
--- a/appc-common/src/main/java/org/openecomp/appc/configuration/ConfigurationFactory.java
+++ b/appc-common/src/main/java/org/openecomp/appc/configuration/ConfigurationFactory.java
@@ -116,14 +116,14 @@
     /**
      * The default properties resource to be loaded
      */
-    private static final String DEFAULT_PROPERTIES = "/opt/openecomp/appc/data/properties/appc.properties";
+    private static final String DEFAULT_PROPERTIES = "org/openecomp/appc/default.properties";
 
     /**
      * This collection allows for special configurations to be created and maintained, organized by some identification
      * (such as an object reference to the StackBuilder to which they apply), and then obtained from the configuration
      * factory when needed.
      */
-    private static HashMap<Object, Configuration> localConfigs = new HashMap<Object, Configuration>();
+    private static HashMap<Object, Configuration> localConfigs = new HashMap<>();
 
     /**
      * The reentrant shared lock used to serialize access to the properties.
@@ -355,7 +355,9 @@
                     logger.error(EELFResourceManager.format(e));
                 } finally {
                     try {
-                        stream.close();
+                        if (stream != null) {
+                            stream.close();
+                        }
                     } catch (IOException e) {
                         // not much we can do since logger may not be configured
                         // yet
diff --git a/appc-common/src/main/java/org/openecomp/appc/i18n/Msg.java b/appc-common/src/main/java/org/openecomp/appc/i18n/Msg.java
index 7306b4c..5f0aa32 100644
--- a/appc-common/src/main/java/org/openecomp/appc/i18n/Msg.java
+++ b/appc-common/src/main/java/org/openecomp/appc/i18n/Msg.java
@@ -756,28 +756,60 @@
     OAM_OPERATION_EXCEPTION,
 
     /**
-     *   Application {0} is stopping... Waiting for  {1} LCM request to complete
+     *   Application {0} is {1}
      */
-    OAM_OPERATION_STOPPING,
+    OAM_OPERATION_ENTERING_MAINTENANCE_MODE,
 
     /**
-     * Application {0} is stopped
+     * Application {0} is in {1}
      */
-    OAM_OPERATION_STOPPED,
-
+    OAM_OPERATION_MAINTENANCE_MODE,
 
     /**
-     * Application {0} is started
+     * Application {0} is {1}
      */
     OAM_OPERATION_STARTING,
 
     /**
-     * Application {0} is started
+     * Application {0} is {1}
      */
     OAM_OPERATION_STARTED,
 
-    ;
     /**
+     * Application {0} is {1}
+     */
+    OAM_OPERATION_STOPPING,
+
+    /**
+     * Application {0} is {1}
+     */
+    OAM_OPERATION_STOPPED,
+    /**
+     * A {1} API is not allowed when {0} is in the {2} state
+     */
+    INVALID_STATE_TRANSITION,
+
+    /**
+     * Application {0} was unable to find the Request Handler service
+     */
+    REQUEST_HANDLER_UNAVAILABLE,
+
+    /**
+     * Application {0} is {1}
+     */
+    OAM_OPERATION_RESTARTING,
+
+    /**
+     * Application {0} is {1} for restart
+     */
+    OAM_OPERATION_RESTARTED,
+
+    /**
+     * {0}
+     */
+    OAM_OPERATION_INVALID_INPUT
+    ;
+    /*
      * Static initializer to ensure the resource bundles for this class are loaded...
      */
     static {
diff --git a/appc-common/src/main/resources/org/openecomp/appc/i18n/MessageResources.properties b/appc-common/src/main/resources/org/openecomp/appc/i18n/MessageResources.properties
index 28971c7..86d9b55 100644
--- a/appc-common/src/main/resources/org/openecomp/appc/i18n/MessageResources.properties
+++ b/appc-common/src/main/resources/org/openecomp/appc/i18n/MessageResources.properties
@@ -956,24 +956,58 @@
     state of the thread at the time of the exception.|\
   Correct the cause of the exception and rerun.
 
-OAM_OPERATION_STOPPING=APPC0154W|\
-  Application {0} is stopping... |\
+OAM_OPERATION_ENTERING_MAINTENANCE_MODE=APPC0154W|\
+  Application {0} is {1}|\
   No recovery required|\
   The APPC will no longer accept new LCM requests. Previously accepted LCM requests will be allowed to complete.
 
-OAM_OPERATION_STOPPED=APPC0155W|\
-  Application {0} is stopped|\
+OAM_OPERATION_MAINTENANCE_MODE=APPC0155W|\
+  Application {0} is in {1}|\
   No recovery required|\
-  The APPC is not accepting new LCM requests and all previously accepted LCM requests have completed.    
+  The APPC is not accepting new LCM requests and all previously accepted LCM requests have completed.
 
 OAM_OPERATION_STARTING=APPC0156I|\
-  Application {0} is starting...|\
+  Application {0} is {1}|\
   No recovery required|\
-  The APPC has initiated its startup procedure. Its internal components are coming online.  Once completed it will start accepting LCM requests.   \
-  
+  The APPC has initiated its startup procedure. Its internal components are coming online.  Once completed it will start accepting LCM requests.
+
 OAM_OPERATION_STARTED=APPC0157I|\
-  Application {0} is started|\
+  Application {0} is {1}|\
   No recovery required|\
-  The APPC will now accept new LCM requests for processing.     
+  The APPC will now accept new LCM requests for processing.
 
+INVALID_STATE_TRANSITION=APPC0158E|\
+  A {1} API is not allowed when {0} in the {2} state|\
+  No recovery required|\
+  The Operation requested cannot be performed as per the current state of APPC.
 
+OAM_OPERATION_STOPPING=APPC0159W|\
+  Application {0} is {1}|\
+  No recovery required|\
+  The APPC has initiated its stop procedure. Its internal LCM bundles are stopping.
+
+OAM_OPERATION_STOPPED=APPC0160W|\
+  Application {0} is {1}|\
+  No recovery required|\
+  The APPC LCM bundles have now stopped.
+
+REQUEST_HANDLER_UNAVAILABLE=APPC0161E|\
+  Application {0} was unable to find the Request Handler service |\
+  The application controller attempted to get a handle on Request Handler service \
+    but was unable to locate it in  the OSGi Service Registry.|\
+  Verify if the Request Handler bundle is running.
+
+OAM_OPERATION_RESTARTING=APPC0162W|\
+  Application {0} is {1}|\
+  No recovery required|\
+  The APPC has initiated its restart procedure. Its internal LCM bundles are stopping and will then start again.
+
+OAM_OPERATION_RESTARTED=APPC0163W|\
+  Application {0} is {1} for restart|\
+  No recovery required|\
+  The APPC LCM bundles have been restared (stopped and then started).
+
+OAM_OPERATION_INVALID_INPUT=APPC0162E|\
+  {0}|\
+  No recovery required|\
+  Fix the input parameter and retry.
diff --git a/appc-common/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg b/appc-common/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg
index 78b50cf..a3a3f58 100644
--- a/appc-common/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg
+++ b/appc-common/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg
@@ -110,6 +110,10 @@
     #Store to the same log file messages from upper level appender or not
     log4j.additivity.org.openecomp=false
 
+    #org.openecomp logger
+    log4j.logger.org.openecomp=TRACE, debug, error
+    log4j.additivity.org.openecomp=false
+
     #EELFManager loggers
     #EELF parent logger
     log4j.logger.com.att.eelf=TRACE, debug
diff --git a/appc-event-listener/appc-event-listener-bundle/src/main/java/org/openecomp/appc/listener/AppcEventListenerActivator.java b/appc-event-listener/appc-event-listener-bundle/src/main/java/org/openecomp/appc/listener/AppcEventListenerActivator.java
index 86abd60..b8cfa2e 100644
--- a/appc-event-listener/appc-event-listener-bundle/src/main/java/org/openecomp/appc/listener/AppcEventListenerActivator.java
+++ b/appc-event-listener/appc-event-listener-bundle/src/main/java/org/openecomp/appc/listener/AppcEventListenerActivator.java
@@ -43,8 +43,8 @@
  * <p>
  * The DMaaP listener is responsible for listening to a topic on the Universal Event Bus and reading in messages that
  * conform to the DCAE message format for APPC. These messages will then be parsed and passed along to the APPC Provider
- * to take action on. The listener will also send messages out on DMaaP during critical phases. The messages sent out will
- * have a status of:
+ * to take action on. The listener will also send messages out on DMaaP during critical phases. The messages sent out
+ * will have a status of:
  * <ul>
  * <li><i>PENDING</i> - The listener has read the message off of DMaaP and has put it in the queue to be processed</li>
  * <li><i>ACTIVE</i> - The listener has begun actually processing the request and is waiting on the appc provider to
@@ -119,29 +119,28 @@
 
         Properties props = configuration.getProperties();
 
-        Set<ListenerProperties> listeners = new HashSet<ListenerProperties>();
+        Set<ListenerProperties> listeners = new HashSet<>();
 
         // Configure event listener for the demo use case
         ListenerProperties demoProps = new ListenerProperties("appc.demo", props);
         demoProps.setListenerClass(org.openecomp.appc.listener.demo.impl.ListenerImpl.class);
         listeners.add(demoProps);
 
-	// ===========================================================================
+        // ===========================================================================
 
         ListenerProperties clLCMProps = new ListenerProperties("appc.LCM", props);
         clLCMProps.setListenerClass(org.openecomp.appc.listener.LCM.impl.ListenerImpl.class);
         listeners.add(clLCMProps);
 
-        //Configure the OAM properties
-        clLCMProps = new ListenerProperties("appc.OAM", props);
-        clLCMProps.setListenerClass(org.openecomp.appc.listener.LCM.impl.ListenerImpl.class);
-        listeners.add(clLCMProps);
-
-/*
-        ListenerProperties clLCMProps1607 = new ListenerProperties("appc.LCM1607", props);
-        clLCMProps1607.setListenerClass(org.openecomp.appc.listener.LCM1607.impl.ListenerImpl.class);
-        listeners.add(clLCMProps1607);
-*/
+        // Configure the OAM properties
+        String oamPropKeyPrefix = "appc.OAM";
+        ListenerProperties oamProps  = new ListenerProperties(oamPropKeyPrefix, props);
+        if (isAppcOamPropsListenerEnabled(oamProps)) {
+            oamProps.setListenerClass(org.openecomp.appc.listener.LCM.impl.ListenerImpl.class);
+            listeners.add(oamProps);
+        } else {
+            LOG.warn(String.format("The listener %s is disabled and will not be run", oamPropKeyPrefix));
+        }
 
         adapter = new ControllerImpl(listeners);
         if (ctx != null && registration == null) {
@@ -186,4 +185,17 @@
         return "DMaaP Listener";
     }
 
+    /**
+     * Check if AppcOam props disable listener or not
+     *
+     * @param listenerProperties of ListenerProperties objext
+     * @return false only if AppcOam disabled key is defined and equal to true. Otherwise, return true.
+     */
+    private boolean isAppcOamPropsListenerEnabled(ListenerProperties listenerProperties) {
+        final Properties appcOamProperties = listenerProperties.getProperties();
+
+        return appcOamProperties == null
+                || !Boolean.parseBoolean(appcOamProperties.getProperty(
+                        ListenerProperties.KEYS.DISABLED.getPropertySuffix()));
+    }
 }
diff --git a/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/default.properties b/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/default.properties
index dc84b8b..e9b78cc 100644
--- a/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/default.properties
+++ b/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/default.properties
@@ -50,3 +50,41 @@
 org.openecomp.appc.logging.file=logback.xml
 
 
+#
+# The properties would be used by OAM's Stop/Start APIs to stop/start the bundles
+#
+appc.OAM.ToStop.properties=appc.OAM.AppcBundlesToStop\
+,appc.OAM.OtherBundlesToStop
+appc.OAM.ToNotStop.properties=appc.OAM.AppcBundlesToNotStop\
+,appc.OAM.OtherBundlesToNotStop
+
+# These following properties represent the Regular-Expression which would be evaluated against the
+# running Bundles's Symbolic-Name:
+#   - appc.OAM.AppcBundlesToStop
+#   - appc.OAM.OtherBundlesToStop
+#   - appc.OAM.AppcBundlesToNotStop
+#   - appc.OAM.OtherBundlesToNotStop
+appc.OAM.AppcBundlesToStop=.*appc.*\
+,domain-model-lib\
+,execution-queue-management-lib\
+,lock-manager-impl\
+,org.openecomp.sdnc.config.params\
+,org.openecomp.sdnc.config.audit\
+,org.openecomp.sdnc.config.generator\
+,org.openecomp.sdnc.dg.loader\
+,transaction-recorder
+
+appc.OAM.OtherBundlesToStop=.*app-cntrl.*\
+,com.att.sdnctl.sli.adaptor.asyncresponse
+
+appc.OAM.AppcBundlesToNotStop=.*appc.oam.*\
+,appc-common\
+,appc-command-executor-api\
+,appc-lifecycle-management-api\
+,appc-lifecycle-management-core\
+,appc-metric-bundle\
+,org.openecomp.appc.listener\
+,state-machine-lib
+
+appc.OAM.OtherBundlesToNotStop=app-cntrl-message-adapter-factory\
+,app-cntrl-aaf-filters
diff --git a/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg b/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg
deleted file mode 100644
index be58632..0000000
--- a/appc-oam/appc-oam-bundle/src/main/resources/org/openecomp/appc/org.ops4j.pax.logging.cfg
+++ /dev/null
@@ -1,144 +0,0 @@
-    ################################################################################
-    #
-    #    Licensed to the Apache Software Foundation (ASF) under one or more
-    #    contributor license agreements.  See the NOTICE file distributed with
-    #    this work for additional information regarding copyright ownership.
-    #    The ASF licenses this file to You 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,
-    #    WITH WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    #    See the License for the specific language governing permissions and
-    #    limitations under the License.
-    #
-    ################################################################################
-
-    # Root
-    #log4j.rootLogger=TRACE, osgi:VmLogAppender
-    log4j.rootLogger=TRACE, out, sift, osgi:*
-    log4j.throwableRenderer=org.apache.log4j.OsgiThrowableRenderer
-
-    # CONSOLE appender not used by default
-    log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-    log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-    log4j.appender.stdout.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %-16.16t | %-32.32c{1} | %X{bundle.id} - %X{bundle.name} - %X{bundle.version} | %m%n
-
-    # Async appender forwarding to file appender
-    log4j.appender.async=org.apache.log4j.AsyncAppender
-    log4j.appender.async.appenders=out
-
-    # Karaf appenders
-    # File appender
-    log4j.appender.out=org.apache.log4j.RollingFileAppender
-    log4j.appender.out.layout=org.apache.log4j.PatternLayout
-    log4j.appender.out.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %-16.16t | %-32.32c{1} | %X{bundle.id} - %X{bundle.name} - %X{bundle.version} | %m%n
-    log4j.appender.out.file=${karaf.data}/log/karaf.log
-    log4j.appender.out.append=true
-    log4j.appender.out.maxFileSize=10MB
-    log4j.appender.out.maxBackupIndex=100
-
-
-    # Sift appender
-    log4j.appender.sift=org.apache.log4j.sift.MDCSiftingAppender
-    log4j.appender.sift.key=bundle.name
-    log4j.appender.sift.default=karaf
-    log4j.appender.sift.appender=org.apache.log4j.RollingFileAppender
-    log4j.appender.sift.appender.layout=org.apache.log4j.PatternLayout
-    log4j.appender.sift.appender.layout.ConversionPattern=%d{MM/dd-HH:mm:ss.SSS}|%X{RequestId}|%X{ServiceInstanceId}|%t|%X{ServiceName} - %X{bundle.id} - %X{bundle.name} - %X{bundle.version}|%-5.5p|%X{AlertSeverity}|%X{ServerFQDN}|%X{ServerIPAddress}|[%c{3}]|%m%n
-    log4j.appender.sift.appender.file=${karaf.data}/log/eelf/karaf.log
-    log4j.appender.sift.appender.append=true
-
-    log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPusherImpl=DEBUG
-    log4j.category.org.opendaylight.controller.netconf.persist.impl.osgi.ConfigPersisterActivator=DEBUG
-
-
-    #ECOMP Debug appender
-    log4j.appender.debug=org.apache.log4j.RollingFileAppender
-    log4j.appender.debug.key=bundle.name
-    log4j.appender.debug.default=karaf
-
-    log4j.appender.debug.appName=EELFDebug
-    log4j.appender.debug.layout=org.apache.log4j.PatternLayout
-    log4j.appender.debug.layout.ConversionPattern=%d{yyyy-MM-dd'T'hh:mm:ss.SSSXXX}|%X{RequestId}|%m%n
-    #log4j.appender.debug.filter.f1=org.apache.log4j.varia.LevelRangeFilter
-    #log4j.appender.debug.filter.f1.LevelMax=WARN
-    #log4j.appender.debug.filter.f1.LevelMin=TRACE
-
-    
-    log4j.appender.debug.file=${karaf.data}/log/APPC/appc-debug.log
-    log4j.appender.debug.append=true
-    log4j.appender.debug.maxFileSize=100MB
-    log4j.appender.debug.maxBackupIndex=10
-
-
-    #Error appender
-    log4j.appender.error=org.apache.log4j.RollingFileAppender
-    log4j.appender.error.appName=EELFError
-    log4j.appender.error.File=${karaf.data}/log/APPC/appc-error.log
-    log4j.appender.error.Threshold=ERROR
-    log4j.appender.error.MaxBackupIndex=1
-    log4j.appender.error.MaxFileSize=100MB
-    log4j.appender.error.layout=org.apache.log4j.PatternLayout
-    log4j.appender.error.layout.ConversionPattern=%d{yyyy-MM-dd'T'hh:mm:ss.SSSXXX}|%X{RequestId}|%t|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%-5.5p|%X{ErrorCode}|%X{ErrorDescription}|%m%n
-
-    #Metrics appender
-    log4j.appender.metric=org.apache.log4j.RollingFileAppender
-    log4j.appender.metric.appName=EELFMetrics
-    log4j.appender.metric.File=${karaf.data}/log/APPC/appc-metric.log
-    log4j.appender.metric.MaxBackupIndex=1
-    log4j.appender.metric.MaxFileSize=100MB
-    log4j.appender.metric.layout=org.apache.log4j.PatternLayout
-    log4j.appender.metric.layout.ConversionPattern=%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%t|%X{ServerName}|%X{ServiceName}|%X{PartnerName}|%X{TargetEntity}|%X{TargetServiceName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDescription}|%X{InstanceUUID}|%-5.5p|%X{Severity}|%X{ServerIPAddress}|%X{ElapsedTime}|%X{ServerFQDN}|%X{ClientIPAddress}|%X{ClassName}||%X{ProcessKey}|%X{TargetVirtualEntity}|%X{CustomField1}|%X{CustomField2}|%X{CustomField3}|%X{CustomField4}|%m%n
-
-    #Audit appender
-    log4j.appender.audit=org.apache.log4j.RollingFileAppender
-    log4j.appender.audit.appName=EELFAudit
-    log4j.appender.audit.File=${karaf.data}/log/APPC/appc-audit.log
-    log4j.appender.audit.MaxBackupIndex=1
-    log4j.appender.audit.MaxFileSize=100MB
-    log4j.appender.audit.layout=org.apache.log4j.PatternLayout
-    log4j.appender.audit.layout.ConversionPattern=%X{BeginTimestamp}|%X{EndTimestamp}|%X{RequestId}|%X{ServiceInstanceId}|%t|%X{ServerName}|%X{ServiceName}|%X{PartnerName}|%X{StatusCode}|%X{ResponseCode}|%X{ResponseDescription}|%X{InstanceUUID}|%-5.5p|%X{Severity}|%X{ServerIPAddress}|%X{ElapsedTime}|%X{ServerFQDN}|%X{ClientIPAddress}|%X{ClassName}||%X{ProcessKey}|%X{CustomField1}|%X{CustomField2}|%X{CustomField3}|%X{CustomField4}|%m%n
-
-    #Loggers
-    #Routing of all messages from root logger
-    log4j.logger.com.att=TRACE, debug, error
-    #Store to the same log file messages from upper level appender or not
-    log4j.additivity.com.att=false
-
-    #EELFManager loggers
-    #EELF parent logger
-    log4j.logger.com.att.eelf=TRACE, debug
-    log4j.additivity.com.att.eelf=false
- 
-    #Audit logger routing
-    log4j.logger.com.att.eelf.audit=DEBUG, audit
-    log4j.additivity.com.att.eelf.audit=false     
-    
-    #Metric logger routing
-    log4j.logger.com.att.eelf.metrics=DEBUG, metric
-    log4j.additivity.com.att.eelf.metrics=false
-
-    #Performance logger routing
-    log4j.logger.com.att.eelf.perf=DEBUG, metric
-    log4j.additivity.com.att.eelf.perf=false 
-
-    #Server logger routing
-    log4j.logger.com.att.eelf.server=DEBUG, debug
-    log4j.additivity.com.att.eelf.server=false 
-
-    #Policy logger routing
-    log4j.logger.com.att.eelf.policy=DEBUG, debug
-    log4j.additivity.com.att.eelf.policy=false 
- 
-    #Error logger routing
-    log4j.logger.com.att.eelf.error=DEBUG, error
-    log4j.additivity.com.att.eelf.error=false 
-
-    #Debug logger routing
-    log4j.logger.com.att.eelf.debug=DEBUG, debug
-    log4j.additivity.com.att.eelf.debug=false 
-
diff --git a/appc-oam/appc-oam-installer/src/main/resources/scripts/install-feature.sh b/appc-oam/appc-oam-installer/src/main/resources/scripts/install-feature.sh
index 05b4ae3..8de5e57 100644
--- a/appc-oam/appc-oam-installer/src/main/resources/scripts/install-feature.sh
+++ b/appc-oam/appc-oam-installer/src/main/resources/scripts/install-feature.sh
@@ -39,5 +39,29 @@
 	exit 1
 fi
 
-${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:repo-add ${features.repositories}
-${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:install ${features.boot}
+#${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:repo-add ${features.repositories}
+#${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:install ${features.boot}
+
+
+COUNT=0
+while [ $COUNT -lt 10 ]; do
+	${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:repo-add ${features.repositories} 2> /tmp/installErr
+	cat /tmp/installErr
+	if grep -q 'Failed to get the session' /tmp/installErr; then
+		sleep 10
+	else
+		let COUNT=10
+	fi
+	let COUNT=COUNT+1
+done
+COUNT=0
+while [ $COUNT -lt 10 ]; do
+	${ODL_KARAF_CLIENT} ${ODL_KARAF_CLIENT_OPTS} feature:install ${features.boot} 2> /tmp/installErr
+		cat /tmp/installErr
+	if grep -q 'Failed to get the session' /tmp/installErr; then
+		sleep 10
+	else
+		let COUNT=10
+	fi
+	let COUNT=COUNT+1
+done
diff --git a/appc-provider/appc-provider-bundle/src/main/java/org/openecomp/appc/provider/AppcProviderLcm.java b/appc-provider/appc-provider-bundle/src/main/java/org/openecomp/appc/provider/AppcProviderLcm.java
index 90097ae..2924969 100644
--- a/appc-provider/appc-provider-bundle/src/main/java/org/openecomp/appc/provider/AppcProviderLcm.java
+++ b/appc-provider/appc-provider-bundle/src/main/java/org/openecomp/appc/provider/AppcProviderLcm.java
@@ -24,18 +24,91 @@
 
 package org.openecomp.appc.provider;
 
-import java.text.ParseException;
-import java.util.Collection;
-import java.util.concurrent.ExecutorService;
-import java.util.concurrent.Executors;
-import java.util.concurrent.Future;
-
+import com.att.eelf.configuration.EELFLogger;
+import com.att.eelf.configuration.EELFManager;
+import com.att.eelf.i18n.EELFResourceManager;
+import com.google.common.util.concurrent.Futures;
 import org.opendaylight.controller.md.sal.binding.api.DataBroker;
 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker;
 import org.opendaylight.controller.sal.binding.api.NotificationProviderService;
 import org.opendaylight.controller.sal.binding.api.RpcProviderRegistry;
-import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.common.header.CommonHeader;
-import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.*;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.Action;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.AppcProviderLcmService;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.AuditInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.AuditOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.AuditOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.CheckLockInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.CheckLockOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.CheckLockOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupDeleteInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupDeleteOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupDeleteOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigBackupOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigExportInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigExportOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigExportOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigModifyInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigModifyOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigModifyOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigRestoreInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigRestoreOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigRestoreOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigScaleoutInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigScaleoutOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigScaleoutOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigureInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigureOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.ConfigureOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.EvacuateInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.EvacuateOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.EvacuateOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.HealthCheckInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.HealthCheckOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.HealthCheckOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LiveUpgradeInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LiveUpgradeOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LiveUpgradeOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LockInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LockOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.LockOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.MigrateInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.MigrateOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.MigrateOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RebuildInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RebuildOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RebuildOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RestartInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RestartOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RestartOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RollbackInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RollbackOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.RollbackOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SnapshotInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SnapshotOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SnapshotOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SoftwareUploadInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SoftwareUploadOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SoftwareUploadOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StartInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StartOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StartOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StopInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StopOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.StopOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SyncInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SyncOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.SyncOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TerminateInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TerminateOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TerminateOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TestInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TestOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.TestOutputBuilder;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.UnlockInput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.UnlockOutput;
+import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.UnlockOutputBuilder;
 import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.status.Status;
 import org.opendaylight.yang.gen.v1.org.openecomp.appc.lcm.rev160108.status.StatusBuilder;
 import org.opendaylight.yangtools.yang.common.RpcResult;
@@ -43,9 +116,8 @@
 import org.openecomp.appc.Constants;
 import org.openecomp.appc.configuration.Configuration;
 import org.openecomp.appc.configuration.ConfigurationFactory;
-import org.openecomp.appc.domainmodel.lcm.ActionLevel;
 import org.openecomp.appc.domainmodel.lcm.ResponseContext;
-import org.openecomp.appc.domainmodel.lcm.RuntimeContext;
+import org.openecomp.appc.exceptions.APPCException;
 import org.openecomp.appc.executor.objects.LCMCommandStatus;
 import org.openecomp.appc.executor.objects.Params;
 import org.openecomp.appc.i18n.Msg;
@@ -56,17 +128,14 @@
 import org.openecomp.appc.requesthandler.RequestHandler;
 import org.openecomp.appc.requesthandler.objects.RequestHandlerInput;
 import org.openecomp.appc.requesthandler.objects.RequestHandlerOutput;
-import com.att.eelf.configuration.EELFLogger;
-import com.att.eelf.configuration.EELFManager;
-import com.att.eelf.i18n.EELFResourceManager;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.FrameworkUtil;
-import org.osgi.framework.InvalidSyntaxException;
 import org.osgi.framework.ServiceReference;
 
-import com.google.common.util.concurrent.Futures;
-import org.slf4j.MDC;
-
+import java.text.ParseException;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
+import java.util.concurrent.Future;
 
 public class AppcProviderLcm implements AutoCloseable, AppcProviderLcmService {
 
@@ -146,7 +215,7 @@
     /**
      * Rebuilds a specific VNF
      *
-     * @see org.opendaylight.yang.gen.v1.org.openecomp.appc.rev160108.AppcProviderLcmService#rebuild(RebuildInput)
+     * @see AppcProviderLcmService#rebuild(RebuildInput)
      */
     @Override
     public Future<RpcResult<RebuildOutput>> rebuild(RebuildInput input) {
@@ -155,12 +224,17 @@
         RebuildOutputBuilder outputBuilder = new RebuildOutputBuilder();
         String action = Action.Rebuild.toString() ;
         String rpcName = Action.Rebuild.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -175,10 +249,8 @@
         outputBuilder.setStatus(status);
         RpcResult<RebuildOutput> result = RpcResultBuilder.<RebuildOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
-
     }
 
-
     /**
      * Restarts a specific VNF
      *
@@ -191,7 +263,8 @@
         RestartOutputBuilder outputBuilder = new RestartOutputBuilder();
         String action = Action.Restart.toString() ;
         String rpcName = Action.Restart.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
                 RequestHandlerInput request = new RequestInputBuilder().requestContext()
@@ -203,7 +276,8 @@
                         .build();
 
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -220,11 +294,10 @@
         return Futures.immediateFuture(result);
     }
 
-
     /**
      * Migrates a specific VNF
      *
-     * @see org.opendaylight.yang.gen.v1.org.openecomp.appc.rev160108.AppcProviderLcmService#migrate(MigrateInput)
+     * @see AppcProviderLcmService#migrate(MigrateInput)
      */
     @Override
     public Future<RpcResult<MigrateOutput>> migrate(MigrateInput input) {
@@ -233,12 +306,17 @@
         MigrateOutputBuilder outputBuilder = new MigrateOutputBuilder();
         String action = Action.Migrate.toString() ;
         String rpcName = Action.Migrate.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -255,11 +333,10 @@
         return Futures.immediateFuture(result);
     }
 
-
     /**
      * Evacuates a specific VNF
      *
-     * @see org.opendaylight.yang.gen.v1.org.openecomp.appc.rev160108.AppcProviderLcmService#evacuate(EvacuateInput)
+     * @see AppcProviderLcmService#evacuate(EvacuateInput)
      */
     @Override
     public Future<RpcResult<EvacuateOutput>> evacuate(EvacuateInput input) {
@@ -294,7 +371,7 @@
     /**
      * Evacuates a specific VNF
      *
-     * @see org.opendaylight.yang.gen.v1.org.openecomp.appc.rev160108.AppcProviderLcmService#snapshot(SnapshotInput)
+     * @see AppcProviderLcmService#snapshot(SnapshotInput)
      */
     @Override
     public Future<RpcResult<SnapshotOutput>> snapshot(SnapshotInput input) {
@@ -303,13 +380,19 @@
         SnapshotOutputBuilder outputBuilder = new SnapshotOutputBuilder();
         String action = Action.Snapshot.toString() ;
         String rpcName = Action.Snapshot.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         String identityUrl = input.getIdentityUrl();
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).additionalContext("identity-url", identityUrl).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName)
+                        .additionalContext("identity-url", identityUrl).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -331,14 +414,20 @@
 
         RollbackOutputBuilder outputBuilder = new RollbackOutputBuilder();
         String rpcName = Action.Rollback.toString() ;
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), rpcName);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), rpcName);
         String identityUrl =  input.getIdentityUrl();
         String snapshotId = input.getSnapshotId();
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).additionalContext("identity-url", identityUrl).additionalContext("snapshot-id", snapshotId).action(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).additionalContext("identity-url", identityUrl)
+                        .additionalContext("snapshot-id", snapshotId).action(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -361,12 +450,17 @@
         SyncOutputBuilder outputBuilder = new SyncOutputBuilder();
         String action = Action.Sync.toString() ;
         String rpcName = Action.Sync.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -404,56 +498,63 @@
     }
 
     private RequestHandlerOutput executeRequest(RequestHandlerInput request){
-
-        RequestHandler handler = getRequestHandler(request.getRequestContext().getActionLevel());
+        RequestHandler handler = getRequestHandler();
         RequestHandlerOutput requestHandlerOutput;
+        if (handler != null) {
         try {
             requestHandlerOutput = handler.handleRequest(request);
         } catch (Exception e) {
-
-            final String appName = configuration.getProperty(Constants.PROPERTY_APPLICATION_NAME);
-            final String reason = EELFResourceManager.format(Msg.EXCEPTION_CALLING_DG, e, appName, e.getClass().getSimpleName(), "", e.getMessage());
-
             logger.info("UNEXPECTED FAILURE while executing " + request.getRequestContext().getAction().name());
-
-
-            final ResponseContext responseContext = new ResponseContext();
-            requestHandlerOutput = new RequestHandlerOutput();
-            requestHandlerOutput.setResponseContext(responseContext);
-            responseContext.setCommonHeader(request.getRequestContext().getCommonHeader());
-            String errorMessage = e.getMessage() != null ? e.getMessage() : e.toString();
-            Params params = new Params().addParam("errorMsg", errorMessage);
-            responseContext.setStatus(LCMCommandStatus.UNEXPECTED_ERROR.toStatus(params));
-
-            LoggingUtils.logErrorMessage(
-                    LoggingConstants.TargetNames.APPC_PROVIDER,
-                    reason,
-                    this.getClass().getName());
-
-
+            requestHandlerOutput = createErrorRequestHandlerObj(request,
+                    LCMCommandStatus.UNEXPECTED_ERROR, Msg.EXCEPTION_CALLING_DG, e);
+        }
+        } else {
+            String errorMsg = "LCM request cannot be processed at the moment because APPC isn't running";
+            requestHandlerOutput = createErrorRequestHandlerObj(request,
+                    LCMCommandStatus.REJECTED, Msg.REQUEST_HANDLER_UNAVAILABLE, new APPCException(errorMsg));
         }
         return requestHandlerOutput;
     }
 
-    private RequestHandler getRequestHandler(ActionLevel actionLevel){
-        RequestHandler handler ;
-        final BundleContext context = FrameworkUtil.getBundle(RequestHandler.class).getBundleContext();
-        String filter = "(level=" + actionLevel.name() + ")";
-        try {
-            Collection<ServiceReference<RequestHandler>> serviceReferences = context.getServiceReferences(RequestHandler.class, filter);
-            if (serviceReferences.size() != 1) {
-                logger.error("Cannot find service reference for " + RequestHandler.class.getName());
-                throw new RuntimeException();
-            }
-            ServiceReference<RequestHandler> serviceReference = serviceReferences.iterator().next();
-            handler = context.getService(serviceReference);
-        } catch (InvalidSyntaxException e) {
-            logger.error("Cannot find service reference for " + RequestHandler.class.getName() + ": Invalid Syntax " + filter, e);
-            throw new RuntimeException(e);
-        }
-        return  handler ;
+    private RequestHandlerOutput createErrorRequestHandlerObj(RequestHandlerInput request,
+                                                              LCMCommandStatus cmdStatus,
+                                                              Msg msg,
+                                                              Exception e) {
+        final String appName = configuration.getProperty(Constants.PROPERTY_APPLICATION_NAME);
+        final String reason = EELFResourceManager.format(msg, e,
+                appName, e.getClass().getSimpleName(), "", e.getMessage());
+
+        RequestHandlerOutput requestHandlerOutput = new RequestHandlerOutput();
+        final ResponseContext responseContext = new ResponseContext();
+        requestHandlerOutput.setResponseContext(responseContext);
+        responseContext.setCommonHeader(request.getRequestContext().getCommonHeader());
+
+        String errorMessage = e.getMessage() != null ? e.getMessage() : e.toString();
+        Params params = new Params().addParam("errorMsg", errorMessage);
+        responseContext.setStatus(cmdStatus.toStatus(params));
+
+        LoggingUtils.logErrorMessage(
+                LoggingConstants.TargetNames.APPC_PROVIDER,
+                reason,
+                this.getClass().getName());
+
+        return requestHandlerOutput;
     }
 
+    private RequestHandler getRequestHandler(){
+        final BundleContext context = FrameworkUtil.getBundle(RequestHandler.class).getBundleContext();
+        if (context == null) {
+            return null;
+        }
+
+        final ServiceReference reference = context.getServiceReference(RequestHandler.class.getName());
+        if (reference == null) {
+            logger.error("Cannot find service reference for " + RequestHandler.class.getName());
+            throw new RuntimeException();
+        }
+
+        return (RequestHandler) context.getService(reference);
+    }
 
     @Override
     public Future<RpcResult<TerminateOutput>> terminate(TerminateInput input) {
@@ -461,12 +562,17 @@
         TerminateOutputBuilder outputBuilder = new TerminateOutputBuilder();
         String action = Action.Terminate.toString() ;
         String rpcName = Action.Terminate.name().toLowerCase();
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
 
                 status = buildParsingErrorStatus(e);
@@ -481,7 +587,8 @@
         }
         outputBuilder.setCommonHeader(input.getCommonHeader());
         outputBuilder.setStatus(status);
-        RpcResult<TerminateOutput> result = RpcResultBuilder.<TerminateOutput> status(true).withResult(outputBuilder.build()).build();
+        RpcResult<TerminateOutput> result =
+                RpcResultBuilder.<TerminateOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
     }
 
@@ -491,12 +598,17 @@
         ConfigureOutputBuilder outputBuilder = new ConfigureOutputBuilder();
         String action = Action.Configure.toString() ;
         String rpcName = "configure";
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -509,7 +621,8 @@
         }
         outputBuilder.setCommonHeader(input.getCommonHeader());
         outputBuilder.setStatus(status);
-        RpcResult<ConfigureOutput> result = RpcResultBuilder.<ConfigureOutput> status(true).withResult(outputBuilder.build()).build();
+        RpcResult<ConfigureOutput> result =
+                RpcResultBuilder.<ConfigureOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
     }
 
@@ -519,12 +632,17 @@
         ConfigModifyOutputBuilder outputBuilder = new ConfigModifyOutputBuilder();
         String action = Action.ConfigModify.toString() ;
         String rpcName = "config-modify";
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -537,7 +655,8 @@
         }
         outputBuilder.setCommonHeader(input.getCommonHeader());
         outputBuilder.setStatus(status);
-        RpcResult<ConfigModifyOutput> result = RpcResultBuilder.<ConfigModifyOutput> status(true).withResult(outputBuilder.build()).build();
+        RpcResult<ConfigModifyOutput> result =
+                RpcResultBuilder.<ConfigModifyOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
     }
 
@@ -547,12 +666,17 @@
         ConfigScaleoutOutputBuilder outputBuilder = new ConfigScaleoutOutputBuilder();
         String action = Action.ConfigScaleOut.toString() ;
         String rpcName = "config-scaleout";
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -565,7 +689,8 @@
         }
         outputBuilder.setCommonHeader(input.getCommonHeader());
         outputBuilder.setStatus(status);
-        RpcResult<ConfigScaleoutOutput> result = RpcResultBuilder.<ConfigScaleoutOutput> status(true).withResult(outputBuilder.build()).build();
+        RpcResult<ConfigScaleoutOutput> result =
+                RpcResultBuilder.<ConfigScaleoutOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
     }
 
@@ -575,12 +700,17 @@
         ConfigRestoreOutputBuilder outputBuilder = new ConfigRestoreOutputBuilder();
         String action = Action.ConfigRestore.toString() ;
         String rpcName = "config-restore";
-        Status status = ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
+        Status status =
+                ValidationService.getInstance().validateInput(input.getCommonHeader(), input.getAction(), action);
         if(null == status) {
             try {
-                RequestHandlerInput request = new RequestInputBuilder().requestContext().commonHeader(input.getCommonHeader()).actionIdentifiers(input.getActionIdentifiers()).payload(input.getPayload()).action(action).rpcName(rpcName).build();
+                RequestHandlerInput request = new RequestInputBuilder().requestContext()
+                        .commonHeader(input.getCommonHeader())
+                        .actionIdentifiers(input.getActionIdentifiers())
+                        .payload(input.getPayload()).action(action).rpcName(rpcName).build();
                 status = buildStatusWithDispatcherOutput(executeRequest(request));
-                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s", input.getActionIdentifiers(), status.getCode(), status.getMessage()));
+                logger.info(String.format("Execute of '%s' finished with status %s. Reason: %s",
+                        input.getActionIdentifiers(), status.getCode(), status.getMessage()));
             } catch (ParseException e) {
                 status = buildParsingErrorStatus(e);
 
@@ -593,7 +723,8 @@
         }
         outputBuilder.setCommonHeader(input.getCommonHeader());
         outputBuilder.setStatus(status);
-        RpcResult<ConfigRestoreOutput> result = RpcResultBuilder.<ConfigRestoreOutput> status(true).withResult(outputBuilder.build()).build();
+        RpcResult<ConfigRestoreOutput> result =
+                RpcResultBuilder.<ConfigRestoreOutput> status(true).withResult(outputBuilder.build()).build();
         return Futures.immediateFuture(result);
     }
 
@@ -657,7 +788,7 @@
     /**
      * Starts a specific VNF
      *
-     * @see org.opendaylight.yang.gen.v1.org.openecomp.appc.rev160108.AppcProviderLcmService#start(StartInput)
+     * @see AppcProviderLcmService#start(StartInput)
      */
     @Override
     public Future<RpcResult<StartOutput>> start(StartInput input) {
