commit e1b24c893dd4b9b3ef4d869e58b079b017f8e0ad
Author: stepanekp <1stepanekpetr@gmail.com>
Date:   Sat Apr 9 00:37:02 2022 +0200

    Project structure changes for Docker

diff --git a/Dockerfile b/Dockerfile
index da8b6b6..b6f4045 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -3,11 +3,15 @@ FROM maven:3.6.3-jdk-11-slim AS build
 RUN mkdir -p /workspace
 WORKDIR /workspace
 COPY pom.xml /workspace
+#RUN mvn -f pom.xml dependency:resolve
 COPY src /workspace/src
 RUN mvn -f pom.xml clean package -Dmaven.test.skip=true
+COPY data /workspace/data
 
 ### STAGE 2: RUN ###
 FROM adoptopenjdk:11-jre-hotspot
 COPY --from=build /workspace/target/*.war app.war
+COPY --from=build /workspace/data /data
+
 EXPOSE 8080
 ENTRYPOINT ["java","-jar","app.war"]
diff --git a/data/configurations/Default.json b/data/configurations/Default.json
new file mode 100644
index 0000000..9531ca4
--- /dev/null
+++ b/data/configurations/Default.json
@@ -0,0 +1,111 @@
+{
+    "configuration": [
+        {
+            "antiPattern": "TooLongSprint",
+            "thresholds": [
+                {
+                    "thresholdName": "maxIterationLength",
+                    "value": "21"
+                },
+                {
+                    "thresholdName": "maxNumberOfTooLongIterations",
+                    "value": "0"
+                }
+            ]
+        },
+        {
+            "antiPattern": "VaryingSprintLength",
+            "thresholds": [
+                {
+                    "thresholdName": "maxDaysDifference",
+                    "value": "7"
+                },
+                {
+                    "thresholdName": "maxIterationChanged",
+                    "value": "1"
+                }
+            ]
+        },
+        {
+            "antiPattern": "BusinessAsUsual",
+            "thresholds": [
+                {
+                    "thresholdName": "divisionOfIterationsWithRetrospective",
+                    "value": "66.66f"
+                },
+                {
+                    "thresholdName": "searchSubstringsWithRetrospective",
+                    "value": "%retr%||%revi%||%week%scrum%"
+                }
+            ]
+        },
+        {
+            "antiPattern": "SpecifyNothing",
+            "thresholds": [
+                {
+                    "thresholdName": "minNumberOfWikiPagesWithSpecification",
+                    "value": "1"
+                },
+                {
+                    "thresholdName": "minNumberOfActivitiesWithSpecification",
+                    "value": "1"
+                },
+                {
+                    "thresholdName": "minAvgLengthOfActivityDescription",
+                    "value": "150"
+                },
+                {
+                    "thresholdName": "searchSubstringsWithProjectSpecification",
+                    "value": "%dsp%||%specifikace%||%specification%||%vize%proj%||%vize%produ%"
+                }
+            ]
+        },
+        {
+            "antiPattern": "RoadToNowhere",
+            "thresholds": [
+                {
+                    "thresholdName": "minNumberOfWikiPagesWithProjectPlan",
+                    "value": "1"
+                },
+                {
+                    "thresholdName": "minNumberOfActivitiesWithProjectPlan",
+                    "value": "1"
+                },
+                {
+                    "thresholdName": "searchSubstringsWithProjectPlan",
+                    "value": "%plán projektu%||%project plan%||%plan project%||%projektový plán%"
+                }
+            ]
+        },
+        {
+            "antiPattern": "LongOrNonExistentFeedbackLoops",
+            "thresholds": [
+                {
+                    "thresholdName": "divisionOfIterationsWithFeedbackLoop",
+                    "value": "50.00f"
+                },
+                {
+                    "thresholdName": "maxGapBetweenFeedbackLoopRate",
+                    "value": "2f"
+                },
+                {
+                    "thresholdName": "searchSubstringsWithFeedbackLoop",
+                    "value": "%schůz%zákazník%||%předvedení%zákazník%||%zákazn%demo%||%schůz%zadavat%||%inform%schůz%||%zákazn%||%zadavatel%"
+                }
+            ]
+        },
+        {
+            "antiPattern": "NinetyNinetyRule",
+            "thresholds": [
+                {
+                    "thresholdName": "maxDivisionRange",
+                    "value": "1.25f"
+                },
+                {
+                    "thresholdName": "maxBadDivisionLimit",
+                    "value": "2"
+                }
+            ]
+        }
+    ]
+}
\ No newline at end of file
diff --git a/data/operationalizations/BusinessAsUsual.html b/data/operationalizations/BusinessAsUsual.html
new file mode 100644
index 0000000..29f446a
--- /dev/null
+++ b/data/operationalizations/BusinessAsUsual.html
@@ -0,0 +1 @@
+test3
\ No newline at end of file
diff --git a/data/operationalizations/LongOrNonExistentFeedbackLoops.html b/data/operationalizations/LongOrNonExistentFeedbackLoops.html
new file mode 100644
index 0000000..64ba643
--- /dev/null
+++ b/data/operationalizations/LongOrNonExistentFeedbackLoops.html
@@ -0,0 +1 @@
+test6
\ No newline at end of file
diff --git a/data/operationalizations/NinetyNinetyRule.html b/data/operationalizations/NinetyNinetyRule.html
new file mode 100644
index 0000000..60f6c48
--- /dev/null
+++ b/data/operationalizations/NinetyNinetyRule.html
@@ -0,0 +1 @@
+test7
\ No newline at end of file
diff --git a/data/operationalizations/RoadToNowhere.html b/data/operationalizations/RoadToNowhere.html
new file mode 100644
index 0000000..4f1bd33
--- /dev/null
+++ b/data/operationalizations/RoadToNowhere.html
@@ -0,0 +1 @@
+test5
\ No newline at end of file
diff --git a/data/operationalizations/SpecifyNothing.html b/data/operationalizations/SpecifyNothing.html
new file mode 100644
index 0000000..7475221
--- /dev/null
+++ b/data/operationalizations/SpecifyNothing.html
@@ -0,0 +1 @@
+test4
\ No newline at end of file
diff --git a/data/operationalizations/TooLongSprint.html b/data/operationalizations/TooLongSprint.html
new file mode 100644
index 0000000..3f808a3
--- /dev/null
+++ b/data/operationalizations/TooLongSprint.html
@@ -0,0 +1,35 @@
+<div><h1>This is h1</h1></div>
+<div><b>Lorem </b>ipsum dolor sit amet, consectetuer adipiscing elit. <code>Nulla est.</code> </div>
+<div>Etiam commodo dui eget wisi. <b>Fusce tellus </b>odio, dapibus <span style="color: rgb(33, 37, 41); font-family: SFMono-Regular, Menlo, Monaco, Consolas, " liberation="" mono",="" "courier="" new",="" monospace;="" font-size:="" 14px;"="">id</span>
+    <pre>fermentum</pre>
+    <pre>test</pre>
+    <pre>suscipit id erat. </pre>
+</div>
+<div><b></b>
+    <pre><b>Fusce</b><span style="font-size: 1rem;"> aliquam vestibulum ipsum. Nullam sit amet magna in </span><u style="font-size: 1rem;">magna</u><span style="font-size: 1rem;"> gravida vehicula. </span></pre>
+</div>
+<div><i>Ut tempus purus at lorem.</i> </div><div><br></div>
+<div></div>
+<div><br></div>
+<div>
+    <ul>
+        <li>Lorem ipsum</li>
+        <li>Lorem ipsum</li>
+        <li>Lorem ipsum</li>
+    </ul>
+    <div><a href="https://www.fav.zcu.cz/cs/">https://www.fav.zcu.cz/cs/</a><br></div>
+</div>
+<div><br></div>
+<div><img src="/operationalizations/images/test2.png"><br></div>
+<div><br></div><h2>This is h2</h2><h3>This is h3</h3>
+<div>
+    <pre>Sed</pre>
+    ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, 
+</div>
+<div>totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt
+    <pre>explicabo. </pre>
+</div>
+<div>Sed vel lectus. Donec odio tempus molestie, porttitor ut, iaculis quis, sem. </div>
+<div><br></div>
+<div><img src="/operationalizations/images/testImage.png"><br></div>
+<div><br></div>
\ No newline at end of file
diff --git a/data/operationalizations/VaryingSprintLength.html b/data/operationalizations/VaryingSprintLength.html
new file mode 100644
index 0000000..d606037
--- /dev/null
+++ b/data/operationalizations/VaryingSprintLength.html
@@ -0,0 +1 @@
+test2
\ No newline at end of file
diff --git a/docker-compose.yml b/docker-compose.yml
index a6ae302..33ce06a 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -48,3 +48,6 @@ services:
       SPRING_DATASOURCE_URL: jdbc:mysql://mysql-db:3306/spade
       SPRING_DATASOURCE_USERNAME: root
       SPRING_DATASOURCE_PASSWORD: testtest
+      ACCOUNT_USER_NAME: 
+      ACCOUNT_USER_PASSWORD:
+      DATA_PATH: /data/
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/controller/AppController.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/controller/AppController.java
index 37178db..7cf91bb 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/controller/AppController.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/controller/AppController.java
@@ -22,7 +22,6 @@ import org.springframework.web.bind.annotation.*;
 import org.springframework.web.multipart.MultipartFile;
 import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 
-import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpSession;
 import java.io.BufferedWriter;
 import java.io.File;
@@ -30,8 +29,6 @@ import java.io.FileWriter;
 import java.nio.file.Files;
 import java.time.LocalTime;
 import java.time.format.DateTimeFormatter;
-import java.util.ArrayList;
-import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
@@ -106,6 +103,7 @@ public class AppController {
         String currentConfigurationName = configurationGetFromSession(session);
         model.addAttribute("antiPattern", antiPatternService.getAntiPatternById(id).getAntiPatternModel());
         model.addAttribute("description", antiPatternService.getDescriptionFromCatalogue(id));
+        model.addAttribute("operationalizationText", antiPatternService.getOperationalizationText(antiPatternService.getAntiPatternById(id).getAntiPatternModel().getName()));
         model.addAttribute("configurations", configurationService.getConfigurationByName(currentConfigurationName));
         return "anti-pattern";
     }
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/model/AntiPattern.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/model/AntiPattern.java
index a99b2e9..3847b76 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/model/AntiPattern.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/model/AntiPattern.java
@@ -101,18 +101,6 @@ public class AntiPattern {
         return Constants.ANTI_PATTERN_CATALOGUE_URL + this.catalogueFileName;
     }
 
-    public String getOperationalizationText() {
-        String myPath = new FileSystemResource("").getFile().getAbsolutePath() + "\\src\\main\\webapp\\operationalizations\\" + this.getName() + ".html";
-        String content = null;
-        try {
-            content = new String ( Files.readAllBytes(Paths.get(myPath)));
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-
-        return content;
-    }
-
     @Override
     public String toString() {
         return "AntiPattern{" +
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/AntiPatternRepository.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/AntiPatternRepository.java
index 8635ca2..a5ff74e 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/AntiPatternRepository.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/AntiPatternRepository.java
@@ -8,6 +8,8 @@ import cz.zcu.fav.kiv.antipatterndetectionapp.utils.JsonParser;
 import org.reflections.Reflections;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.core.io.FileSystemResource;
 import org.springframework.stereotype.Component;
 import org.springframework.web.context.ServletContextAware;
 
@@ -27,12 +29,17 @@ public class AntiPatternRepository implements ServletContextAware {
 
     private static final String QUERY_DIR = "/queries/";
     private static final String AP_DIR = "/antipatterns/";
-    private static final String OPERATIONALIZATION_DIR = "/operationalizations/";
-    private static final String OPERATIONALIZATION_IMG_DIR = "/operationalizations/images/";
+    private final String OPERATIONALIZATION_DIR;
+    private final String OPERATIONALIZATION_IMG_DIR;
     private final Logger LOGGER = LoggerFactory.getLogger(AntiPatternRepository.class);
     private ServletContext servletContext;
     private Map<Long, AntiPatternDetector> antiPatternDetectors;
 
+
+    public AntiPatternRepository(@Value("${DATA_PATH}")String dir){
+        this.OPERATIONALIZATION_DIR = dir + "operationalizations/";
+        this.OPERATIONALIZATION_IMG_DIR = dir + "operationalizations/images/";
+    }
     /**
      * This method load all queries from files for each AP.
      *
@@ -264,7 +271,7 @@ public class AntiPatternRepository implements ServletContextAware {
 
     public String getOperationalizationDirPathName(){
         try {
-            return servletContext.getResource(OPERATIONALIZATION_DIR).getFile();
+            return new FileSystemResource(OPERATIONALIZATION_DIR).getFile().getAbsolutePath();
         } catch (Exception e) {
             e.printStackTrace();
         }
@@ -273,7 +280,7 @@ public class AntiPatternRepository implements ServletContextAware {
 
     public String getOperationalizationImgDirFileName(){
         try {
-            return servletContext.getResource(OPERATIONALIZATION_IMG_DIR).getFile();
+            return new FileSystemResource(OPERATIONALIZATION_IMG_DIR).getFile().getAbsolutePath();
         } catch (Exception e) {
             e.printStackTrace();
         }
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/ConfigurationRepository.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/ConfigurationRepository.java
index e734bad..254991d 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/ConfigurationRepository.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/repository/ConfigurationRepository.java
@@ -11,32 +11,28 @@ import cz.zcu.fav.kiv.antipatterndetectionapp.utils.JsonParser;
 import cz.zcu.fav.kiv.antipatterndetectionapp.utils.Utils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.core.io.FileSystemResource;
 import org.springframework.stereotype.Component;
-import org.springframework.web.context.ServletContextAware;
 
-import javax.servlet.ServletContext;
 import java.io.*;
-import java.net.URL;
-import java.nio.file.Paths;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 @Component
-public class ConfigurationRepository implements ServletContextAware {
+public class ConfigurationRepository {
 
-    private ServletContext servletContext;
-    private static final String CONFIGURATION_DIR = "/configurations/";
+    private final String CONFIGURATION_DIR;
     private final Logger LOGGER = LoggerFactory.getLogger(ConfigurationRepository.class);
 
     // Map<ConfigurationName, Map<AntiPatternName, Map<ThresholdName, value>>>
     public Map<String, Map<String, Map<String, String>>> allConfigurations;
 
-    @Override
-    public void setServletContext(ServletContext servletContext) {
-        this.servletContext = servletContext;
-
+    /**
+     * Constructor to set configurations folder and start loading
+     * @param dir
+     */
+    public ConfigurationRepository(@Value("${DATA_PATH}")String dir){
+        this.CONFIGURATION_DIR = dir + "configurations/";
         loadConfigurations();
     }
 
@@ -50,8 +46,7 @@ public class ConfigurationRepository implements ServletContextAware {
 
         File configurationsFolder = null;
         try {
-            URL url = servletContext.getResource(CONFIGURATION_DIR);
-            configurationsFolder = new File(url.getFile());
+            configurationsFolder = new File(new FileSystemResource(CONFIGURATION_DIR).getFile().getAbsolutePath());
         } catch (Exception e) {
             LOGGER.error("Cannot access folder with configurations " + CONFIGURATION_DIR);
             return;
@@ -151,10 +146,11 @@ public class ConfigurationRepository implements ServletContextAware {
 
         root.set("configuration", array);
 
+        File configurationFile = null;
         try {
-            String uri = servletContext.getResource(CONFIGURATION_DIR).toURI() + configurationName + ".json";
+            configurationFile = new File(new FileSystemResource(CONFIGURATION_DIR + configurationName + ".json").getFile().getAbsolutePath());
 
-            JsonParser.getObjectWriter().writeValue(Paths.get(new URL(uri).toURI()).toFile(), root);
+            JsonParser.getObjectWriter().writeValue(configurationFile, root);
         } catch (Exception e) {
             LOGGER.error("Cannot write configuration to the file");
         }
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternService.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternService.java
index 452c23b..306662b 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternService.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternService.java
@@ -44,6 +44,8 @@ public interface AntiPatternService {
      */
     String getDescriptionFromCatalogue(long id);
 
+    String getOperationalizationText(String fileName);
+
     String getOperationalizationFilePath(String antiPatternName);
 
     String getOperationalizationImageFilePath(String imageName);
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternServiceImpl.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternServiceImpl.java
index fd85708..5e68fc7 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternServiceImpl.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/AntiPatternServiceImpl.java
@@ -1,6 +1,5 @@
 package cz.zcu.fav.kiv.antipatterndetectionapp.service;
 
-import com.fasterxml.jackson.databind.JsonNode;
 import cz.zcu.fav.kiv.antipatterndetectionapp.Constants;
 import cz.zcu.fav.kiv.antipatterndetectionapp.detecting.detectors.AntiPatternDetector;
 import cz.zcu.fav.kiv.antipatterndetectionapp.model.AntiPattern;
@@ -12,6 +11,9 @@ import org.jsoup.Jsoup;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Paths;
 import java.util.*;
 
 
@@ -165,13 +167,26 @@ public class AntiPatternServiceImpl implements AntiPatternService {
         return resultDescription.trim();
     }
 
+    @Override
+    public String getOperationalizationText(String fileName){
+        String filePath = getOperationalizationFilePath(fileName);
+
+        String content = null;
+        try {
+            content = new String (Files.readAllBytes(Paths.get(filePath)));
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+        return content;
+    }
+
     @Override
     public String getOperationalizationFilePath(String antiPatternName){
-        return antiPatternRepository.getOperationalizationDirPathName() + antiPatternName + ".html";
+        return antiPatternRepository.getOperationalizationDirPathName() + "/" + antiPatternName + ".html";
     }
 
     @Override
     public String getOperationalizationImageFilePath(String imageName){
-        return antiPatternRepository.getOperationalizationImgDirFileName() + imageName;
+        return antiPatternRepository.getOperationalizationImgDirFileName() + "/" + imageName;
     }
 }
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/UserAccountServiceImpl.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/UserAccountServiceImpl.java
index 56480b3..d8016ea 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/UserAccountServiceImpl.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/service/UserAccountServiceImpl.java
@@ -1,6 +1,8 @@
 package cz.zcu.fav.kiv.antipatterndetectionapp.service;
 
 import cz.zcu.fav.kiv.antipatterndetectionapp.controller.AppController;
+import cz.zcu.fav.kiv.antipatterndetectionapp.spring.ApplicationProperties;
+import cz.zcu.fav.kiv.antipatterndetectionapp.spring.SpringApplicationContext;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.stereotype.Service;
@@ -11,34 +13,18 @@ import java.util.Properties;
 @Service
 public class UserAccountServiceImpl implements UserAccountService{
 
-    private final String accountDetailsFile = "account.properties";
-
     private final Logger LOGGER = LoggerFactory.getLogger(AppController.class);
 
     @Override
     public boolean checkCredentials(String username, String password) {
-        try (InputStream input = this.getClass().getClassLoader().getResourceAsStream(accountDetailsFile)) {
-
-            Properties prop = new Properties();
-
-            if (input == null) {
-                LOGGER.error("Unable to open file: " + accountDetailsFile);
-                return false;
-            }
-
-            // load a properties file
-            prop.load(input);
-
-            //get the property value and print it out
-            String accountUsername = prop.getProperty("account.user.name");
-            String accountPassword = prop.getProperty("account.user.password");
+        ApplicationProperties applicationProperties = ((ApplicationProperties) SpringApplicationContext.getContext()
+                .getBean("applicationProperties"));
 
-            if(username.equals(accountUsername) && password.equals(accountPassword))
-                return true;
+        String accountName = applicationProperties.getAccountUserName();
+        String accountPass = applicationProperties.getAccountUserPassword();
 
-        } catch (Exception ex) {
-            ex.printStackTrace();
-        }
+        if(username.equals(accountName) && password.equals(accountPass))
+            return true;
 
         return false;
     }
diff --git a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/spring/ApplicationProperties.java b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/spring/ApplicationProperties.java
index eb56f42..964591e 100644
--- a/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/spring/ApplicationProperties.java
+++ b/src/main/java/cz/zcu/fav/kiv/antipatterndetectionapp/spring/ApplicationProperties.java
@@ -21,4 +21,12 @@ public class ApplicationProperties {
     public String getDataSourcePassword() {
         return environment.getProperty("spring.datasource.password");
     }
+
+    public String getAccountUserName() {
+        return environment.getProperty("account.user.name");
+    }
+
+    public String getAccountUserPassword() {
+        return environment.getProperty("account.user.password");
+    }
 }
diff --git a/src/main/resources/account.properties b/src/main/resources/account.properties
deleted file mode 100644
index 0b82750..0000000
--- a/src/main/resources/account.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-account.user.name=
-account.user.password=
\ No newline at end of file
diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties
index 525a1ae..21935ec 100644
--- a/src/main/resources/application.properties
+++ b/src/main/resources/application.properties
@@ -1,3 +1,5 @@
 spring.datasource.url=jdbc:mysql://localhost:3306/spade
 spring.datasource.username=root
 spring.datasource.password=
+account.user.name=
+account.user.password=
diff --git a/src/main/webapp/WEB-INF/templates/anti-pattern.html b/src/main/webapp/WEB-INF/templates/anti-pattern.html
index 8ec16a1..724f469 100644
--- a/src/main/webapp/WEB-INF/templates/anti-pattern.html
+++ b/src/main/webapp/WEB-INF/templates/anti-pattern.html
@@ -128,7 +128,7 @@
                     <input type="file" id="imageInput" name="fileupload" hidden>
                     <button id="upload-button" onclick="uploadFile()" hidden></button>
                 </div>
-                <div class="content form-control" id="content-area" onload="getContent()" th:utext="${antiPattern.getOperationalizationText()}"></div>
+                <div class="content form-control" id="content-area" onload="getContent()" th:utext="${operationalizationText}"></div>
             </div>
             <form id="operationalization-form" action="#" th:action="@{/anti-patterns/} + ${antiPattern.id} + @{/operationalization}" th:object="${antiPattern}" method="post">
                 <div class="save-operationalization-button-container">
diff --git a/src/main/webapp/configurations/Default.json b/src/main/webapp/configurations/Default.json
deleted file mode 100644
index 9531ca4..0000000
--- a/src/main/webapp/configurations/Default.json
+++ /dev/null
@@ -1,111 +0,0 @@
-{
-    "configuration": [
-        {
-            "antiPattern": "TooLongSprint",
-            "thresholds": [
-                {
-                    "thresholdName": "maxIterationLength",
-                    "value": "21"
-                },
-                {
-                    "thresholdName": "maxNumberOfTooLongIterations",
-                    "value": "0"
-                }
-            ]
-        },
-        {
-            "antiPattern": "VaryingSprintLength",
-            "thresholds": [
-                {
-                    "thresholdName": "maxDaysDifference",
-                    "value": "7"
-                },
-                {
-                    "thresholdName": "maxIterationChanged",
-                    "value": "1"
-                }
-            ]
-        },
-        {
-            "antiPattern": "BusinessAsUsual",
-            "thresholds": [
-                {
-                    "thresholdName": "divisionOfIterationsWithRetrospective",
-                    "value": "66.66f"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithRetrospective",
-                    "value": "%retr%||%revi%||%week%scrum%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "SpecifyNothing",
-            "thresholds": [
-                {
-                    "thresholdName": "minNumberOfWikiPagesWithSpecification",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minNumberOfActivitiesWithSpecification",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minAvgLengthOfActivityDescription",
-                    "value": "150"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithProjectSpecification",
-                    "value": "%dsp%||%specifikace%||%specification%||%vize%proj%||%vize%produ%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "RoadToNowhere",
-            "thresholds": [
-                {
-                    "thresholdName": "minNumberOfWikiPagesWithProjectPlan",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minNumberOfActivitiesWithProjectPlan",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithProjectPlan",
-                    "value": "%plán projektu%||%project plan%||%plan project%||%projektový plán%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "LongOrNonExistentFeedbackLoops",
-            "thresholds": [
-                {
-                    "thresholdName": "divisionOfIterationsWithFeedbackLoop",
-                    "value": "50.00f"
-                },
-                {
-                    "thresholdName": "maxGapBetweenFeedbackLoopRate",
-                    "value": "2f"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithFeedbackLoop",
-                    "value": "%schůz%zákazník%||%předvedení%zákazník%||%zákazn%demo%||%schůz%zadavat%||%inform%schůz%||%zákazn%||%zadavatel%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "NinetyNinetyRule",
-            "thresholds": [
-                {
-                    "thresholdName": "maxDivisionRange",
-                    "value": "1.25f"
-                },
-                {
-                    "thresholdName": "maxBadDivisionLimit",
-                    "value": "2"
-                }
-            ]
-        }
-    ]
-}
\ No newline at end of file
diff --git a/src/main/webapp/configurations/MyConfig.json b/src/main/webapp/configurations/MyConfig.json
deleted file mode 100644
index 9531ca4..0000000
--- a/src/main/webapp/configurations/MyConfig.json
+++ /dev/null
@@ -1,111 +0,0 @@
-{
-    "configuration": [
-        {
-            "antiPattern": "TooLongSprint",
-            "thresholds": [
-                {
-                    "thresholdName": "maxIterationLength",
-                    "value": "21"
-                },
-                {
-                    "thresholdName": "maxNumberOfTooLongIterations",
-                    "value": "0"
-                }
-            ]
-        },
-        {
-            "antiPattern": "VaryingSprintLength",
-            "thresholds": [
-                {
-                    "thresholdName": "maxDaysDifference",
-                    "value": "7"
-                },
-                {
-                    "thresholdName": "maxIterationChanged",
-                    "value": "1"
-                }
-            ]
-        },
-        {
-            "antiPattern": "BusinessAsUsual",
-            "thresholds": [
-                {
-                    "thresholdName": "divisionOfIterationsWithRetrospective",
-                    "value": "66.66f"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithRetrospective",
-                    "value": "%retr%||%revi%||%week%scrum%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "SpecifyNothing",
-            "thresholds": [
-                {
-                    "thresholdName": "minNumberOfWikiPagesWithSpecification",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minNumberOfActivitiesWithSpecification",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minAvgLengthOfActivityDescription",
-                    "value": "150"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithProjectSpecification",
-                    "value": "%dsp%||%specifikace%||%specification%||%vize%proj%||%vize%produ%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "RoadToNowhere",
-            "thresholds": [
-                {
-                    "thresholdName": "minNumberOfWikiPagesWithProjectPlan",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "minNumberOfActivitiesWithProjectPlan",
-                    "value": "1"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithProjectPlan",
-                    "value": "%plán projektu%||%project plan%||%plan project%||%projektový plán%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "LongOrNonExistentFeedbackLoops",
-            "thresholds": [
-                {
-                    "thresholdName": "divisionOfIterationsWithFeedbackLoop",
-                    "value": "50.00f"
-                },
-                {
-                    "thresholdName": "maxGapBetweenFeedbackLoopRate",
-                    "value": "2f"
-                },
-                {
-                    "thresholdName": "searchSubstringsWithFeedbackLoop",
-                    "value": "%schůz%zákazník%||%předvedení%zákazník%||%zákazn%demo%||%schůz%zadavat%||%inform%schůz%||%zákazn%||%zadavatel%"
-                }
-            ]
-        },
-        {
-            "antiPattern": "NinetyNinetyRule",
-            "thresholds": [
-                {
-                    "thresholdName": "maxDivisionRange",
-                    "value": "1.25f"
-                },
-                {
-                    "thresholdName": "maxBadDivisionLimit",
-                    "value": "2"
-                }
-            ]
-        }
-    ]
-}
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/BusinessAsUsual.html b/src/main/webapp/operationalizations/BusinessAsUsual.html
deleted file mode 100644
index 29f446a..0000000
--- a/src/main/webapp/operationalizations/BusinessAsUsual.html
+++ /dev/null
@@ -1 +0,0 @@
-test3
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/LongOrNonExistentFeedbackLoops.html b/src/main/webapp/operationalizations/LongOrNonExistentFeedbackLoops.html
deleted file mode 100644
index 64ba643..0000000
--- a/src/main/webapp/operationalizations/LongOrNonExistentFeedbackLoops.html
+++ /dev/null
@@ -1 +0,0 @@
-test6
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/NinetyNinetyRule.html b/src/main/webapp/operationalizations/NinetyNinetyRule.html
deleted file mode 100644
index 60f6c48..0000000
--- a/src/main/webapp/operationalizations/NinetyNinetyRule.html
+++ /dev/null
@@ -1 +0,0 @@
-test7
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/RoadToNowhere.html b/src/main/webapp/operationalizations/RoadToNowhere.html
deleted file mode 100644
index 4f1bd33..0000000
--- a/src/main/webapp/operationalizations/RoadToNowhere.html
+++ /dev/null
@@ -1 +0,0 @@
-test5
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/SpecifyNothing.html b/src/main/webapp/operationalizations/SpecifyNothing.html
deleted file mode 100644
index 7475221..0000000
--- a/src/main/webapp/operationalizations/SpecifyNothing.html
+++ /dev/null
@@ -1 +0,0 @@
-test4
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/TooLongSprint.html b/src/main/webapp/operationalizations/TooLongSprint.html
deleted file mode 100644
index 3f3e0e1..0000000
--- a/src/main/webapp/operationalizations/TooLongSprint.html
+++ /dev/null
@@ -1 +0,0 @@
-<div><h1>This is h1</h1></div><div><b>Lorem </b>ipsum dolor sit amet, consectetuer adipiscing elit. <code>Nulla est.</code> </div><div>Etiam commodo dui eget wisi. <b>Fusce tellus </b>odio, dapibus <span style="color: rgb(33, 37, 41); font-family: SFMono-Regular, Menlo, Monaco, Consolas, " liberation="" mono",="" "courier="" new",="" monospace;="" font-size:="" 14px;"="">id</span><pre>fermentum</pre><pre>test</pre><pre>suscipit id erat. </pre></div><div><b></b><pre><b>Fusce</b><span style="font-size: 1rem;"> aliquam vestibulum ipsum. Nullam sit amet magna in </span><u style="font-size: 1rem;">magna</u><span style="font-size: 1rem;"> gravida vehicula. </span></pre></div><div><i>Ut tempus purus at lorem.</i> </div><div></div><div><br></div><div><ul><li>Lorem ipsum</li><li>Lorem ipsum</li><li>Lorem ipsum</li></ul><div><a href="https://www.fav.zcu.cz/cs/">https://www.fav.zcu.cz/cs/</a><br></div></div><div><br></div><div><img src="/operationalizations/images/test2.png"><br></div><div><br></div><h2>This is h2</h2><h3>This is h3</h3><div><pre>Sed</pre> ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, </div><div>totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt <pre>explicabo. </pre></div><div>Sed vel lectus. Donec odio tempus molestie, porttitor ut, iaculis quis, sem. </div><div><br></div><div><img src="/operationalizations/images/testImage.png"><br></div><div><br></div>
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/VaryingSprintLength.html b/src/main/webapp/operationalizations/VaryingSprintLength.html
deleted file mode 100644
index d606037..0000000
--- a/src/main/webapp/operationalizations/VaryingSprintLength.html
+++ /dev/null
@@ -1 +0,0 @@
-test2
\ No newline at end of file
diff --git a/src/main/webapp/operationalizations/images/test2.png b/src/main/webapp/operationalizations/images/test2.png
deleted file mode 100644
index 6768f71..0000000
Binary files a/src/main/webapp/operationalizations/images/test2.png and /dev/null differ
diff --git a/src/main/webapp/operationalizations/images/testImage.png b/src/main/webapp/operationalizations/images/testImage.png
deleted file mode 100644
index f6c3d93..0000000
Binary files a/src/main/webapp/operationalizations/images/testImage.png and /dev/null differ
