Watch
1
0
Fork
You've already forked siard-suite
0
mirror of https://github.com/sfa-siard/siard-suite.git synced 2026-08-17 12:42:31 +00:00
Read-only mirror of https://github.com/sfa-siard/siard-suite — Schweizerisches Bundesarchiv. Issues & pull requests at the source. Catalog: https://www.opensource.admin.ch/en/softwares/wa9g41 https://www.opensource.admin.ch/en/softwares/wa9g41
  • Java 89.7%
  • HTML 5.4%
  • CSS 3.1%
  • ANTLR 0.9%
  • Batchfile 0.3%
  • Other 0.4%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-08-17 10:24:49 +02:00
.github/workflows fix: update pattern for deliverables action 2026-03-23 17:14:38 +01:00
.idea doc: software architecture document 2024-04-24 10:48:44 +02:00
docker fix: syntax error in docker-compose.yaml 2026-06-25 08:01:52 +02:00
docs doc: add AGENTS.md, add refactoring plan (#168) 2026-06-26 09:19:48 +02:00
gradle chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-access fix: java error when creating archive (#173) 2026-08-17 10:22:46 +02:00
jdbc-base chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-db2 chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-mssql chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-mysql chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-oracle chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
jdbc-postgres chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
scripts chore: remove method end and divider comments (#159) 2026-03-23 17:26:46 +01:00
siard-api chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
siard-cmd fix: java error when creating archive (#173) 2026-08-17 10:22:46 +02:00
siard-suite-app chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
siard-utilities chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
sql-parser chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
zip64-file chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
.git-blame-ignore-revs chore: add last commit to .git-blame-ignore-revs 2026-03-13 12:54:35 +01:00
.gitignore chore(all): cleanup .gitignore files 2026-01-09 14:46:40 +01:00
.tool-versions chore: upgrade java in .tool-versions 2025-09-08 16:55:21 +02:00
AGENTS.md chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
build.gradle.kts chore: improve and consolidate logging (#172) 2026-06-29 08:50:06 +02:00
CHANGELOG.md release: 2.2.167 2026-08-17 10:24:49 +02:00
gradlew chore: initialize gradle project from maven pom 2022-10-13 10:38:31 +02:00
gradlew.bat chore: initialize gradle project from maven pom 2022-10-13 10:38:31 +02:00
LICENSE.txt Create LICENSE.txt 2022-09-14 13:11:43 +02:00
publiccode.yml chore: fix software name in publiccode.yml 2025-10-24 16:10:05 +02:00
README.md chore(all): use gradle version catalog (#161) 2026-03-27 12:55:52 +01:00
release-guide.md chore: migrate to Java 17 2025-09-02 12:45:37 +02:00
settings.gradle.kts chore(siard-utilities): rename module 2026-01-17 20:10:58 +01:00
user-manual.pdf feat: Enables editing of metadata in SIARD archives 2023-10-31 08:53:45 +01:00

SIARD Suite 2.2

About

SIARD Suite is a comprehensive toolset for archiving relational databases in the SIARD (Software-Independent Archival of Relational Databases) format. The suite ensures long-term preservation and accessibility of database contents, independent of the original database management system.

Key Features:

  • Graphical Interface: User-friendly GUI for archiving, restoring, searching, and exporting databases
  • Command-Line Tools: Powerful CLI for automated workflows and scripting
  • Multi-Database Support: Compatible with PostgreSQL, MySQL, Oracle, MS SQL Server, DB2, and MS Access
  • SIARD Format 2.2: Compliant with the latest SIARD standard for database archival

Project Structure: This is a Gradle-based monorepo containing multiple modules:

  • siard-suite-app - Desktop application with GUI
  • siard-cmd - Command-line interface
  • siard-api - Core API for reading/writing SIARD files
  • jdbc-* - Database-specific JDBC wrappers
  • Supporting libraries and utilities

Developer Setup

Prerequisites

Java 17 with JavaFX is required. Download from:

For asdf users:

asdf install

Docker is required for running integration tests (uses Testcontainers).

Running the Application

GUI Application:

./gradlew :siard-suite-app:run

Command-Line Interface:

First, build the distribution:

./gradlew :siard-cmd:installDist

Then run the CLI tools:

# Download database to SIARD archive
./siard-cmd/build/install/siard-cmd/bin/siard-from-db <arguments>

# Upload SIARD archive to database
./siard-cmd/build/install/siard-cmd/bin/siard-to-db <arguments>

Code Formatting & Git Blame

We recently performed a bulk reformatting of the entire Java codebase to standardize our style. To avoid seeing "style-only" changes when using git blame, we use a .git-blame-ignore-revs file. This file contains the commit hashes of the formatting commits. Github will automatically use this file and does not show the formatting commits in the blame.

To ignore these formatting commits in your local terminal or IDE, run the following command once in the project root:

git config blame.ignoreRevsFile .git-blame-ignore-revs

Building the Project

Build all modules:

./gradlew clean build -x test

Note: running all tests takes quite long!

Build specific module:

./gradlew :module-name:build

The build creates distributions in build/distributions/ with executable scripts and all dependencies.

Running Tests

Run all tests:

./gradlew test

Run tests for a specific module:

./gradlew :module-name:test

Examples:

./gradlew :siard-api:test           # Core API tests
./gradlew :jdbc-postgres:test       # PostgreSQL wrapper tests
./gradlew :siard-cmd:test           # CLI tests

Integration tests (siard-cmd):

./gradlew :siard-cmd:integrationTest                    # All integration tests
./gradlew :siard-cmd:integrationTestPostgres            # PostgreSQL only
./gradlew :siard-cmd:integrationTestMysql               # MySQL only

Note: all tests require Docker to be running (uses Testcontainers).

Dependency Analysis

The project uses the Dependency Analysis Gradle Plugin to detect dependency issues.

Analyze all dependencies:

./gradlew buildHealth

This generates a report showing:

  • Unused dependencies: Dependencies declared but not actually used in code
  • Used transitive dependencies: Dependencies used in code but not explicitly declared
  • Misused dependencies: Dependencies that should use a different configuration (e.g., api instead of implementation)

View the report:

# Console output shows summary
./gradlew buildHealth

# Detailed HTML report
open build/reports/dependency-analysis/build-health-report.html

Fix issues automatically (where possible):

./gradlew buildHealth --auto-correct

Analyze a specific module:

./gradlew :module-name:buildHealth

Note: The plugin may suggest removing dependencies that are actually needed as transitive dependencies. Always verify suggestions before applying them.

Creating Platform-Specific Packages

Create application image:

./gradlew jpackageImage

The image will be available at ./build/jpackage/siard-suite (OS-specific).

Create installer:

./gradlew jpackage

Creates platform-specific installers (DMG, EXE, MSI, DEB, or RPM).

Ubuntu users: Install alien if RPM building fails:

sudo apt install alien

Versioning and Releases

⚠️ Read the release guide before creating releases!

Versions follow the SIARD format version (2.2.x) and are managed with the Axion Release Plugin.

Check current version:

./gradlew currentVersion

Create a release:

./gradlew release

This creates a tag and pushes it to remote, triggering GitHub Actions to build deliverables.

Note: Official GitHub releases must be created manually by BAR.

Documentation

Documentation is written in AsciiDoc and bundled with the application.

Generate PDF documentation:

./gradlew :siard-suite-app:asciidoctorPdf

Available Documentation:

Declaration

Contributions to the codebase have been made with the support of Windsurf. Windsurf is AI-powered code completion tool, that is trained exclusively on natural language and source code data with permissive licenses.