diff --git a/.docs/.swagger/api-metadata.yaml b/.docs/.swagger/api-metadata.yaml
index bcfa22b1e63f10a2899d354aba0c1e7d50caaa46..0e789535b8109d53d145ff20db56eb5d776dd0c3 100644
--- a/.docs/.swagger/api-metadata.yaml
+++ b/.docs/.swagger/api-metadata.yaml
@@ -38,12 +38,6 @@ paths:
           type: integer
           format: int64
       responses:
-        "409":
-          description: Query store failed to query table history
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "400":
           description: Table history query is malformed
           content:
@@ -56,6 +50,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "404":
+          description: "Table, database or user could not be found"
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: Find table history successfully
           content:
@@ -64,8 +64,8 @@ paths:
                 type: array
                 items:
                   $ref: '#/components/schemas/TableHistoryDto'
-        "404":
-          description: "Table, database or user could not be found"
+        "409":
+          description: Query store failed to query table history
           content:
             application/json:
               schema:
@@ -92,12 +92,6 @@ paths:
           type: integer
           format: int64
       responses:
-        "409":
-          description: Query store failed to query table history
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "400":
           description: Table history query is malformed
           content:
@@ -110,6 +104,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "404":
+          description: "Table, database or user could not be found"
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: Find table history successfully
           content:
@@ -118,8 +118,8 @@ paths:
                 type: array
                 items:
                   $ref: '#/components/schemas/TableHistoryDto'
-        "404":
-          description: "Table, database or user could not be found"
+        "409":
+          description: Query store failed to query table history
           content:
             application/json:
               schema:
@@ -178,12 +178,6 @@ paths:
         schema:
           type: string
       responses:
-        "422":
-          description: Could not import csv via sidecar
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "400":
           description: Table data is malformed or image is not supported
           content:
@@ -196,18 +190,24 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Get table data successfully
+          content:
+            '*/*':
+              schema:
+                $ref: '#/components/schemas/QueryResultDto'
         "403":
           description: Access to the database is forbidden
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Get table data successfully
+        "422":
+          description: Could not import csv via sidecar
           content:
-            '*/*':
+            application/json:
               schema:
-                $ref: '#/components/schemas/QueryResultDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -237,20 +237,14 @@ paths:
               $ref: '#/components/schemas/TableCsvDto'
         required: true
       responses:
-        "404":
-          description: Table or database could not be found
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "202":
           description: Inserted data successfully
           content:
             '*/*':
               schema:
                 type: object
-        "400":
-          description: Insert table data is malformed
+        "404":
+          description: Table or database could not be found
           content:
             application/json:
               schema:
@@ -261,6 +255,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "400":
+          description: Insert table data is malformed
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -363,12 +363,6 @@ paths:
         schema:
           type: string
       responses:
-        "422":
-          description: Could not import csv via sidecar
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "400":
           description: Table data is malformed or image is not supported
           content:
@@ -381,18 +375,24 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Get table data successfully
+          content:
+            '*/*':
+              schema:
+                $ref: '#/components/schemas/QueryResultDto'
         "403":
           description: Access to the database is forbidden
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Get table data successfully
+        "422":
+          description: Could not import csv via sidecar
           content:
-            '*/*':
+            application/json:
               schema:
-                $ref: '#/components/schemas/QueryResultDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -410,12 +410,6 @@ paths:
           type: string
           format: uuid
       responses:
-        "403":
-          description: Find user is not permitted
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: User was not found
           content:
@@ -428,6 +422,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/UserDto'
+        "403":
+          description: Find user is not permitted
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -450,26 +450,26 @@ paths:
               $ref: '#/components/schemas/UserUpdateDto'
         required: true
       responses:
-        "405":
-          description: Foreign user modification
+        "404":
+          description: User attribute was not found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Modify user query is malformed
+        "403":
+          description: Modify user is not permitted
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: User attribute was not found
+        "405":
+          description: Foreign user modification
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Modify user is not permitted
+        "400":
+          description: Modify user query is malformed
           content:
             application/json:
               schema:
@@ -503,30 +503,30 @@ paths:
               $ref: '#/components/schemas/UserThemeSetDto'
         required: true
       responses:
-        "405":
-          description: Foreign user modification
+        "403":
+          description: Modify user is not permitted
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Modify user is not permitted
+        "404":
+          description: User or user attribute was not found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Modified user theme
+        "405":
+          description: Foreign user modification
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/UserDto'
-        "404":
-          description: User or user attribute was not found
+                $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Modified user theme
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                $ref: '#/components/schemas/UserDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -550,8 +550,8 @@ paths:
               $ref: '#/components/schemas/UserPasswordDto'
         required: true
       responses:
-        "403":
-          description: Modify is not allowed
+        "503":
+          description: Authentication service does not respond
           content:
             application/json:
               schema:
@@ -562,24 +562,24 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "405":
-          description: Foreign user modification
+        "202":
+          description: Modified user password
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Authentication service does not respond
+                $ref: '#/components/schemas/UserDto'
+        "405":
+          description: Foreign user modification
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Modified user password
+        "403":
+          description: Modify is not allowed
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/UserDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -597,18 +597,18 @@ paths:
           type: integer
           format: int64
       responses:
-        "200":
-          description: Find one ontology
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/OntologyDto'
         "404":
           description: Could not find ontology
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "200":
+          description: Find one ontology
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/OntologyDto'
     put:
       tags:
       - ontology-endpoint
@@ -628,18 +628,18 @@ paths:
               $ref: '#/components/schemas/OntologyModifyDto'
         required: true
       responses:
-        "202":
-          description: Updated ontology successfully
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/OntologyDto'
         "404":
           description: Could not find ontology
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Updated ontology successfully
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/OntologyDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -656,16 +656,16 @@ paths:
           type: integer
           format: int64
       responses:
-        "202":
-          description: Deleted ontology successfully
-          content:
-            application/json: {}
         "404":
           description: Could not find ontology
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Deleted ontology successfully
+          content:
+            application/json: {}
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -714,18 +714,18 @@ paths:
               $ref: '#/components/schemas/BannerMessageUpdateDto'
         required: true
       responses:
-        "404":
-          description: Could not find message
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "202":
           description: Updated message
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/BannerMessageBriefDto'
+        "404":
+          description: Could not find message
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -859,12 +859,6 @@ paths:
               $ref: '#/components/schemas/DatabaseModifyVisibilityDto'
         required: true
       responses:
-        "202":
-          description: Visibility modified successfully
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/DatabaseDto'
         "403":
           description: Visibility modification is not permitted
           content:
@@ -877,6 +871,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Visibility modified successfully
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/DatabaseDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -900,24 +900,24 @@ paths:
               $ref: '#/components/schemas/DatabaseTransferDto'
         required: true
       responses:
-        "202":
-          description: Transfer of ownership was successful
+        "403":
+          description: Transfer of ownership is not permitted
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/DatabaseDto'
+                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: Database or user could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Transfer of ownership is not permitted
+        "202":
+          description: Transfer of ownership was successful
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                $ref: '#/components/schemas/DatabaseDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -953,27 +953,27 @@ paths:
               $ref: '#/components/schemas/ColumnSemanticsUpdateDto'
         required: true
       responses:
-        "404":
-          description: Table or database could not be found
+        "202":
+          description: Updated column semantics successfully
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Update semantic concept query is malformed or update unit of
-            measurement query is malformed
+                $ref: '#/components/schemas/ColumnDto'
+        "404":
+          description: Table or database could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Updated column semantics successfully
+        "403":
+          description: Access to the database is forbidden
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ColumnDto'
-        "403":
-          description: Access to the database is forbidden
+                $ref: '#/components/schemas/ApiErrorDto'
+        "400":
+          description: Update semantic concept query is malformed or update unit of
+            measurement query is malformed
           content:
             application/json:
               schema:
@@ -1007,24 +1007,24 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Modify of image is not permitted
+        "202":
+          description: Modify of image was successful
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                $ref: '#/components/schemas/DatabaseDto'
         "410":
           description: File was not found in the Storage Service
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Modify of image was successful
+        "403":
+          description: Modify of image is not permitted
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/DatabaseDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1054,8 +1054,8 @@ paths:
               $ref: '#/components/schemas/DatabaseModifyAccessDto'
         required: true
       responses:
-        "400":
-          description: Modify access query or database connection is malformed
+        "404":
+          description: Database or user not found
           content:
             application/json:
               schema:
@@ -1067,14 +1067,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Database or user not found
+        "202":
+          description: Modify access succeeded
+        "400":
+          description: Modify access query or database connection is malformed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Modify access succeeded
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1103,28 +1103,28 @@ paths:
               $ref: '#/components/schemas/DatabaseGiveAccessDto'
         required: true
       responses:
-        "202":
-          description: Granting access succeeded
-        "400":
-          description: Granting access query or database connection is malformed
+        "403":
+          description: Failed giving access
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "405":
-          description: Granting access not permitted
+        "202":
+          description: Granting access succeeded
+        "404":
+          description: Database or user not found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Failed giving access
+        "405":
+          description: Granting access not permitted
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Database or user not found
+        "400":
+          description: Granting access query or database connection is malformed
           content:
             application/json:
               schema:
@@ -1151,22 +1151,22 @@ paths:
           type: string
           format: uuid
       responses:
-        "404":
-          description: "User, database with access was not found"
+        "403":
+          description: Revoke of access not permitted as no access was found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Modify access query or database connection is malformed
+        "404":
+          description: "User, database with access was not found"
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
         "202":
           description: Revoked access successfully
-        "403":
-          description: Revoke of access not permitted as no access was found
+        "400":
+          description: Modify access query or database connection is malformed
           content:
             application/json:
               schema:
@@ -1206,26 +1206,26 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "501":
-          description: Image is not supported
+        "200":
+          description: List queries
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Connection to the database failed
+                $ref: '#/components/schemas/QueryDto'
+        "501":
+          description: Image is not supported
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: List queries
+        "504":
+          description: Query store failed to select query
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/QueryDto'
-        "504":
-          description: Query store failed to select query
+                $ref: '#/components/schemas/ApiErrorDto'
+        "503":
+          description: Connection to the database failed
           content:
             application/json:
               schema:
@@ -1264,14 +1264,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "405":
-          description: Persist query is not permitted
+        "200":
+          description: Persist query successful
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "412":
-          description: Query is already persisted
+                $ref: '#/components/schemas/QueryDto'
+        "400":
+          description: Image not supported
           content:
             application/json:
               schema:
@@ -1282,18 +1282,18 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Image not supported
+        "412":
+          description: Query is already persisted
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: Persist query successful
+        "405":
+          description: Persist query is not permitted
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/QueryDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1324,8 +1324,8 @@ paths:
               $ref: '#/components/schemas/SignupRequestDto'
         required: true
       responses:
-        "417":
-          description: User with e-mail already exists
+        "409":
+          description: User with username already exists
           content:
             application/json:
               schema:
@@ -1334,12 +1334,6 @@ paths:
           description: Parameters are not well-formed (likely email)
           content:
             application/json: {}
-        "409":
-          description: User with username already exists
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: default role not found
           content:
@@ -1352,6 +1346,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/UserBriefDto'
+        "417":
+          description: User with e-mail already exists
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
   /api/semantic/ontology:
     get:
       tags:
@@ -1451,6 +1451,12 @@ paths:
               $ref: '#/components/schemas/ImageCreateDto'
         required: true
       responses:
+        "409":
+          description: Image already exists
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "201":
           description: Created image
           content:
@@ -1463,12 +1469,6 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "409":
-          description: Image already exists
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1534,62 +1534,62 @@ paths:
               $ref: '#/components/schemas/IdentifierSaveDto'
         required: true
       responses:
-        "406":
-          description: Creating identifier not allowed
+        "201":
+          description: Created identifier
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "405":
-          description: Creating identifier not permitted
+                $ref: '#/components/schemas/IdentifierDto'
+        "502":
+          description: Query information could not be retrieved
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "502":
-          description: Query information could not be retrieved
+        "406":
+          description: Creating identifier not allowed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "409":
-          description: Identifier for this resource already exists
+        "404":
+          description: "Failed to find database, table or view"
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Insufficient access rights or authorities
+        "204":
+          description: Identifier could not be created
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "201":
-          description: Created identifier
+        "400":
+          description: Identifier form contains invalid request data
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/IdentifierDto'
+                $ref: '#/components/schemas/ApiErrorDto'
         "503":
           description: DataCite system did not respond
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Identifier form contains invalid request data
+        "409":
+          description: Identifier for this resource already exists
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "204":
-          description: Identifier could not be created
+        "403":
+          description: Insufficient access rights or authorities
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Failed to find database, table or view"
+        "405":
+          description: Creating identifier not permitted
           content:
             application/json:
               schema:
@@ -1610,12 +1610,6 @@ paths:
         schema:
           type: string
       responses:
-        "404":
-          description: User not found
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: List of databases
           content:
@@ -1624,6 +1618,12 @@ paths:
                 type: array
                 items:
                   $ref: '#/components/schemas/DatabaseBriefDto'
+        "404":
+          description: User not found
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
     post:
       tags:
       - database-endpoint
@@ -1636,33 +1636,33 @@ paths:
               $ref: '#/components/schemas/DatabaseCreateDto'
         required: true
       responses:
-        "409":
-          description: Query store could not be created
+        "404":
+          description: "Container, user or database could not be found"
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Connection to the database failed
+        "403":
+          description: Database create permission is missing or grant permissions
+            at broker service failed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Database create query is malformed or image is not supported
+        "409":
+          description: Query store could not be created
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Database create permission is missing or grant permissions
-            at broker service failed
+        "400":
+          description: Database create query is malformed or image is not supported
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Container, user or database could not be found"
+        "503":
+          description: Connection to the database failed
           content:
             application/json:
               schema:
@@ -1688,6 +1688,12 @@ paths:
         schema:
           type: string
       responses:
+        "404":
+          description: User not found
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: Count databases
           content:
@@ -1696,12 +1702,6 @@ paths:
                 type: array
                 items:
                   $ref: '#/components/schemas/DatabaseDto'
-        "404":
-          description: User not found
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
   /api/database/{databaseId}/view:
     get:
       tags:
@@ -1752,32 +1752,32 @@ paths:
               $ref: '#/components/schemas/ViewCreateDto'
         required: true
       responses:
-        "404":
-          description: Database or user could not be found
+        "403":
+          description: Credentials missing
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "405":
-          description: Create view is not permitted
+        "404":
+          description: Database or user could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Create view query is malformed
+        "401":
+          description: Credentials missing
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Credentials missing
+        "201":
+          description: Create view successfully
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "401":
-          description: Credentials missing
+                $ref: '#/components/schemas/ViewBriefDto'
+        "423":
+          description: Create view resulted in an invalid query statement
           content:
             application/json:
               schema:
@@ -1788,14 +1788,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "201":
-          description: Create view successfully
+        "400":
+          description: Create view query is malformed
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ViewBriefDto'
-        "423":
-          description: Create view resulted in an invalid query statement
+                $ref: '#/components/schemas/ApiErrorDto'
+        "405":
+          description: Create view is not permitted
           content:
             application/json:
               schema:
@@ -1817,14 +1817,6 @@ paths:
           type: integer
           format: int64
       responses:
-        "200":
-          description: List tables
-          content:
-            application/json:
-              schema:
-                type: array
-                items:
-                  $ref: '#/components/schemas/TableBriefDto'
         "404":
           description: Database could not be found
           content:
@@ -1837,6 +1829,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "200":
+          description: List tables
+          content:
+            application/json:
+              schema:
+                type: array
+                items:
+                  $ref: '#/components/schemas/TableBriefDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1865,30 +1865,30 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Create table query is malformed
+        "404":
+          description: "Database, container or user could not be found"
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Database, container or user could not be found"
+        "201":
+          description: Created a new table
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                $ref: '#/components/schemas/TableBriefDto'
         "403":
           description: Create table not permitted
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "201":
-          description: Created a new table
+        "400":
+          description: Create table query is malformed
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/TableBriefDto'
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1918,26 +1918,20 @@ paths:
               $ref: '#/components/schemas/ImportDto'
         required: true
       responses:
-        "202":
-          description: Import table data successfully
-        "422":
-          description: Could not import csv via sidecar
+        "409":
+          description: Import failed in sidecar
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Import table data successfully
         "404":
           description: Table or database could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "409":
-          description: Import failed in sidecar
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "403":
           description: Access to the database is forbidden
           content:
@@ -1950,6 +1944,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "422":
+          description: Could not import csv via sidecar
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -1972,34 +1972,34 @@ paths:
         schema:
           type: boolean
       responses:
-        "405":
-          description: Find all queries is not permitted
+        "404":
+          description: "Database, container or user could not be found"
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: List queries
-          content:
-            application/json:
-              schema:
-                type: array
-                items:
-                  $ref: '#/components/schemas/QueryBriefDto'
         "501":
           description: Image is not supported
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Connection to the database failed
+        "504":
+          description: Query store failed to select query
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Database, container or user could not be found"
+        "200":
+          description: List queries
+          content:
+            application/json:
+              schema:
+                type: array
+                items:
+                  $ref: '#/components/schemas/QueryBriefDto'
+        "503":
+          description: Connection to the database failed
           content:
             application/json:
               schema:
@@ -2011,8 +2011,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "504":
-          description: Query store failed to select query
+        "405":
+          description: Find all queries is not permitted
           content:
             application/json:
               schema:
@@ -2076,8 +2076,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Execute query not permitted
+        "409":
+          description: Could not store query in query store
           content:
             application/json:
               schema:
@@ -2088,8 +2088,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "409":
-          description: Could not store query in query store
+        "403":
+          description: Execute query not permitted
           content:
             application/json:
               schema:
@@ -2137,12 +2137,6 @@ paths:
               $ref: '#/components/schemas/ContainerCreateRequestDto'
         required: true
       responses:
-        "409":
-          description: Container name already exists
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: Container image or user could not be found
           content:
@@ -2155,6 +2149,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ContainerBriefDto'
+        "409":
+          description: Container name already exists
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2197,8 +2197,8 @@ paths:
         schema:
           type: string
       responses:
-        "417":
-          description: Generated query or uri is malformed
+        "404":
+          description: Could not find ontology
           content:
             application/json:
               schema:
@@ -2209,16 +2209,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: Found entities
-          content:
-            application/json:
-              schema:
-                type: array
-                items:
-                  $ref: '#/components/schemas/EntityDto'
-        "404":
-          description: Could not find ontology
+        "417":
+          description: Generated query or uri is malformed
           content:
             application/json:
               schema:
@@ -2229,6 +2221,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "200":
+          description: Found entities
+          content:
+            application/json:
+              schema:
+                type: array
+                items:
+                  $ref: '#/components/schemas/EntityDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2252,28 +2252,28 @@ paths:
           type: integer
           format: int64
       responses:
-        "200":
-          description: Suggested table semantics successfully
-          content:
-            application/json:
-              schema:
-                type: array
-                items:
-                  $ref: '#/components/schemas/TableColumnEntityDto'
         "422":
           description: Ontology does not have rdf or sparql endpoint
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Could not find the table
+        "417":
+          description: Generated query is malformed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "417":
-          description: Generated query is malformed
+        "200":
+          description: Suggested table semantics successfully
+          content:
+            application/json:
+              schema:
+                type: array
+                items:
+                  $ref: '#/components/schemas/TableColumnEntityDto'
+        "404":
+          description: Could not find the table
           content:
             application/json:
               schema:
@@ -2307,14 +2307,12 @@ paths:
           type: integer
           format: int64
       responses:
-        "200":
-          description: Suggested table column semantics successfully
+        "404":
+          description: Could not find the table column
           content:
             application/json:
               schema:
-                type: array
-                items:
-                  $ref: '#/components/schemas/TableColumnEntityDto'
+                $ref: '#/components/schemas/ApiErrorDto'
         "422":
           description: Ontology does not have rdf or sparql endpoint
           content:
@@ -2327,12 +2325,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Could not find the table column
+        "200":
+          description: Suggested table column semantics successfully
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                type: array
+                items:
+                  $ref: '#/components/schemas/TableColumnEntityDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2366,26 +2366,21 @@ paths:
           format: int64
       - name: Accept
         in: header
-        required: true
-        schema:
-          type: string
-      responses:
-        "404":
-          description: Identifier could not be found
-          content:
-            text/csv:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+        required: true
+        schema:
+          type: string
+      responses:
         "410":
           description: Failed to retrieve from S3 endpoint
           content:
             text/csv:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "422":
-          description: Failed to retrieve from database sidecar
+        "400":
+          description: "Identifier could not be exported, the requested style is not\
+            \ known"
           content:
-            text/csv:
+            text/bibliography:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
         "409":
@@ -2394,15 +2389,14 @@ paths:
             text/csv:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: "Identifier could not be exported, the requested style is not\
-            \ known"
+        "503":
+          description: Identifier could not exported from database as it is not reachable
           content:
-            text/bibliography:
+            text/csv:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Identifier could not exported from database as it is not reachable
+        "422":
+          description: Failed to retrieve from database sidecar
           content:
             text/csv:
               schema:
@@ -2419,6 +2413,12 @@ paths:
             text/bibliography; style=apa: {}
             text/bibliography; style=ieee: {}
             text/bibliography; style=bibtex: {}
+        "404":
+          description: Identifier could not be found
+          content:
+            text/csv:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
   /api/oai:
     get:
       tags:
@@ -2492,18 +2492,18 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: Database found successfully
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/DatabaseDto'
         "404":
           description: Database or exchange could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "200":
+          description: Database found successfully
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/DatabaseDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2533,50 +2533,50 @@ paths:
           type: string
           format: date-time
       responses:
-        "422":
-          description: Sidecar operation could not be completed
+        "201":
+          description: Created identifier
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/ApiErrorDto'
+                $ref: '#/components/schemas/IdentifierDto'
         "409":
           description: Failed to export file from sidecar
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Operation is not allowed
+        "422":
+          description: Sidecar operation could not be completed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Database connection could not be established
+        "403":
+          description: Operation is not allowed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "201":
-          description: Created identifier
+        "400":
+          description: Images is not supported or table/query is malformed
           content:
             application/json:
               schema:
-                $ref: '#/components/schemas/IdentifierDto'
+                $ref: '#/components/schemas/ApiErrorDto'
         "410":
           description: Blob storage operation could not be completed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Table, database or user was not found"
+        "503":
+          description: Database connection could not be established
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Images is not supported or table/query is malformed
+        "404":
+          description: "Table, database or user was not found"
           content:
             application/json:
               schema:
@@ -2639,18 +2639,18 @@ paths:
           type: integer
           format: int64
       responses:
-        "403":
-          description: Find view is not permitted
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: Find view successfully
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ViewDto'
+        "403":
+          description: Find view is not permitted
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: "Database, view or user could not be found"
           content:
@@ -2679,20 +2679,20 @@ paths:
           type: integer
           format: int64
       responses:
-        "403":
-          description: Deletion not allowed
+        "400":
+          description: Delete view query is malformed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "503":
-          description: Connection to the database failed
+        "423":
+          description: Delete view resulted in an invalid query statement
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Delete view query is malformed
+        "404":
+          description: "Database, view or user could not be found"
           content:
             application/json:
               schema:
@@ -2703,16 +2703,16 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "423":
-          description: Delete view resulted in an invalid query statement
+        "200":
+          description: Delete view successfully
+        "503":
+          description: Connection to the database failed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "200":
-          description: Delete view successfully
-        "404":
-          description: "Database, view or user could not be found"
+        "403":
+          description: Deletion not allowed
           content:
             application/json:
               schema:
@@ -2752,6 +2752,12 @@ paths:
           type: integer
           format: int64
       responses:
+        "404":
+          description: "Database, view, container or user could not be found"
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
         "200":
           description: Find data successfully
           content:
@@ -2770,12 +2776,6 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Database, view, container or user could not be found"
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2805,8 +2805,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Count data not allowed
+        "404":
+          description: "Database, view, container or user could not be found"
           content:
             application/json:
               schema:
@@ -2818,14 +2818,14 @@ paths:
               schema:
                 type: integer
                 format: int64
-        "400":
-          description: Pagination not in valid range or find data query is malformed
+        "403":
+          description: Count data not allowed
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Database, view, container or user could not be found"
+        "400":
+          description: Pagination not in valid range or find data query is malformed
           content:
             application/json:
               schema:
@@ -2853,20 +2853,14 @@ paths:
           type: integer
           format: int64
       responses:
-        "503":
-          description: Could not communicate with the broker service
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "403":
           description: Access to the database is forbidden
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: "Table, database or container could not be found"
+        "503":
+          description: Could not communicate with the broker service
           content:
             application/json:
               schema:
@@ -2877,6 +2871,12 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/TableDto'
+        "404":
+          description: "Table, database or container could not be found"
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2899,14 +2899,16 @@ paths:
           type: integer
           format: int64
       responses:
-        "400":
-          description: Delete table query resulted in an invalid query statement
+        "202":
+          description: Delete table successfully
+        "403":
+          description: Access to the database is forbidden
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Access to the database is forbidden
+        "400":
+          description: Delete table query resulted in an invalid query statement
           content:
             application/json:
               schema:
@@ -2917,8 +2919,6 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "202":
-          description: Delete table successfully
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -2948,12 +2948,6 @@ paths:
           type: string
           format: date-time
       responses:
-        "422":
-          description: Could not import csv via sidecar
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "400":
           description: Table data is malformed or image is not supported
           content:
@@ -2979,6 +2973,12 @@ paths:
               schema:
                 type: integer
                 format: int64
+        "422":
+          description: Could not import csv via sidecar
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -3007,8 +3007,14 @@ paths:
         schema:
           type: string
       responses:
-        "409":
-          description: Export of query failed
+        "404":
+          description: Database or query could not be found
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
+        "422":
+          description: Sidecar failed to export
           content:
             application/json:
               schema:
@@ -3019,8 +3025,8 @@ paths:
             '*/*':
               schema:
                 type: object
-        "410":
-          description: Could not find in S3 storage
+        "400":
+          description: Image is not supported
           content:
             application/json:
               schema:
@@ -3031,20 +3037,14 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "422":
-          description: Sidecar failed to export
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Image is not supported
+        "410":
+          description: Could not find in S3 storage
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Database or query could not be found
+        "409":
+          description: Export of query failed
           content:
             application/json:
               schema:
@@ -3097,32 +3097,32 @@ paths:
         schema:
           type: string
       responses:
-        "417":
-          description: Could not parse columns
+        "404":
+          description: Database or query could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Execute query not permitted
+        "417":
+          description: Could not parse columns
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "400":
-          description: Image is not supported
+        "409":
+          description: Could not store query in query store
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "409":
-          description: Could not store query in query store
+        "400":
+          description: Image is not supported
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Database or query could not be found
+        "403":
+          description: Execute query not permitted
           content:
             application/json:
               schema:
@@ -3156,14 +3156,14 @@ paths:
           type: integer
           format: int64
       responses:
-        "417":
-          description: Could not parse columns
+        "404":
+          description: Database or query could not be found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "403":
-          description: Execute query not permitted
+        "417":
+          description: Could not parse columns
           content:
             application/json:
               schema:
@@ -3174,8 +3174,8 @@ paths:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
-        "404":
-          description: Database or query could not be found
+        "403":
+          description: Execute query not permitted
           content:
             application/json:
               schema:
@@ -3243,18 +3243,18 @@ paths:
           type: integer
           format: int64
       responses:
-        "202":
-          description: Deleted container successfully
-          content:
-            '*/*':
-              schema:
-                type: object
         "404":
           description: Container not found
           content:
             application/json:
               schema:
                 $ref: '#/components/schemas/ApiErrorDto'
+        "202":
+          description: Deleted container successfully
+          content:
+            '*/*':
+              schema:
+                type: object
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -3272,12 +3272,6 @@ paths:
           type: integer
           format: int64
       responses:
-        "403":
-          description: Deleting identifier not permitted
-          content:
-            application/json:
-              schema:
-                $ref: '#/components/schemas/ApiErrorDto'
         "404":
           description: Identifier or database could not be found
           content:
@@ -3290,6 +3284,12 @@ paths:
             '*/*':
               schema:
                 type: object
+        "403":
+          description: Deleting identifier not permitted
+          content:
+            application/json:
+              schema:
+                $ref: '#/components/schemas/ApiErrorDto'
       security:
       - bearerAuth: []
       - basicAuth: []
@@ -6794,14 +6794,14 @@ components:
           type: string
         resumptionToken:
           type: string
+        parametersString:
+          type: string
         fromDate:
           type: string
           format: date-time
         untilDate:
           type: string
           format: date-time
-        parametersString:
-          type: string
     BannerMessageDto:
       required:
       - id
diff --git a/.docs/.swagger/swagger-site.sh b/.docs/.swagger/swagger-site.sh
index b9a0d163e9649e1766a2efed232ea634a45c5916..f6f91bc9109786bf5c8341c548e49fca5ed59cf4 100644
--- a/.docs/.swagger/swagger-site.sh
+++ b/.docs/.swagger/swagger-site.sh
@@ -7,10 +7,6 @@ services[9093]=data
 services[9099]=metadata
 services[3305]=sidecar
 
-# clean up
-echo "clean up ./site"
-rm -rf ./site
-
 # ensure target directories are present
 echo "ensure target directory ./site are present"
 mkdir -p ./site
diff --git a/.docs/build-website.sh b/.docs/build-website.sh
new file mode 100755
index 0000000000000000000000000000000000000000..6e2fb29e7959e6f65ed85f73e5e217c889db1ead
--- /dev/null
+++ b/.docs/build-website.sh
@@ -0,0 +1,82 @@
+#!/bin/bash
+
+OVERRIDES_MAIN_HTML=""
+SCRIPTS_EXTRA_JS=""
+
+function clean_cache {
+  echo "Removing cache from directory ./site"
+  rm -rf ./site
+}
+
+function generate_docs {
+  BRANCH="release-$1"
+  echo "==================================================="
+  echo "Building DOCS for version $1 on branch $BRANCH"
+  echo "==================================================="
+  git reset --hard && git checkout "$BRANCH"
+  pip install -r ./requirements.txt > /dev/null
+  mkdir -p ./final
+  if [ "$1" = "latest" ]; then
+    OVERRIDES_MAIN_HTML=$(cat .docs/overrides/main.html)
+    sed -i -e "s/__APPVERSION__/${APP_VERSION}/g" .docs/scripts/extra.js
+    SCRIPTS_EXTRA_JS=$(cat .docs/scripts/extra.js)
+  else
+    echo $OVERRIDES_MAIN_HTML > .docs/overrides/main.html
+    mkdir -p .docs/scripts
+    echo $SCRIPTS_EXTRA_JS > .docs/scripts/extra.js
+  fi
+  find .docs/ -type f -exec sed -i -e "s/__APPVERSION__/$1/g" {} \;
+  find .docs/ -type f -exec sed -i -e "s/__CHARTVERSION__/$1/g" {} \;
+  mkdocs build > /dev/null && cp -r ./site "./final/$1"
+  cp -r "./swagger/$1" "./final/$1/swagger"
+  clean_cache
+}
+
+function generate_api {
+  BRANCH="release-$1"
+  echo "==================================================="
+  echo "Building API for version $1 on branch $BRANCH"
+  echo "==================================================="
+  git reset --hard && git checkout "$BRANCH"
+  bash .docs/.swagger/swagger-site.sh
+  find ./site -type f -exec sed -i -e "s/__APPVERSION__/$1/g" {} \;
+  mkdir -p "./swagger/$1"
+  cp -r ./site/* "./swagger/$1/"
+  clean_cache
+}
+
+# usage
+if [ -z "$DOC_VERSIONS" ]; then
+    echo "Variable DOC_VERSIONS not set"
+    exit 1
+fi
+versions=(${DOC_VERSIONS//,/ })
+
+# usage
+if [ -z "$APP_VERSION" ]; then
+    echo "Variable APP_VERSION not set"
+    exit 2
+fi
+echo "==================================================="
+echo "APP_VERSION=$APP_VERSION"
+echo "==================================================="
+
+# ensure branches exist on machine
+git fetch
+
+generate_api "latest"
+generate_docs "latest"
+
+# versions
+for i in "${!versions[@]}"; do
+  version="${versions[i]}"
+  generate_api "$version"
+  generate_docs "$version"
+done
+
+
+# finalization
+echo "==================================================="
+echo "Moving default version $APP_VERSION docs to /"
+cp -r ./final/${APP_VERSION}/* ./final/
+echo "==================================================="
diff --git a/.docs/redirect.html b/.docs/redirect.html
index 053a5581bfeeb797c2d571a1dd378b1ed88df305..a3737a67b6655b56c4c31f35f8bfc279a72b5e0f 100644
--- a/.docs/redirect.html
+++ b/.docs/redirect.html
@@ -5,7 +5,7 @@
 <head>
     <meta charset="UTF-8">
     <title>Redirect Notice</title>
-    <meta http-equiv="Refresh" content="0; url='https://www.ifs.tuwien.ac.at/infrastructures/dbrepo/__APPVERSION__/'" />
+    <meta http-equiv="Refresh" content="0; url='/infrastructures/dbrepo/__APPVERSION__/'" />
 </head>
 <body>
 <h1>Redirect Notice</h1>
@@ -14,7 +14,7 @@
     available at:
 </p>
 <p>
-    <a href="https://www.ifs.tuwien.ac.at/infrastructures/dbrepo/__APPVERSION__/">https://www.ifs.tuwien.ac.at/infrastructures/dbrepo/__APPVERSION__/</a>
+    <a href="/infrastructures/dbrepo/__APPVERSION__/">/infrastructures/dbrepo/__APPVERSION__/</a>
 </p>
 </body>
 </html>
\ No newline at end of file
diff --git a/.docs/scripts/extra.js b/.docs/scripts/extra.js
index 4768615e22f22fc7f895cfee742ed9c848347b89..2360d0d2db8579cfbd71d6077fe894cc46056c61 100644
--- a/.docs/scripts/extra.js
+++ b/.docs/scripts/extra.js
@@ -1,10 +1,11 @@
 function getVersion() {
     const segments = location.pathname.split('/');
-    if (segments.length >= 4) {
+    if (segments.length > 4 && (segments[3].match(/[0-9]\.[0-9]\.[0-9]/g) || segments[3] == 'latest')) {
+        console.debug('version', segments[3]);
         return segments[3];
-    } else {
-        return '__APPVERSION__';
     }
+    console.debug('default version', '__APPVERSION__');
+    return '__APPVERSION__';
 }
 function switchVersion(value) {
     if (!value) { return }
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index ed2f87c948759cd28ad1e8d94d991dab5bd2b11b..d4fff5e34f5b1ad0037795a60bb227885d290dee 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -4,15 +4,18 @@ variables:
   TRIVY_CACHE_DIR: ".trivycache/"
   DOCKER_HOST: "unix:///var/run/dind/docker.sock"
   TESTCONTAINERS_RYUK_DISABLED: "false"
+  DOC_VERSIONS: "latest,1.4.1,1.4.0,1.3.0"
   APP_VERSION: "1.4.1"
   CHART_VERSION: "1.4.1"
 
 image: debian:12-slim
 
 cache:
+  policy: pull
+  key: ${CI_BUILD_REF_NAME}
   paths:
-    - /root/.m2/repository/
-    - /root/.npm/
+    - final/
+    - .m2/
 
 stages:
   - build
@@ -24,12 +27,20 @@ stages:
 build-metadata-service:
   image: maven:3-openjdk-17
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   script:
     - "mvn -f ./dbrepo-metadata-service/pom.xml clean install -Dstyle.color=always -DskipTests"
 
 build-analyse-service:
   image: python:3.9-slim
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   variables:
     PIPENV_PIPFILE: "./dbrepo-analyse-service/Pipfile"
   script:
@@ -39,6 +50,10 @@ build-analyse-service:
 build-data-service:
   image: maven:3-openjdk-17
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   needs:
     - build-metadata-service
   script:
@@ -48,6 +63,10 @@ build-data-service:
 build-frontend:
   image: node:14-alpine
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   script:
     - "yarn config set network-timeout 600000 -g"
     - "yarn --cwd ./dbrepo-ui install --legacy-peer-deps"
@@ -56,6 +75,10 @@ build-frontend:
 build-search-service:
   image: python:3.10-alpine
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   script:
     - "pip install pipenv"
     - "cd dbrepo-search-service && pipenv install --system --deploy"
@@ -63,6 +86,10 @@ build-search-service:
 build-docker:
   image: docker.io/docker:24-dind
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   before_script:
     - echo "$CI_REGISTRY_PASSWORD" | docker login --username "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY_URL
   script:
@@ -74,6 +101,10 @@ build-docker:
 build-helm:
   image: docker.io/docker:24-dind
   stage: build
+  only:
+    refs:
+      - dev
+      - master
   before_script:
     - echo "$CI_REGISTRY_PASSWORD" | docker login --username "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY_URL
   script:
@@ -86,6 +117,10 @@ build-helm:
 test-metadata-service:
   image: maven:3-openjdk-17
   stage: test
+  only:
+    refs:
+      - dev
+      - master
   needs:
     - build-metadata-service
   script:
@@ -105,6 +140,10 @@ test-metadata-service:
 test-data-service:
   image: maven:3-openjdk-17
   stage: test
+  only:
+    refs:
+      - dev
+      - master
   needs:
     - build-data-service
   script:
@@ -124,6 +163,10 @@ test-data-service:
 test-analyse-service:
   image: python:3.9-slim
   stage: test
+  only:
+    refs:
+      - dev
+      - master
   variables:
     PIPENV_PIPFILE: "./dbrepo-analyse-service/Pipfile"
   needs:
@@ -146,6 +189,10 @@ test-analyse-service:
 test-frontend:
   image: node:14-alpine
   stage: test
+  only:
+    refs:
+      - dev
+      - master
   needs:
     - build-frontend
   script:
@@ -170,7 +217,6 @@ scan-analyse-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-analyse-service-report.json docker.io/dbrepo/analyse-service:latest
@@ -191,7 +237,6 @@ scan-authentication-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-authentication-service-report.json docker.io/dbrepo/authentication-service:latest
@@ -212,7 +257,6 @@ scan-broker-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-broker-service-report.json docker.io/dbrepo/broker-service:latest
@@ -233,7 +277,6 @@ scan-gateway-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-gateway-service-report.json docker.io/nginx:1.25.0-alpine-slim
@@ -254,7 +297,6 @@ scan-metadata-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-metadata-service-report.json docker.io/dbrepo/metadata-service:latest
@@ -275,7 +317,6 @@ scan-data-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-data-service-report.json docker.io/dbrepo/data-service:latest
@@ -296,7 +337,6 @@ scan-search-db:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-search-db-report.json docker.io/dbrepo/search-db:latest
@@ -317,7 +357,6 @@ scan-search-dashboard:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-search-dashboard-report.json docker.io/opensearchproject/opensearch-dashboards:2.10.0
@@ -338,7 +377,6 @@ scan-search-db-init:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-search-db-init-report.json docker.io/dbrepo/search-db-init:latest
@@ -359,7 +397,6 @@ scan-data-db:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-data-db-report.json docker.io/bitnami/mariadb:11.2.2-debian-11-r0
@@ -380,7 +417,6 @@ scan-metadata-db:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-metadata-db-report.json docker.io/dbrepo/metadata-db:latest
@@ -401,7 +437,6 @@ scan-ui:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-ui-report.json docker.io/dbrepo/ui:latest
@@ -422,7 +457,6 @@ scan-storage-service:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-storage-service-report.json docker.io/chrislusf/seaweedfs:3.59
@@ -443,7 +477,6 @@ scan-storage-service-init:
   only:
     refs:
       - master
-      - release-v1.4
   allow_failure: true
   script:
     - trivy image --insecure --exit-code 0 --format template --template "@.trivy/gitlab.tpl" -o ./.trivy/trivy-storage-service-init-report.json docker.io/dbrepo/storage-service-init:latest
@@ -458,55 +491,27 @@ scan-storage-service-init:
     reports:
       container_scanning: ./.trivy/trivy-storage-service-init-report.json
 
-release-latest:
-  stage: release
-  image: docker:24-dind
-  needs:
-    - test-metadata-service
-    - test-data-service
-    - test-analyse-service
-    - test-frontend
-  only:
-    refs:
-      - master
-  before_script:
-    - echo "$CI_REGISTRY_PASSWORD" | docker login --username "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY_URL
-    - echo "$CI_REGISTRY2_PASSWORD" | docker login --username "$CI_REGISTRY2_USER" --password-stdin $CI_REGISTRY2_URL
-  script:
-    - "ifconfig eth0 mtu 1450 up"
-    - "apk add make bash"
-    - TAG=latest make release
-
-release-1.3:
-  stage: release
-  image: docker:24-dind
-  needs:
-    - test-metadata-service
-    - test-data-service
-    - test-analyse-service
-    - test-frontend
+docs-registry:
+  stage: docs
+  image: docker.io/python:3.11-slim
   only:
     refs:
-      - release-v1.3
-  before_script:
-    - echo "$CI_REGISTRY_PASSWORD" | docker login --username "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY_URL
-    - echo "$CI_REGISTRY2_PASSWORD" | docker login --username "$CI_REGISTRY2_USER" --password-stdin $CI_REGISTRY2_URL
+      - /^release-.*/
   script:
-    - "ifconfig eth0 mtu 1450 up"
-    - "apk add make bash"
-    - "TAG=1.3.0 make release"
+    - pip install -r ./requirements.txt
+    - python3 .docs/docker/release.py
 
-release-1.4:
+release-images:
   stage: release
   image: docker:24-dind
-  needs:
+  dependencies:
     - test-metadata-service
     - test-data-service
     - test-analyse-service
     - test-frontend
   only:
     refs:
-      - release-v1.4
+      - /^release-.*/
   before_script:
     - echo "$CI_REGISTRY_PASSWORD" | docker login --username "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY_URL
     - echo "$CI_REGISTRY2_PASSWORD" | docker login --username "$CI_REGISTRY2_USER" --password-stdin $CI_REGISTRY2_URL
@@ -515,12 +520,12 @@ release-1.4:
     - "apk add make bash"
     - "TAG=${APP_VERSION} make release"
 
-release-helm-1.4:
+release-chart:
   stage: release
   image: docker:24-dind
   only:
     refs:
-      - release-v1.4
+      - /^release-.*/
   before_script:
     - echo "$CI_REGISTRY2_PASSWORD" | docker login --username "$CI_REGISTRY2_USER" --password-stdin $CI_REGISTRY2_URL
   script:
@@ -531,202 +536,19 @@ release-helm-1.4:
     - helm package ./helm-charts/dbrepo --destination ./build
     - helm push "./build/dbrepo-${CHART_VERSION}.tgz" "oci://${CI_REGISTRY2_URL}/helm"
 
-build-api-latest:
-  stage: build
-  image: docker.io/alpine:3.18
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - apk add bash git
-    - git fetch && git checkout master
-    - bash .docs/.swagger/swagger-site.sh
-    - find ./site -type f -exec sed -i -e "s/__APPVERSION__/latest/g" {} \;
-    - mkdir -p ./swagger/latest
-    - cp -r ./site/* ./swagger/latest/
-  cache:
-    paths:
-      - ./swagger/latest
-  artifacts:
-    when: always
-    paths:
-      - ./swagger/latest
-    expire_in: 1 days
-
-build-api-1.3:
-  stage: build
-  image: docker.io/alpine:3.18
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - apk add bash git maven
-    - git fetch && git checkout release-v1.3
-    - bash .docs/.swagger/generate.sh
-    - mkdir -p ./swagger/1.3.0
-    - cp -r ./site/* ./swagger/1.3.0/
-  cache:
-    paths:
-      - ./swagger/1.3.0
-  artifacts:
-    when: always
-    paths:
-      - ./swagger/1.3.0
-    expire_in: 1 days
-
-build-api-1.4:
-  stage: build
-  image: docker.io/alpine:3.18
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - apk add bash git
-    - bash .gitlab/build-api.sh v1.4.0 release-v1.4
-  cache:
-    paths:
-      - ./swagger/${APP_VERSION}
-  artifacts:
-    when: always
-    paths:
-      - ./swagger/${APP_VERSION}
-    expire_in: 1 days
-
-docs-registry:
-  stage: docs
-  image: docker.io/python:3.11-slim
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - pip install -r ./requirements.txt
-    - python3 .docs/docker/release.py
-  cache:
-    paths:
-      - ./final
-  artifacts:
-    when: always
-    paths:
-      - ./final
-    expire_in: 1 days
-
-docs-latest:
-  stage: docs
-  image: docker.io/python:3.9-slim
-  needs:
-    - build-api-latest
-    - build-api-1.3
-    - build-api-1.4
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - apt-get update && apt-get install -y git make sed
-    - git fetch && git checkout master
-    - pip install -r ./requirements.txt
-    - mkdir -p ./final
-    - sed -i -e "s/__APPVERSION__/${APP_VERSION}/g" .docs/redirect.html
-    - cp ./.docs/redirect.html ./final/index.html
-    - find .docs/ -type f -exec sed -i -e "s/__APPVERSION__/latest/g" {} \;
-    - find .docs/ -type f -exec sed -i -e "s/__CHARTVERSION__/${CHART_VERSION}/g" {} \;
-    - mkdocs build && cp -r ./site ./final/latest
-    - cp -r ./swagger/latest ./final/latest/swagger
-  cache:
-    paths:
-      - ./final
-  artifacts:
-    when: always
-    paths:
-      - ./final
-    expire_in: 1 days
-
-docs-1.3:
-  stage: docs
-  image: docker.io/python:3.9-slim
-  needs:
-    - build-api-latest
-    - build-api-1.3
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    - apt-get update && apt-get install -y git make wget
-    - git fetch && git checkout release-v1.3
-    - pip install -r ./requirements.txt
-    - wget https://gitlab.phaidra.org/fair-data-austria-db-repository/fda-services/-/raw/dev/.docs/overrides/main.html -O .docs/overrides/main.html -q
-    - mkdir -p ./final
-    - mkdocs build && cp -r ./site ./final/1.3.0
-    - cp -r ./swagger/1.3.0 ./final/1.3.0/swagger
-  cache:
-    paths:
-      - ./final
-  artifacts:
-    when: always
-    paths:
-      - ./final
-    expire_in: 1 days
-
-docs-1.4:
-  stage: docs
-  image: docker.io/python:3.11-slim
-  needs:
-    - build-api-latest
-    - build-api-1.3
-    - build-api-1.4
-  only:
-    refs:
-      - master
-      - release-v1.3
-      - release-v1.4
-  script:
-    # need to loop for release-v1.4 and tag 1.4.0
-    - apt-get update && apt-get install -y git make sed wget
-    - git fetch && git checkout release-v1.4
-    - pip install -r ./requirements.txt
-    - wget https://gitlab.phaidra.org/fair-data-austria-db-repository/fda-services/-/raw/dev/.docs/overrides/main.html -O .docs/overrides/main.html -q
-    - mkdir -p ./final
-    - find .docs/ -type f -exec sed -i -e "s/__APPVERSION__/${APP_VERSION}/g" {} \;
-    - find .docs/ -type f -exec sed -i -e "s/__CHARTVERSION__/${CHART_VERSION}/g" {} \;
-    - mkdocs build && cp -r ./site ./final/${APP_VERSION}
-    - cp -r ./swagger/${APP_VERSION} ./final/${APP_VERSION}/swagger
-  cache:
-    paths:
-      - ./final
-  artifacts:
-    when: always
-    paths:
-      - ./final
-    expire_in: 1 days
-
 release-docs:
   stage: release
-  image: docker.io/finalgene/openssh:9.1
-  needs:
-    - docs-latest
-    - docs-1.3
-    - docs-1.4
+  image: docker.io/python:3.11-slim
   only:
     refs:
-      - master
-      - release-v1.3
-      - release-v1.4
+      - /^release-.*/
   script:
+    - apt-get update && apt-get install -y git make sed wget ssh
+    - make docs
     - eval $(ssh-agent -s)
     - echo "$CI_KEY_PRIVATE" > /root/.ssh/id_rsa && chmod 0600 /root/.ssh/id_rsa
     - echo "$CI_KEY_PUBLIC" > /root/.ssh/id_rsa.pub
     - echo "$CI_DOC_ID" > ~/.ssh/known_hosts
-    - tar czfv final.tar.gz ./final
+    - tar czfv ./final.tar.gz ./final
     - "scp -oHostKeyAlgorithms=+ssh-rsa -oPubkeyAcceptedAlgorithms=+ssh-rsa final.tar.gz $CI_DOC_USER@$CI_DOC_IP:final.tar.gz"
     - "ssh -oHostKeyAlgorithms=+ssh-rsa -oPubkeyAcceptedAlgorithms=+ssh-rsa $CI_DOC_USER@$CI_DOC_IP 'rm -rf /system/user/ifs/infrastructures/public_html/dbrepo/*; tar xzfv ./final.tar.gz; rm -f ./final.tar.gz; cp -r ./final/* /system/user/ifs/infrastructures/public_html/dbrepo; rm -rf ./final'"
diff --git a/Makefile b/Makefile
index 45e493ffa90202c9268578eeb2213fc712c74cd4..6187dc11366577f2e08dfe2f71430d04d14ea7ed 100644
--- a/Makefile
+++ b/Makefile
@@ -222,5 +222,8 @@ test: test-backend test-frontend
 teardown:
 	./bin/teardown.sh
 
-build-api: build-docker
+build-api:
 	bash .docs/.swagger/swagger-generate.sh
+
+docs:
+	bash .docs/build-website.sh
\ No newline at end of file