Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
660c8b6
TIMAAT Weiterentwicklung #9 - categories view
NKO97 Nov 13, 2025
38a88ff
TIMAAT Weiterentwicklung #9 - categories view
NKO97 Nov 17, 2025
073cd66
TIMAAT Weiterentwicklung #9 - categories view
NKO97 Nov 17, 2025
dc4cb11
TIMAAT Weiterentwicklung #9 - Datatables integration for category sets
NKO97 Nov 17, 2025
fd2440f
TIMAAT Weiterentwicklung #9 - Datatables integration for categories
NKO97 Nov 17, 2025
1ffd90f
TIMAAT Weiterentwicklung #9 - Adding and edit of categories
NKO97 Nov 23, 2025
defffca
TIMAAT Weiterentwicklung #9 - Adding and edit of category sets
NKO97 Nov 23, 2025
d69ec20
TIMAAT Weiterentwicklung #9 - Implement category set deletion
NKO97 Nov 23, 2025
388cc12
TIMAAT Weiterentwicklung #9 - Generic datatable implementation
NKO97 Nov 24, 2025
5eaa620
TIMAAT Weiterentwicklung #9 - Implemented categories table for actors
NKO97 Nov 24, 2025
3dcb242
TIMAAT Weiterentwicklung #9 - Implemented listing structure for storages
NKO97 Nov 28, 2025
e62e7b3
TIMAAT Weiterentwicklung #9 - Added metamodel processor
NKO97 Dec 2, 2025
e59b4f9
TIMAAT Weiterentwicklung #9 - Started implementation of table column …
NKO97 Dec 3, 2025
bc14aac
Merge branch 'nko-master' into 9-umsetzung-einer-ansicht-zur-betracht…
NKO97 Dec 3, 2025
902b046
TIMAAT Weiterentwicklung #9 - Implemented column selector component
NKO97 Dec 7, 2025
0a30f49
TIMAAT Weiterentwicklung #9 - Added persisting and loading of active …
NKO97 Dec 7, 2025
19fa7d4
TIMAAT Weiterentwicklung #9 - Added col reorder plugin
NKO97 Dec 8, 2025
19242ce
TIMAAT Weiterentwicklung #9 - Added category and category set query p…
NKO97 Dec 13, 2025
dcffa19
TIMAAT Weiterentwicklung #9 - Created a generic DbStorage
NKO97 Dec 13, 2025
1195308
TIMAAT Weiterentwicklung #9 - Created a generic DbStorage
NKO97 Dec 13, 2025
9307321
TIMAAT Weiterentwicklung #9 - Showing of information message when no …
NKO97 Dec 19, 2025
bccf8ec
TIMAAT Weiterentwicklung #9 - Usage of selected categories and catego…
NKO97 Dec 19, 2025
8f23c7d
TIMAAT Weiterentwicklung #9 - Created database update & Refactored as…
NKO97 Dec 27, 2025
2968b6f
TIMAAT Weiterentwicklung #9 - Categories and category sets for actors
NKO97 Dec 28, 2025
d72472d
TIMAAT Weiterentwicklung #9 - Fixed setting of categories
NKO97 Jan 10, 2026
643f5c6
TIMAAT Weiterentwicklung #9 - Implemented endpoint segment structure …
NKO97 Jan 10, 2026
e36a652
TIMAAT Weiterentwicklung #9 - segment structure category table
NKO97 Jan 10, 2026
5556fa2
TIMAAT Weiterentwicklung #9 - Added entity type filter buttons
NKO97 Jan 11, 2026
45303a6
TIMAAT Weiterentwicklung #9 - Added types filter to entity endpoints
NKO97 Jan 11, 2026
3303b32
TIMAAT Weiterentwicklung #9 - Integrate usage of type query parameters
NKO97 Jan 11, 2026
a388832
TIMAAT Weiterentwicklung #9 - Added vertical scrolling for categories…
NKO97 Jan 11, 2026
06b78a1
TIMAAT Weiterentwicklung #9 - Added column groups
NKO97 Jan 11, 2026
4ceed56
TIMAAT Weiterentwicklung #9 - Categories content tables - Updated col…
NKO97 Jan 12, 2026
599181c
TIMAAT Weiterentwicklung #9 - Categories content tables - Implemented…
NKO97 Jan 12, 2026
ad5a401
TIMAAT Weiterentwicklung #9 - Categories content table - Ordering
NKO97 Jan 12, 2026
eb25e32
TIMAAT Weiterentwicklung #9 - Implemented thumbnail column for annota…
NKO97 Jan 13, 2026
bd8aad1
TIMAAT Weiterentwicklung #9 - Implemented authorization verification
NKO97 Jan 13, 2026
403a325
TIMAAT Weiterentwicklung #9 - Configurable search field for generic t…
NKO97 Jan 13, 2026
88c9f04
TIMAAT Weiterentwicklung #9 - Updated generic table representation to…
NKO97 Jan 13, 2026
25afede
TIMAAT Weiterentwicklung #9 - Fixed bug leading to a hiding of save a…
NKO97 Jan 13, 2026
a690885
TIMAAT Weiterentwicklung #9 - Fixed bug leading to not selectable aud…
NKO97 Jan 13, 2026
fd6868b
TIMAAT Weiterentwicklung #9 - Fixed titles in form
NKO97 Jan 13, 2026
2cf9347
TIMAAT Weiterentwicklung #9 - Fixed used query parameter to filter by…
NKO97 Jan 13, 2026
1092dca
TIMAAT Weiterentwicklung #9 - Fixed dependency bug
NKO97 Jan 13, 2026
fc534c0
TIMAAT Weiterentwicklung #9 - Fixed entrypoint script
NKO97 Jan 13, 2026
d084ca2
Update docker-image-build.yml
NKO97 Feb 26, 2026
e7af3e1
master: Increased version to 1.0.0-SNAPSHOT
NKO97 Apr 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/docker-image-build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build & Push Multi-Arch Docker Image

on:
workflow_dispatch:
push:
branches:
- master
Expand Down Expand Up @@ -62,4 +63,4 @@ jobs:
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
labels: ${{ steps.meta.outputs.labels }}
4 changes: 1 addition & 3 deletions docker/timaat-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@ for var in "${required_vars[@]}"; do
fi
done
echo "Verify database and create or upgrade schema (if necessary)"
if [ "$(mysql -u"${DATABASE_USER}" -p"${DATABASE_PASSWORD}" -h"${DATABASE_HOST}" -P"${DATABASE_PORT}" -N -s -e \
"SELECT COUNT(*) FROM information_schema.tables WHERE \
table_schema='${DATABASE_SCHEMA_NAME}' AND table_name='db_version';")" -eq 1 ]; then
if [ "$(mysql -u"${DATABASE_USER}" -p"${DATABASE_PASSWORD}" -h"${DATABASE_HOST}" -P"${DATABASE_PORT}" -N -s -e "SELECT COUNT(*) FROM information_schema.tables WHERE table_schema='${DATABASE_SCHEMA_NAME}' AND table_name='db_version';")" -eq 1 ]; then
echo "Database schema already exists. Executing schema update when necessary."
mysql -u"${DATABASE_USER}" -p"${DATABASE_PASSWORD}" -h"${DATABASE_HOST}" -P"${DATABASE_PORT}" ${DATABASE_SCHEMA_NAME} < /var/lib/timmat/sql/db_update.sql
else
Expand Down
8 changes: 7 additions & 1 deletion docs/database.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,10 @@ The versioning of the database schema follows the following pattern:
### 0.15.0

* Added column `thumbnail_position_ms` to table `medium_video` to persist thumbnail position of videos
* Added column `thumbnail_position_ms` to table `annotation` to persist thumbnail position of annotations
* Added column `thumbnail_position_ms` to table `annotation` to persist thumbnail position of annotations

### 0.15.1

* Removed unused column `category_set_id` from table `annotation_has_category`
* Added tables `actor_has_category_set` and `actor_has_category` to link actors with categories
* Added view `analysis_segment_structure_element` which combines information of all segment structure type tables
12 changes: 10 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>TIMAATTest</groupId>
<artifactId>TIMAATTest</artifactId>
<version>0.15.0-SNAPSHOT</version>
<version>1.0.0-SNAPSHOT</version>
<packaging>war</packaging>
<properties>
<!-- <buildDirectory>c:\xampp\tomcat-1\webapps</buildDirectory> -->
Expand All @@ -24,7 +24,9 @@
<version>3.11.0</version>
<configuration>
<release>11</release>
<!-- Remove the conflicting source/target settings -->
<generatedSourcesDirectory>
${project.build.directory}/generated-sources/annotations
</generatedSourcesDirectory>
</configuration>
</plugin>

Expand All @@ -44,6 +46,7 @@
</includes>
</resource>
</webResources>

</configuration>
</plugin>

Expand Down Expand Up @@ -171,6 +174,11 @@
<artifactId>eclipselink</artifactId>
<version>3.0.2</version>
</dependency>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.jpa.modelgen.processor</artifactId>
<version>3.0.2</version>
</dependency>
<!-- https://mvnrepository.com/artifact/jakarta.xml.bind/jakarta.xml.bind-api -->
<dependency>
<groupId>jakarta.xml.bind</groupId>
Expand Down
26 changes: 26 additions & 0 deletions src/main/java/de/bitgilde/TIMAAT/db/DbAccessComponent.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

import java.util.logging.Level;
import java.util.logging.Logger;
import java.util.stream.Stream;

/**
* Components which require database connectivity can extend to this class.
Expand Down Expand Up @@ -43,6 +44,31 @@ protected <RESULT_TYPE> RESULT_TYPE executeDbTransaction(DbTransactionOperation<
}
}

/**
* Exceutes a {@link DbTransactionOperation} having a stream as result
* Always use this when working with {@link Stream}s. Otherwise the db transaction is already closed
* and results can't be gathered.
*
* @param dbTransactionOperation
* @return
* @param <RESULT_TYPE>
* @throws DbTransactionExecutionException
*/
protected <RESULT_TYPE> Stream<RESULT_TYPE> executeStreamDbTransaction(DbTransactionOperation<Stream<RESULT_TYPE>> dbTransactionOperation) throws DbTransactionExecutionException {
logger.log(Level.FINE, "Start execution of db transaction");
EntityManager em = emf.createEntityManager();
try {
em.getTransaction().begin();
Stream<RESULT_TYPE> result = dbTransactionOperation.execute(em);

return result.onClose(em::close);
} catch (Exception e) {
logger.log(Level.SEVERE, "Error in execution of db transaction", e);
em.getTransaction().rollback();
throw new DbTransactionExecutionException(e);
}
}

@FunctionalInterface
public interface DbTransactionOperation<RESULT_TYPE> {
/**
Expand Down
16 changes: 13 additions & 3 deletions src/main/java/de/bitgilde/TIMAAT/di/binder/TIMAATBinder.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,17 @@
import de.bitgilde.TIMAAT.rest.security.authorization.AnnotationAuthorizationVerifier;
import de.bitgilde.TIMAAT.rest.security.authorization.DbAnnotationAuthorizationVerifier;
import de.bitgilde.TIMAAT.sse.EntityUpdateEventService;
import de.bitgilde.TIMAAT.storage.entity.AnnotationStorage;
import de.bitgilde.TIMAAT.storage.entity.actor.ActorStorage;
import de.bitgilde.TIMAAT.storage.entity.analysislist.AnalysisListStorage;
import de.bitgilde.TIMAAT.storage.entity.annotation.AnnotationStorage;
import de.bitgilde.TIMAAT.storage.entity.AudioAnalysisResultStorage;
import de.bitgilde.TIMAAT.storage.entity.MediumStorage;
import de.bitgilde.TIMAAT.storage.entity.CategorySetStorage;
import de.bitgilde.TIMAAT.storage.entity.CategoryStorage;
import de.bitgilde.TIMAAT.storage.entity.medium.MediumStorage;
import de.bitgilde.TIMAAT.storage.entity.MediumVideoStorage;
import de.bitgilde.TIMAAT.storage.entity.MusicStorage;
import de.bitgilde.TIMAAT.storage.entity.music.MusicStorage;
import de.bitgilde.TIMAAT.storage.entity.TagStorage;
import de.bitgilde.TIMAAT.storage.entity.segment.SegmentStructureElementsStorage;
import de.bitgilde.TIMAAT.storage.file.AnnotationFileStorage;
import de.bitgilde.TIMAAT.storage.file.AudioFileStorage;
import de.bitgilde.TIMAAT.storage.file.ImageFileStorage;
Expand Down Expand Up @@ -74,9 +79,14 @@ protected void configure() {
bindAsContract(MusicStorage.class).in(Singleton.class);
bindAsContract(AnnotationStorage.class).in(Singleton.class);
bindAsContract(TagStorage.class).in(Singleton.class);
bindAsContract(ActorStorage.class).in(Singleton.class);
bindAsContract(MediumStorage.class).in(Singleton.class);
bindAsContract(AnalysisListStorage.class).in(Singleton.class);
bindAsContract(MediumVideoStorage.class).in(Singleton.class);
bindAsContract(AnnotationFileStorage.class).in(Singleton.class);
bindAsContract(CategoryStorage.class).in(Singleton.class);
bindAsContract(CategorySetStorage.class).in(Singleton.class);
bindAsContract(SegmentStructureElementsStorage.class).in(Singleton.class);

bind(DbAnnotationAuthorizationVerifier.class).to(AnnotationAuthorizationVerifier.class).in(Singleton.class);
bindAsContract(AnalysisListAuthorizationVerifier.class).in(Singleton.class);
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/de/bitgilde/TIMAAT/model/DataTableInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,20 @@
/**
* @author Mirko Scherf <mscherf@uni-mainz.de>
*/
public class DataTableInfo {
public class DataTableInfo<ENTITY_TYPE> {

public int draw;
public long recordsTotal;
public long recordsFiltered;

public List<?> data;
public List<ENTITY_TYPE> data;


public DataTableInfo() {

}

public DataTableInfo(int draw, long recordsTotal, long recordsFiltered, List<?> data) {
public DataTableInfo(int draw, long recordsTotal, long recordsFiltered, List<ENTITY_TYPE> data) {
this.draw = draw;
this.recordsTotal = recordsTotal;
this.recordsFiltered = recordsFiltered;
Expand Down
50 changes: 44 additions & 6 deletions src/main/java/de/bitgilde/TIMAAT/model/FIPOP/Actor.java
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
package de.bitgilde.TIMAAT.model.FIPOP;

import java.io.Serializable;
import java.sql.Timestamp;
import java.util.List;
import java.util.Objects;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonManagedReference;
import com.fasterxml.jackson.annotation.JsonProperty;

import jakarta.persistence.CascadeType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
Expand All @@ -25,6 +19,11 @@
import jakarta.persistence.OneToOne;
import jakarta.persistence.Transient;

import java.io.Serializable;
import java.sql.Timestamp;
import java.util.List;
import java.util.Objects;

/*
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -136,6 +135,30 @@ public class Actor implements Serializable {
)
private List<Role> roles;

@ManyToMany
@JoinTable(
name="actor_has_category_set"
, joinColumns={
@JoinColumn(name="actor_id")
}
, inverseJoinColumns={
@JoinColumn(name="category_set_id")
}
)
private List<CategorySet> categorySets;

@ManyToMany
@JoinTable(
name="actor_has_category"
, joinColumns={
@JoinColumn(name="actor_id")
}
, inverseJoinColumns={
@JoinColumn(name="category_id")
}
)
private List<Category> categories;

//bi-directional many-to-many association to Medium_Image
@ManyToMany
@JoinTable(
Expand Down Expand Up @@ -568,4 +591,19 @@ public void setTags(List<Tag> tags) {
this.tags = tags;
}

public List<Category> getCategories() {
return categories;
}

public void setCategories(List<Category> categories) {
this.categories = categories;
}

public List<CategorySet> getCategorySets() {
return categorySets;
}

public void setCategorySets(List<CategorySet> categorySets) {
this.categorySets = categorySets;
}
}
30 changes: 22 additions & 8 deletions src/main/java/de/bitgilde/TIMAAT/model/FIPOP/AnalysisAction.java
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
package de.bitgilde.TIMAAT.model.FIPOP;

import java.io.Serializable;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;

import jakarta.persistence.CascadeType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
Expand All @@ -21,6 +18,9 @@
import jakarta.persistence.Table;
import jakarta.persistence.Transient;

import java.io.Serializable;
import java.util.List;

/*
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -43,7 +43,7 @@
@Entity
@Table(name="analysis_action")
@NamedQuery(name="AnalysisAction.findAll", query="SELECT a FROM AnalysisAction a")
public class AnalysisAction implements Serializable {
public class AnalysisAction implements Serializable, SegmentStructureEntity {
private static final long serialVersionUID = 1L;

@Id
Expand Down Expand Up @@ -114,19 +114,33 @@ public long getStartTime() {
return this.startTime;
}

public void setStartTime(long startTime) {
@JsonIgnore
@Override
public String getName() {
return analysisActionTranslations.get(0).getName();
}

public void setStartTime(long startTime) {
this.startTime = startTime;
}

@Override
public List<Category> getCategories() {
return this.categories;
}

@Override
public void setCategories(List<Category> categories) {
this.categories = categories;
}

public AnalysisScene getAnalysisScene() {

@JsonIgnore
@Override
public MediumAnalysisList getMediumAnalysisList() {
return getAnalysisScene().getAnalysisSegment().getMediumAnalysisList();
}

public AnalysisScene getAnalysisScene() {
return this.analysisScene;
}

Expand Down
28 changes: 21 additions & 7 deletions src/main/java/de/bitgilde/TIMAAT/model/FIPOP/AnalysisScene.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
package de.bitgilde.TIMAAT.model.FIPOP;

import java.io.Serializable;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonManagedReference;
import com.fasterxml.jackson.annotation.JsonProperty;

import jakarta.persistence.CascadeType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
Expand All @@ -22,6 +19,9 @@
import jakarta.persistence.Table;
import jakarta.persistence.Transient;

import java.io.Serializable;
import java.util.List;

/*
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -44,7 +44,7 @@
@Entity
@Table(name="analysis_scene")
@NamedQuery(name="AnalysisScene.findAll", query="SELECT a FROM AnalysisScene a")
public class AnalysisScene implements Serializable {
public class AnalysisScene implements Serializable, SegmentStructureEntity {
private static final long serialVersionUID = 1L;

@Id
Expand Down Expand Up @@ -120,19 +120,33 @@ public long getStartTime() {
return this.startTime;
}

public void setStartTime(long startTime) {
@JsonIgnore
@Override
public String getName() {
return analysisSceneTranslations.get(0).getName();
}

public void setStartTime(long startTime) {
this.startTime = startTime;
}

@Override
public List<Category> getCategories() {
return this.categories;
}

@Override
public void setCategories(List<Category> categories) {
this.categories = categories;
}

public List<AnalysisAction> getAnalysisActions() {
@JsonIgnore
@Override
public MediumAnalysisList getMediumAnalysisList() {
return analysisSegment.getMediumAnalysisList();
}

public List<AnalysisAction> getAnalysisActions() {
return this.analysisActions;
}

Expand Down
Loading
Loading