feat: API implementation and Docker artifact publishing#1
Open
davidgamez wants to merge 8 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR adds the first stable implementation of the OpenAPI schema. The implementation uses the https://github.com/openapitools/openapi-generator Maven plugin to generate most of the code and interfaces. The core validator functionality is located in the official GTFS validator repository.
Out of scope
completeandheavyenough to review.From our AI friend
This pull request introduces the initial setup for the GTFS Validator API project, providing a production-ready, containerized, and CI-integrated Spring Boot HTTP API for the MobilityData Canonical GTFS Schedule Validator. The changes establish the build system, code formatting, Dockerization, continuous integration workflows, and detailed documentation, as well as the application entry point.
The most important changes are:
Build System and Dependency Management
pom.xmlconfiguring the project as a Spring Boot application, managing dependencies (including the validator core and patched transitive dependencies), plugins for OpenAPI code generation, code formatting (Spotless with google-java-format), and resource handling. The build also integrates the OpenAPI spec and sets up code style enforcement.Dockerization
Dockerfileto build and package the application as a minimal, production-ready container image, running as a non-root user and exposing configuration viaJAVA_OPTS..dockerignorefile to exclude unnecessary files and directories from Docker build context, improving build efficiency and security.Continuous Integration
.github/workflows/build.ymlfor building, testing, and enforcing code style on every push, pull request, or manual trigger..github/workflows/docker.ymlworkflow to build and publish multi-arch Docker images to GitHub Container Registry on pushes, tags, releases, and pull requests.OpenAPI Code Generation
.openapi-generator-ignoreto prevent overwriting custom source files during OpenAPI code generation, ensuring maintainability of hand-written code.Documentation and Entry Point
README.mddescribing the project, endpoints, build/test instructions, Docker usage, CI/CD processes, configuration, and project structure.src/main/java/org/mobilitydata/gtfsvalidator/api/Application.javafor the Spring Boot service.