diff --git a/smp-docker/pom.xml b/smp-docker/pom.xml
index 9dbf933e3bae11f5d9a56c58a214e46647f62827..b87aa729b80195cb63de7301a271b706816aa559 100644
--- a/smp-docker/pom.xml
+++ b/smp-docker/pom.xml
@@ -8,7 +8,7 @@
     <parent>
         <groupId>eu.europa.ec.edelivery</groupId>
         <artifactId>smp-modules</artifactId>
-        <version>5.0-SNAPSHOT</version>
+        <version>5.0-RC2-SNAPSHOT</version>
         <relativePath>../pom.xml</relativePath>
     </parent>
     <properties>
diff --git a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/data/dao/ConfigurationDao.java b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/data/dao/ConfigurationDao.java
index e6fa9af0161b3ca293ef9ddea84041de4e798e7c..5a1eefef9aa8887e0d89e45ca700ee864718784b 100644
--- a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/data/dao/ConfigurationDao.java
+++ b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/data/dao/ConfigurationDao.java
@@ -29,15 +29,12 @@ import eu.europa.ec.edelivery.smp.logging.SMPLoggerFactory;
 import eu.europa.ec.edelivery.smp.utils.PropertyUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.lang3.exception.ExceptionUtils;
-import org.springframework.beans.factory.InitializingBean;
 import org.springframework.context.ApplicationContext;
 import org.springframework.context.event.ContextRefreshedEvent;
 import org.springframework.context.event.ContextStoppedEvent;
 import org.springframework.context.event.EventListener;
 import org.springframework.stereotype.Repository;
-import org.springframework.transaction.PlatformTransactionManager;
 import org.springframework.transaction.annotation.Transactional;
-import org.springframework.transaction.support.TransactionTemplate;
 
 import javax.persistence.TypedQuery;
 import java.io.File;
@@ -54,7 +51,7 @@ import static eu.europa.ec.edelivery.smp.exceptions.ErrorCode.CONFIGURATION_ERRO
  * @since 4.2
  */
 @Repository(value = "configurationDao")
-public class ConfigurationDao extends BaseDao<DBConfiguration>  {
+public class ConfigurationDao extends BaseDao<DBConfiguration> {
 
     private static final SMPLogger LOG = SMPLoggerFactory.getLogger(ConfigurationDao.class);
     boolean isRefreshProcess = false;
@@ -62,8 +59,6 @@ public class ConfigurationDao extends BaseDao<DBConfiguration>  {
     Map<String, Object> cachedPropertyValues = new HashMap();
     OffsetDateTime lastUpdate = null;
     OffsetDateTime initiateDate = null;
-
-
     boolean serverRestartNeeded = false;
 
     protected final SMPEnvironmentProperties environmentProperties = SMPEnvironmentProperties.getInstance();
@@ -74,21 +69,6 @@ public class ConfigurationDao extends BaseDao<DBConfiguration>  {
         this.applicationContext = applicationContext;
     }
 
-    /**
-     * Validate and initialize database configurations
-
-    public void afterPropertiesSetTEest() {
-        LOG.info("Reload DomiSMP properties");
-        // Transaction might not be yet initialized (@Transactional on this method does not help :) ).
-        // Wrap the method to TransactionTemplate to make possible database property initialization
-        TransactionTemplate tmpl = new TransactionTemplate(txManager);
-        tmpl.execute(status -> {
-            LOG.info("Start initial (re)load of the DomiSMP properties with transaction status object [{}]",  status);
-            refreshProperties();
-            return null;
-        });
-    }
-     */
     /**
      * Searches for a configuration entity by its  key and returns it if found. Returns an empty {@code Optional} if missing.
      *
@@ -185,7 +165,7 @@ public class ConfigurationDao extends BaseDao<DBConfiguration>  {
         return cachedProperties.getProperty(property, defValue);
     }
 
-
+    @Transactional
     public <T extends Object> T getCachedPropertyValue(SMPPropertyEnum key) {
         if (lastUpdate == null) {
             // init properties
diff --git a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIGroupPublicService.java b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIGroupPublicService.java
index dcdabfd973c8c4a326d02e801389dd8ad24f6e38..4916e1c274bbbcb7ba11a1530f52585387d67653 100644
--- a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIGroupPublicService.java
+++ b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIGroupPublicService.java
@@ -4,6 +4,7 @@ import eu.europa.ec.edelivery.smp.data.dao.*;
 import eu.europa.ec.edelivery.smp.data.enums.MembershipRoleType;
 import eu.europa.ec.edelivery.smp.data.model.DBDomain;
 import eu.europa.ec.edelivery.smp.data.model.DBGroup;
+import eu.europa.ec.edelivery.smp.data.model.doc.DBResourceFilter;
 import eu.europa.ec.edelivery.smp.data.model.user.DBGroupMember;
 import eu.europa.ec.edelivery.smp.data.model.user.DBUser;
 import eu.europa.ec.edelivery.smp.data.ui.GroupRO;
@@ -37,12 +38,14 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
     private final GroupDao groupDao;
     private final GroupMemberDao groupMemberDao;
     private final DomainDao domainDao;
+    private final ResourceDao resourceDao;
     private final UserDao userDao;
     private final ConversionService conversionService;
 
-    public UIGroupPublicService(GroupDao groupDao, DomainDao domainDao, GroupMemberDao groupMemberDao, UserDao userDao, ConversionService conversionService) {
+    public UIGroupPublicService(GroupDao groupDao, DomainDao domainDao, ResourceDao resourceDao, GroupMemberDao groupMemberDao, UserDao userDao, ConversionService conversionService) {
         this.groupDao = groupDao;
         this.domainDao = domainDao;
+        this.resourceDao = resourceDao;
         this.conversionService = conversionService;
         this.groupMemberDao = groupMemberDao;
         this.userDao = userDao;
@@ -63,6 +66,7 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
      * @param filter
      * @return
      */
+    @Override
     public ServiceResult<GroupRO> getTableList(int page, int pageSize,
                                                String sortField,
                                                String sortOrder, Object filter) {
@@ -140,6 +144,14 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
         if (!Objects.equals(group.getDomain().getId(), domainId)) {
             throw new SMPRuntimeException(ErrorCode.INVALID_REQUEST, "DeleteGroup", "Group does not belong to domain");
         }
+
+        DBResourceFilter resourceFilter = DBResourceFilter.createBuilder().group(group).domain(group.getDomain()).build();
+        Long resCount = resourceDao.getResourcesForFilterCount(resourceFilter);
+
+        if (resCount > 0) {
+            throw new SMPRuntimeException(ErrorCode.INVALID_REQUEST, "DeleteGroup", "Group has resources [" + resCount + "] and can not be deleted");
+        }
+
         Long userCount = groupMemberDao.getGroupMemberCount(groupId, null);
         if (userCount > 0) {
             throw new SMPRuntimeException(ErrorCode.INVALID_REQUEST, "DeleteGroup", "Group has members [" + userCount + "] and can not be deleted");
@@ -185,7 +197,7 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
     @Transactional
     public ServiceResult<MemberRO> getGroupMembers(Long groupId, Long domainId, int page, int pageSize,
                                                    String filter) {
-        validateDomainAndGroup(groupId, domainId,"GetGroupMembers");
+        validateDomainAndGroup(groupId, domainId, "GetGroupMembers");
 
         Long count = groupMemberDao.getGroupMemberCount(groupId, filter);
         ServiceResult<MemberRO> result = new ServiceResult<>();
@@ -206,7 +218,7 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
     @Transactional
     public MemberRO addMemberToGroup(Long groupId, Long domainId, MemberRO memberRO, Long memberId) {
         LOG.info("Add member [{}] to group [{}]", memberRO.getUsername(), groupId);
-        validateDomainAndGroup(groupId, domainId,"AddMemberToGroup");
+        validateDomainAndGroup(groupId, domainId, "AddMemberToGroup");
 
         DBUser user = userDao.findUserByUsername(memberRO.getUsername())
                 .orElseThrow(() -> new SMPRuntimeException(ErrorCode.INVALID_REQUEST, "Add/edit membership", "User [" + memberRO.getUsername() + "] does not exists!"));
@@ -229,7 +241,7 @@ public class UIGroupPublicService extends UIServiceBase<DBGroup, GroupRO> {
     public MemberRO deleteMemberFromGroup(Long groupId, Long domainId, Long memberId) {
         LOG.info("Delete member [{}] from group [{}]", memberId, groupId);
 
-        validateDomainAndGroup(groupId, domainId,"DeleteMemberFromGroup");
+        validateDomainAndGroup(groupId, domainId, "DeleteMemberFromGroup");
 
         DBGroupMember groupMember = groupMemberDao.find(memberId);
         if (groupMember == null) {
diff --git a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupService.java b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupService.java
index b3e3c33791914340dc7a46e429dd238c1016077f..45c3bcf3e63ab38aa59b55dcb2085d22b487f089 100644
--- a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupService.java
+++ b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupService.java
@@ -148,96 +148,6 @@ public class UIServiceGroupService extends UIServiceBase<DBResource, ServiceGrou
 
     }
 
-    @Transactional
-    public List<ParticipantSMLRecord> updateServiceGroupList(List<ServiceGroupRO> lst, boolean serviceGroupAdmin) {
-        boolean suc = false;
-        List<ParticipantSMLRecord> lstRecords = new ArrayList<>();
-        for (ServiceGroupRO dRo : lst) {
-            if (dRo.getStatus() == EntityROStatus.NEW.getStatusNumber()) {
-                if (serviceGroupAdmin) {
-                    lstRecords.addAll(addNewServiceGroup(dRo));
-                }
-            } else if (dRo.getStatus() == EntityROStatus.UPDATED.getStatusNumber()) {
-                lstRecords.addAll(updateServiceGroup(dRo, serviceGroupAdmin));
-            } else if (dRo.getStatus() == EntityROStatus.REMOVE.getStatusNumber()) {
-                if (serviceGroupAdmin) {
-                    lstRecords.addAll(removeServiceGroup(dRo));
-                }
-            }
-        }
-        // register/unregister participants from domain
-        processSMLRecords(lstRecords);
-
-
-        return lstRecords;
-    }
-
-    /**
-     * Final process of SML records. If participant is to be unregistered it does not update status to database because
-     * it should not be there anymore! For registering it update status!
-     *
-     * @param lstRecords
-     */
-    public void processSMLRecords(List<ParticipantSMLRecord> lstRecords) {
-        if (!smlIntegrationService.isSMLIntegrationEnabled()) {
-            return;
-        }
-        /*
-        for (ParticipantSMLRecord record : lstRecords) {
-            if (record.getStatus() == SMLStatusEnum.REGISTER) {
-                boolean result = smlIntegrationService.registerParticipantToSML(record.getParticipantIdentifier(),
-                        record.getParticipantScheme(), record.getDomain());
-
-                updateServiceGroupDomainStatus(result, record);
-            } else if (record.getStatus() == SMLStatusEnum.UNREGISTER) {
-                boolean result = smlIntegrationService.unregisterParticipantFromSML(record.getParticipantIdentifier(),
-                        record.getParticipantScheme(), record.getDomain());
-                // no need to update database because record is deleted
-                updateServiceGroupDomainStatus(result, record);
-            }
-        }
-
-         */
-    }
-
-    protected void updateServiceGroupDomainStatus(boolean smlActionStatus, ParticipantSMLRecord record) {
-        Optional<DBDomainResourceDef> optionalServiceGroupDomain = serviceGroupDao.findServiceGroupDomain(record.getParticipantIdentifier(),
-                record.getParticipantScheme(), record.getDomain().getDomainCode());
-        /*
-        if (optionalServiceGroupDomain.isPresent()) {
-            DBDomainResourceDef serviceGroupDomain = optionalServiceGroupDomain.get();
-            if (serviceGroupDomain.isSmlRegistered() != smlActionStatus) {
-                serviceGroupDomain.setSmlRegistered(smlActionStatus);
-                serviceGroupDao.updateServiceGroupDomain(serviceGroupDomain);
-            }
-
-        }
-
-         */
-    }
-
-    /**
-     * Remove service group
-     *
-     * @param dRo
-     * @return
-     */
-    public List<ParticipantSMLRecord> removeServiceGroup(ServiceGroupRO dRo) {
-        List<ParticipantSMLRecord> participantSMLRecordList = new ArrayList<>();
-/*
-        DBResource dbServiceGroup = getDatabaseDao().find(dRo.getId());
-        // first update domains
-        List<DBDomainResourceDef> dbServiceGroupDomainList = dbServiceGroup.getResourceDomains();
-        dbServiceGroupDomainList.forEach(dro -> {
-            participantSMLRecordList.add(new ParticipantSMLRecord(SMLStatusEnum.UNREGISTER, dro.getServiceGroup().getIdentifierValue(),
-                    dro.getServiceGroup().getIdentifierScheme(), dro.getDomain()));
-        });
-        serviceGroupDao.removeServiceGroup(dbServiceGroup);
-
- */
-        return participantSMLRecordList;
-    }
-
 
     /**
      * Method validates and converts UI resource object entity to database entity and persists it to database
@@ -296,7 +206,6 @@ public class UIServiceGroupService extends UIServiceBase<DBResource, ServiceGrou
             smd.setDocumentIdentifier(dit.getValue());
 
         });
-
     }
 
     /**
diff --git a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/utils/SmpUrlBuilder.java b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/utils/SmpUrlBuilder.java
index 3d48b811c06d2889e4c2afab2f4f0774a8115bdc..d152b288eeff021469bc85c46d6c32f80bd6055f 100644
--- a/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/utils/SmpUrlBuilder.java
+++ b/smp-server-library/src/main/java/eu/europa/ec/edelivery/smp/utils/SmpUrlBuilder.java
@@ -13,7 +13,6 @@
 
 package eu.europa.ec.edelivery.smp.utils;
 
-import eu.europa.ec.edelivery.smp.conversion.IdentifierService;
 import eu.europa.ec.edelivery.smp.logging.SMPLogger;
 import eu.europa.ec.edelivery.smp.logging.SMPLoggerFactory;
 import eu.europa.ec.edelivery.smp.services.ConfigurationService;
@@ -85,36 +84,37 @@ public class SmpUrlBuilder {
         return uriBuilder
                 .toUriString();
     }
-/*
-    public String buildSMPUrlForParticipantAndDocumentIdentifier(ParticipantIdentifierType participantId, DocumentIdentifier docId) {
-        LOG.debug("Build SMP url for participant identifier: [{}] and document identifier [{}].", participantId, docId);
-        HttpServletRequest req = getCurrentRequest();
-        HttpForwardedHeaders fh = new HttpForwardedHeaders(req);
-        LOG.debug("Generate response uri with headers data: [{}]", fh);
-        UriComponentsBuilder uriBuilder = getSMPUrlBuilder();//
-        if (fh.getHost() != null) {
-            LOG.debug("Set response uri for forwarded headers: [{}]", fh);
-            uriBuilder = uriBuilder.host(fh.getHost());
-            String port = fh.getNonDefaultPort();
-            if (!StringUtils.isBlank(port)) {
-                uriBuilder = uriBuilder.port(port);
-            } else if (!StringUtils.isBlank(fh.getPort())) {
-                LOG.debug("Set port to null because it is default port: [{}]", fh);
-                uriBuilder = uriBuilder.port(null);
+
+    /*
+        public String buildSMPUrlForParticipantAndDocumentIdentifier(ParticipantIdentifierType participantId, DocumentIdentifier docId) {
+            LOG.debug("Build SMP url for participant identifier: [{}] and document identifier [{}].", participantId, docId);
+            HttpServletRequest req = getCurrentRequest();
+            HttpForwardedHeaders fh = new HttpForwardedHeaders(req);
+            LOG.debug("Generate response uri with headers data: [{}]", fh);
+            UriComponentsBuilder uriBuilder = getSMPUrlBuilder();//
+            if (fh.getHost() != null) {
+                LOG.debug("Set response uri for forwarded headers: [{}]", fh);
+                uriBuilder = uriBuilder.host(fh.getHost());
+                String port = fh.getNonDefaultPort();
+                if (!StringUtils.isBlank(port)) {
+                    uriBuilder = uriBuilder.port(port);
+                } else if (!StringUtils.isBlank(fh.getPort())) {
+                    LOG.debug("Set port to null because it is default port: [{}]", fh);
+                    uriBuilder = uriBuilder.port(null);
+                }
+                uriBuilder = uriBuilder.scheme(fh.getProto());
+            } else {
+                LOG.debug("Ignore settings header because host is null!");
             }
-            uriBuilder = uriBuilder.scheme(fh.getProto());
-        } else {
-            LOG.debug("Ignore settings header because host is null!");
-        }
-        String urlEncodedFormatParticipant = identifierService.urlEncodedFormatParticipant(participantId);
-        String urlEncodedFormatDocument = identifierService.urlEncodedFormatDocument(docId);
+            String urlEncodedFormatParticipant = identifierService.urlEncodedFormatParticipant(participantId);
+            String urlEncodedFormatDocument = identifierService.urlEncodedFormatDocument(docId);
 
-        return uriBuilder
-                .path(SMP_DOCUMENT_RESOURCE_TEMPLATE)
-                .buildAndExpand(urlEncodedFormatParticipant, urlEncodedFormatDocument)
-                .toUriString();
-    }
-*/
+            return uriBuilder
+                    .path(SMP_DOCUMENT_RESOURCE_TEMPLATE)
+                    .buildAndExpand(urlEncodedFormatParticipant, urlEncodedFormatDocument)
+                    .toUriString();
+        }
+    */
     public String buildSMPUrlForPath(String path) {
         LOG.debug("Build SMP url for path: [{}].", path);
 
@@ -131,7 +131,7 @@ public class SmpUrlBuilder {
     public UriComponentsBuilder getSMPUrlBuilder() {
 
         UriComponentsBuilder uriBuilder = ServletUriComponentsBuilder.fromCurrentRequestUri();
-       // uriBuilder = uriBuilder.replacePath(getUrlContext());
+        // uriBuilder = uriBuilder.replacePath(getUrlContext());
         return uriBuilder;
     }
 
diff --git a/smp-server-library/src/test/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupServiceUpdateListIntegrationTest.java b/smp-server-library/src/test/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupServiceUpdateListIntegrationTest.java
index cd71dfb7ca4815506d604e4d251554ff273a6168..34d76194a8c44da4388c1976c79ce7f8850b99b0 100644
--- a/smp-server-library/src/test/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupServiceUpdateListIntegrationTest.java
+++ b/smp-server-library/src/test/java/eu/europa/ec/edelivery/smp/services/ui/UIServiceGroupServiceUpdateListIntegrationTest.java
@@ -105,25 +105,6 @@ public class UIServiceGroupServiceUpdateListIntegrationTest extends AbstractServ
         assertEquals(serviceGroupRO.getParticipantIdentifier(), lst.get(0).getParticipantIdentifier());
         assertEquals(serviceGroupRO.getParticipantScheme(), lst.get(0).getParticipantScheme());
     }
-
-    @Test
-    @Transactional
-    public void removeServiceGroupTestSMLRecords() {
-        // given
-        ServiceResult<ServiceGroupRO> res = testInstance.getTableList(-1, -1, null, null, null);
-        assertFalse(res.getServiceEntities().isEmpty());
-        ServiceGroupRO roToDelete = res.getServiceEntities().get(0);
-        assertFalse(roToDelete.getServiceGroupDomains().isEmpty());
-
-        // When
-        List<ParticipantSMLRecord> lst = testInstance.removeServiceGroup(roToDelete);
-        // then
-        assertEquals(roToDelete.getServiceGroupDomains().size(), lst.size());
-        lst.forEach(val -> {
-            assertEquals(SMLStatusEnum.UNREGISTER, val.getStatus());
-        });
-
-    }
 /*
     @Test
     @Transactional
diff --git a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/auth/URLCsrfIgnoreMatcher.java b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/auth/URLCsrfIgnoreMatcher.java
index 2d8051f99d65b1590d95165c985bb8c7baa5c8ab..f8a5fa5290e1cd5ed1d09ea52162e2837f2337c9 100644
--- a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/auth/URLCsrfIgnoreMatcher.java
+++ b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/auth/URLCsrfIgnoreMatcher.java
@@ -39,9 +39,9 @@ public class URLCsrfIgnoreMatcher implements RequestMatcher {
     public boolean matches(HttpServletRequest request) {
         // ignore non ui sites!
         String uri = request.getRequestURI();
-        LOG.info("Test CSRF for uri [{}]", uri);
+        LOG.debug("Test CSRF for uri [{}]", uri);
         if(!StringUtils.startsWithAny(uri,"/ui/","/smp/ui/")) {
-            LOG.info("URL is not part of the UI  [{}]", uri);
+            LOG.debug("URL is not part of the UI  [{}]", uri);
             return false;
         }
         Optional<RegexRequestMatcher> unprotectedMatcher = unprotectedMatcherList.stream().filter(requestMatcher -> requestMatcher.matches(request)).findFirst();
diff --git a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/SMPWebAppConfig.java b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/SMPWebAppConfig.java
index 1d0ec9ed026fb034cbfa27846e90eb7ae9bba5bf..4a915929bf3f6170e8e53bb279178ace1d9775bb 100644
--- a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/SMPWebAppConfig.java
+++ b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/SMPWebAppConfig.java
@@ -37,19 +37,52 @@ import java.util.TimeZone;
 import static org.springframework.core.Ordered.HIGHEST_PRECEDENCE;
 
 /**
- * Created by gutowpa on 11/07/2017.
+ * This is the entry point of the DomiSMP application (beans)configuration/setup.
+ *
+ * The SMPWebAppConfig is initiated from the web.xml.
+ *
+ * The following configurations: ServicesBeansConfiguration, SMPDatabaseConfig, UISecurityConfigurerAdapter, WSSecurityConfigurerAdapter
+ * are configured from the SMPWebAppConfig
+ *
+ * <table border="1">
+ * <tr><th>package</th><th>module</th><th>scan</th></tr>
+ * <tr><td>auth</td><td>smp-server-library/smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>config</td><td>smp-server-library/smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>conversion</td><td>smp-server-library</td><td>ServicesBeansConfiguration</td></tr>
+ * <tr><td>controller</td><td>smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>cron</td><td>smp-server-library</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>data</td><td>smp-server-library</td><td>SMPDatabaseConfig</td></tr>
+ * <tr><td>exceptions</td><td>smp-server-library</td><td>No beans</td></tr>
+ * <tr><td>error</td><td>smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>identifiers</td><td>smp-server-library</td><td>No beans</td></tr>
+ * <tr><td>logging</td><td>smp-server-library</td><td>No beans</td></tr>
+ * <tr><td>monitor</td><td>smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>security</td><td>smp-server-library</td><td>ServicesBeansConfiguration</td></tr>
+ * <tr><td>services</td><td>smp-server-library</td><td>ServicesBeansConfiguration</td></tr>
+ * <tr><td>servlet</td><td>smp-server-library</td><td>No beans</td></tr>
+ * <tr><td>sml</td><td>smp-server-library</td><td>ServicesBeansConfiguration</td></tr>
+ * <tr><td>utils</td><td>smp-server-library</td><td>SMPWebAppConfig</td></tr>
+ * <tr><td>ui</td><td>smp-webapp</td><td>SMPWebAppConfig</td></tr>
+ * </table>
+ *
+ *
+ *  @author gutowpa
+ *  @since 3.0.0
  */
 @Configuration
 @EnableWebMvc
 @ComponentScan(basePackages = {
-        "eu.europa.ec.edelivery.smp",
+        "eu.europa.ec.edelivery.smp.auth",
         "eu.europa.ec.edelivery.smp.config",
+        "eu.europa.ec.edelivery.smp.controllers",
+        "eu.europa.ec.edelivery.smp.error",
         "eu.europa.ec.edelivery.smp.monitor",
         "eu.europa.ec.edelivery.smp.ui",
+        // lib packages
+        "eu.europa.ec.edelivery.smp.utils",
+        "eu.europa.ec.edelivery.smp.cron",
+        // spi properties
         "eu.europa.ec.smp.spi",})
-@Import({GlobalMethodSecurityConfig.class,
-        ServiceErrorControllerAdvice.class,
-        ServicesBeansConfiguration.class})
 public class SMPWebAppConfig implements WebMvcConfigurer {
     private static final Logger LOG = LoggerFactory.getLogger(SMPWebAppConfig.class);
 
diff --git a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/UISecurityConfigurerAdapter.java b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/UISecurityConfigurerAdapter.java
index 80cf9812603e1ea09786db690cfc99a50ce5a2e3..60e61b039107b802c27182838d52cd4462253570 100644
--- a/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/UISecurityConfigurerAdapter.java
+++ b/smp-webapp/src/main/java/eu/europa/ec/edelivery/smp/config/UISecurityConfigurerAdapter.java
@@ -48,7 +48,6 @@ import static eu.europa.ec.edelivery.smp.config.SMPSecurityConstants.SMP_UI_AUTH
 @Order(2)
 @EnableWebSecurity
 @EnableGlobalMethodSecurity(securedEnabled = true, prePostEnabled = true)
-@ComponentScan("eu.europa.ec.edelivery.smp.auth")
 public class UISecurityConfigurerAdapter extends WebSecurityConfigurerAdapter {
 
     private static final Logger LOG = LoggerFactory.getLogger(UISecurityConfigurerAdapter.class);
diff --git a/smp-webapp/src/main/webapp/WEB-INF/web.xml b/smp-webapp/src/main/webapp/WEB-INF/web.xml
index 1bae2541a5eac6cf32ba19785925fe64eba5e848..6c79c4a1adf17575aa19a0606d756aff9bc1f6ea 100644
--- a/smp-webapp/src/main/webapp/WEB-INF/web.xml
+++ b/smp-webapp/src/main/webapp/WEB-INF/web.xml
@@ -41,10 +41,6 @@
             <param-name>contextClass</param-name>
             <param-value>org.springframework.web.context.support.AnnotationConfigWebApplicationContext</param-value>
         </init-param>
-        <init-param>
-            <param-name>contextConfigLocation</param-name>
-            <param-value>eu.europa.ec.edelivery.smp.config.SMPWebAppConfig</param-value>
-        </init-param>
     </servlet>
     <servlet-mapping>
         <servlet-name>smpRestServlet</servlet-name>
@@ -59,8 +55,6 @@
         <param-name>contextConfigLocation</param-name>
         <param-value>
             eu.europa.ec.edelivery.smp.config.EnvironmentProperties;
-            eu.europa.ec.edelivery.smp.config.WSSecurityConfigurerAdapter;
-            eu.europa.ec.edelivery.smp.config.UISecurityConfigurerAdapter;
             eu.europa.ec.edelivery.smp.config.SMPWebAppConfig;
         </param-value>
     </context-param>