💡 Inspiration
Maintaining software plugins is a tedious chore. When an upstream project (like Elasticsearch) releases a new major version, internal APIs break. Developers are forced to manually read changelogs, hunt down deprecated Java methods, bump dependency versions, and test the refactor. We wanted to eliminate this SDLC bottleneck by building a "digital teammate" that handles compatibility upgrades entirely autonomously.
⚙️ What it does
ZERO Maintenance Plugin Keeper is a GitLab Duo Agentic Flow that automatically upgrades plugin repositories to match new upstream base versions.
When triggered via a GitLab Issue, the agent:
- Reads Upstream Context: Analyzes a Knowledge Graph of breaking changes from the upstream repository.
- Scans the Codebase: Reads
.tool-versions,pom.xml, and Java source files to identify deprecated APIs. - Executes Coding Actions: Autonomously refactors the deprecated code to comply with the new base version.
- Reports & Submits: Creates a commit and opens a Merge Request. The MR description includes a detailed Compatibility Report explaining exactly what APIs were changed and why.
- Validates: The new MR automatically triggers the CI/CD pipeline to build the artifact and run an agentic simulation test.
🛠️ How we built it
We built this entirely on the GitLab Duo Agent Platform using Anthropic's Claude models.
- The Flow: We created a Custom Flow configured to trigger whenever the agent's service account is mentioned in an issue (e.g., "Upgrade to 8.12").
- The Agent: We designed a custom Agent equipped with native GitLab tools:
read_file,create_commit, andcreate_merge_request. - The Context: We used an
AGENTS.mdfile and a simulated upstream Knowledge Graph document to ground the AI, ensuring it knew exactly which APIs were deprecated without hallucinating.
⚠️ Challenges we ran into
The biggest challenge was context management. Asking an LLM to clone and read the entire Elasticsearch source repository to figure out what changed is impossible due to context window limits and CI timeouts. We solved this by implementing a "Knowledge Graph" approach—feeding the agent a structured markdown representation of the upstream breaking changes, which allowed it to execute the refactoring flawlessly and quickly.
🧠 What we learned
We learned how to orchestrate multi-step AI workflows using the new GitLab Duo Flow YAML schema. We also discovered that providing highly structured context (like an AGENTS.md file) drastically improves the agent's ability to navigate a repository and write accurate, compilable Java code.
🚀 What's next for ZERO Maintenance Plugin Keeper
Currently, the upstream Knowledge Graph is static. Our next step is to build an independent "Tracker Agent" that watches upstream repositories (like elastic/elasticsearch), dynamically generates the breaking-changes Knowledge Graph on release day, and automatically triggers the Plugin Keeper flow across all dependent plugin repositories in an organization.
Built With
- gitlab
Log in or sign up for Devpost to join the conversation.