Release Management
Relevant source files
The following files were used as context for generating this wiki page:
Release management in the Wikispeech project encompasses the automated processes for tagging version releases across multiple microservices, validating builds through comprehensive integration tests, and managing deployment configurations. The system is designed to synchronize versioning across a distributed architecture involving text-to-speech (TTS) engines, lexicon servers, and symbol set mappers.
Sources: mk_release.sh:1-15, build_and_test.sh:1-10
Release Automation and Tagging
The project uses a specialized script, mk_release.sh, to coordinate releases across the ecosystem. This script ensures that version tags are consistent across the primary repository and its dependent sub-projects.
Versioning Logic
The release process uses a tagging convention where numeric inputs are prefixed with 'v' (e.g., 0.3.0 becomes v0.3.0). The script performs the following primary actions:
- Tag Updates: Automatically updates hardcoded release tags in CI/CD configurations (
.travis.yml) and build scripts (build_and_test.sh). - Multi-Repo Synchronization: Applies the generated tag to five distinct repositories:
pronlex,wikispeech-server,marytts,symbolset, andwikispeech-lexdata. - Release Note Integration: Directs developers to update the central release notes hosted at
stts-se.github.io/wikispeech/release_notes.html.
Sources: mk_release.sh:15-20, mk_release.sh:50-65, mk_release.sh:70-85
Release Workflow
The following diagram illustrates the sequence of operations performed during a release cycle:
Sources: mk_release.sh:45-95
Build Validation and Integration Testing
Before any release or pull request, developers must execute build_and_test.sh. This script mimics CI environment tests by spinning up the entire microservice stack and verifying inter-service communication.
Component Validation
The build script validates the following services in order:
- Symbolset: Clones and checks out the specific release branch, sets up dependencies, and starts the server.
- Pronlex: Configures a Go environment, imports lexicon data into an SQLite database, and launches the lexicon server.
- MaryTTS: Runs Gradle checks and tests, installs STTS-specific voices, and starts the Java-based TTS engine.
- Wikispeech Server: Launches the main Flask application using a specific test configuration.
Sources: build_and_test.sh:35-100
Integration Check Table
| Service | Validation Method | Cleanup Action |
|---|---|---|
| Symbolset | go run *.go | Process Kill by name |
| Pronlex | bash scripts/start_server.sh | Process Kill by name |
| MaryTTS | ./gradlew check && ./gradlew test | Process Kill by name |
| Wikispeech | python3 bin/wikispeech | .travis/exit_server_and_fail_if_not_running.sh |
Sources: build_and_test.sh:15-30, build_and_test.sh:105-115
Environment Management
Release management also involves ensuring that the runtime environment is correctly configured for the new version. The start_wikispeech.sh script facilitates this by managing paths and service dependencies.
Dependency Resolution
The system identifies the root folders for all git repositories (symbolset, pronlex, tts-wrappers) to ensure that the correct version of each microservice is active. It also handles the clearing of the audio cache during startup to prevent version conflicts in generated speech files.
Sources: start_wikispeech.sh:15-30, start_wikispeech.sh:115-125
Service Startup Sequence
Sources: start_wikispeech.sh:95-135
Version Information API
The Wikispeech server provides a /version endpoint that exposes release metadata at runtime. This allows for verification of the currently deployed version.
Metadata Extraction
The server attempts to retrieve versioning info in the following order:
- Build Info File: Checks
/wikispeech/wikispeech_server/build_info.txt. - Git Metadata: If the file is missing, it executes
git describe --tagsandgit rev-parse --abbrev-ref HEADto determine the current tag and branch. - Runtime Info: Appends the
startedAttimestamp to the release data.
Sources: wikispeech_server/wikispeech.py:100-135
Summary
Release management in Wikispeech is a strictly coordinated process that relies on shell automation to synchronize tags across five repositories. By forcing integration tests through build_and_test.sh and providing automated startup scripts like start_wikispeech.sh, the project ensures that the microservice architecture remains consistent and verifiable across different release versions.