Give Agents Faster Turnaround with Dev Loop
- What You Need
- 1. Get the Base Application
- 2. Install the CLI and the Skills
- 3. Give the Agent Vaadin’s Documentation
- 4. Start the Loop
- 5. Let the Agent Work
- 6. Measure the Turnaround
- What You Built
- Troubleshooting
- Related Topics
|
Note
|
Preview Feature
The Dev Loop CLI is a preview feature. This means that it is not yet ready for production usage and may have limitations or bugs. We encourage you to try it out and provide feedback to help us improve it. |
An AI coding agent is quick at writing a change and slow at finding out whether it worked. Left alone, it rebuilds the project, restarts the application, and waits for it to come up. Then it takes a screenshot and reasons about a picture to decide whether its change landed. Every round trip costs wall-clock time. It also costs tokens: the agent re-reads startup output and rebuilds state that the application had a moment earlier.
Dev Loop cuts that round trip down to one command. The agent edits, runs apply, and has an answer within seconds. The exit code says whether the change is live. The line under it names what happened: a hot swap, a push into the open page, a restart, or a failure. The application keeps running between changes, so the agent doesn’t pay to warm it up again.
In this tutorial, you set up Dev Loop on a generated Vaadin starter and hand the application to Claude Code or Codex. The agent makes three changes of increasing size:
-
a stylesheet tweak
-
a change to a view
-
a feature that spans several files
None of them needs a restart by hand, or a screenshot to confirm. At the end, you measure the turnaround against the same work done with ordinary restarts, on your own project.
Nothing here is agent-only. Every command below is one you can run yourself, and you get the same answers. What the agent gets is a loop it can close on its own.
What You Need
-
Java 21 or newer
-
A JetBrains Runtime, strongly recommended. Without one, more of your edits restart the application instead of hot-swapping, and the agent’s turnaround suffers. Download a JBRSDK build from the JetBrains Runtime releases page, at your project’s Java version or newer, and extract it into
~/.jdks/. -
Maven, as
mvnon the path or as the wrapper in the project -
Network access the first time you install
-
Claude Code or Codex CLI, installed and signed in
See Prerequisites for the details of each.
1. Get the Base Application
Open Vaadin Start and keep the sample view. Dev Loop needs a recent enough platform version, so expand Configure Project Settings and check which version the project uses. Download the project, extract it, and open it in your IDE.
You get a small Spring Boot and Maven application — a task list, with a grid of tasks, a toolbar for creating them, and a stylesheet:
Source code
src/main/java/com/example/
Application.java
base/ui/MainLayout.java the shell: header, side nav, footer
examplefeature/
Task.java the JPA entity
TaskRepository.java
TaskService.java
ui/TaskListView.java the view at /
src/main/resources/
META-INF/resources/styles.css the application's own CSS
application.propertiesEach of the three changes in Step 5 targets a different one of those, because each produces a different result from Dev Loop.
Check two things in pom.xml before going further. First, that the version you picked came through:
Source code
XML
<properties>
<vaadin.version>25.4.0-beta4</vaadin.version>
</properties>Second, confirm that the vaadin-dev dependency is present. It’s what the CLI resolves the daemon from, and a generated starter already declares it:
Source code
XML
<dependency>
<groupId>com.vaadin</groupId>
<artifactId>vaadin-dev</artifactId>
<optional>true</optional>
</dependency>The <optional>true</optional> keeps it out of your production build.
2. Install the CLI and the Skills
One goal installs both:
Source code
bash
mvn vaadin:install-dev-cliRun it in the directory that holds your application’s pom.xml. It writes the CLI into .vaadin/, and the skills into .agents/skills/ and .claude/skills/.
There’s no separate step for installing the skills, and nothing to configure per agent. Claude Code discovers skills in .claude/skills/, and Codex discovers them in .agents/skills/, so the single goal above covers both — and any other agent that follows either convention.
Commit all of it, the way you commit mvnw, so that every developer and every agent working on the repository gets the same instructions. See Installing the CLI for what else the goal does, and for installing without network access.
3. Give the Agent Vaadin’s Documentation
This step is optional, but it’s worth the two minutes. Vaadin adds API faster than a model’s training data is refreshed, so an agent working from memory writes plausible code against methods that don’t exist. The Vaadin MCP server answers from the real documentation for the version in your pom.xml.
Source code
terminal
/plugin marketplace add vaadin/agent-marketplace
/plugin install vaadin-skills@vaadin-marketplaceterminal
terminal
terminal
One plugin installs the MCP server and a set of Vaadin development skills together. For manual configuration, or for any other tool, see Claude Code, Codex, or the MCP Server overview.
While you’re here, add a browser automation tool. A Playwright MCP server is the usual choice. The Dev Loop skills expect one for verifying changes that have a visual surface, but they don’t install it. Without one, the agent falls back to your project’s own browser tests, and says that’s what it did.
4. Start the Loop
Ask what’s running, and then start it:
Source code
bash
.vaadin/vaadin-dev status
.vaadin/vaadin-dev startThe status command costs milliseconds, as it starts no JVM. The start command takes roughly 30 seconds cold, and blocks until the application is serving or has failed.
On Windows, use .vaadin\vaadin-dev.cmd instead. See The Cycle for the launchers.
Now open http://localhost:8080 and leave the page open. This matters more than it looks: a stylesheet push has somewhere to land only if a page is already connected. Run apply with no page open, and it reports the file copied to the classpath and says nothing about a push — honest, but not the answer you came for. Open the page before the first change, not after.
From now on, the daemon owns the application’s process. Don’t also start the application with spring-boot:run or an IDE run configuration, since a second launcher fights the daemon for port 8080.
5. Let the Agent Work
Start your agent in the project directory, and give it the prompts below one at a time. Each produces a different outcome, and each comes back verified without a restart by hand. The time on the compiling line is the agent’s turnaround for the change.
You don’t need to mention Dev Loop in the prompt. The installed skill tells the agent to use it, and to treat an edit that hasn’t been applied as unfinished.
A Stylesheet Change
Example prompt:
-
"Give the task list more breathing room: more vertical padding in the grid rows, and make the Create button full width on narrow screens."
The agent edits src/main/resources/META-INF/resources/styles.css, and applies. Expect this:
Source code
change-set: 1 file(s): src/main/resources/META-INF/resources/styles.css
compiling → runtime → Stable (0.4s)
hmr: 1 resource(s) copied, pushed 1 stylesheet(s) in placeWatch the browser: the spacing changes without the page reloading. Your session, your scroll position, and anything you’d typed into the form are all still there.
A Change to a View
Example prompt:
-
"Rename the Create button to Add Task, and show a notification with the task’s due date when a grid row is clicked."
This one edits TaskListView, a view class, so the new bytecode is swapped into the running JVM:
Source code
change-set: 1 file(s): src/main/java/com/example/examplefeature/ui/TaskListView.java
compiling → runtime → Stable (1.2s)
hot-reload: redefineClasses(1); onHotswap completed=trueAgain, no restart and no reload.
You may instead see → live, but no Vaadin component was redefined under the hot-reload: line. That isn’t a failure: the new bytecode is live, but Flow had nothing to refresh, typically because the affected output was rendered on the server and pushed once already. Interact with the view, or reload the page. Don’t apply again — there’s nothing left to compile.
A Feature Across Several Files
Example prompt:
-
"Add a priority to tasks: Low, Normal, or High. Store it with the task, show it as a sortable grid column, and let the user pick one when creating a task."
Now the agent touches Task, TaskService, and TaskListView. It should make all of those edits and then apply once: apply finds the change-set itself by scanning the sources, so running it per file wastes a cycle each time.
A changed JPA mapping never hot-reloads, because Hibernate fixes its metamodel and schema at startup, so Dev Loop escalates:
Source code
change-set: 3 file(s): .../Task.java, .../TaskService.java, .../ui/TaskListView.java
compiling → runtime → restarting → Stable (9.8s)Reload the page to see it. The escalation is the point: rather than report a hot swap that didn’t take, Dev Loop does the thing that works and names it. Everything the agent needs to know is in that one line.
|
Note
|
Source codeRead the error before treating the change as working. A well-behaved agent does the same. |
|
Tip
|
If you watch the agent’s tool calls, you shouldn’t see mvn compile, mvn test, or mvn spring-boot:run between edits. A Maven cycle pays for a fresh JVM and a fresh Spring context to answer a narrower question than apply answers against the application that’s already running. Running the test suite once at the end, over the change as a whole, is a different matter, and still worth doing.
|
6. Measure the Turnaround
The faster turnaround should show up in the whole session, as less wall-clock time and as fewer tokens spent after each restart. You can check that on your own project rather than taking anyone’s word for it.
Use the same prompt, the same model, and two clean copies of the project:
-
Baseline. Start the application with
mvn spring-boot:run, and let the agent restart it however it likes. Run the prompt in a fresh session. -
Dev Loop. Start the application with
.vaadin/vaadin-dev start, and run the same prompt in another fresh session.
Read the session total at the end of each:
| Tool | Command | What It Reports |
|---|---|---|
Claude Code |
| Session cost, API and wall-clock duration, and tokens per model. |
Claude Code |
| Usage against your plan limits. |
Codex |
| Model and token usage for the current window. No cost figure. |
Codex |
| Token activity over time. Requires Codex CLI 0.140.0 or later. |
Either |
| Costs in dollars, read from the local session logs. Codex is supported as a beta data source. |
Three numbers are worth comparing: wall-clock time, total cost, and cache-read tokens. The last one explains the other two. Every restart throws away a warm application and makes the agent re-establish context it had already paid for — recreating test data in an in-memory database, re-reading files, and reasoning about startup output. The longer the session, the more of that Dev Loop avoids.
A few things to be fair about when you read your own numbers:
-
One run per scenario is noise. Model sampling varies more than the effect you’re measuring on a single small change. Run a realistic multi-step session, not a one-liner.
-
A compile error can be slower under
apply, which recompiles only the change-set. An edit that splits across files can surface at runtime rather than at compile time, and cost a turn to diagnose. -
Some changes restart either way. Structural changes to Spring beans, JPA mappings, and non-theme frontend files restart under Dev Loop too, as the third prompt above demonstrated. The saving comes from everything else.
-
Annotation processors don’t run in Dev Loop, so a project using Lombok or MapStruct needs
mvn compile. See Limitations before drawing conclusions from a project that uses one.
What You Built
-
An agent that verifies each change in seconds: it edits, applies, reads a verdict, and knows the difference between a hot swap, a restart, and a failure.
-
An application that stays warm between changes, running under a daemon that owns its process instead of under Maven or an IDE.
-
A CLI and a set of agent skills committed to the project, so that every agent and every developer on it works the same way.
-
A measurement of the turnaround you can repeat on your own project, rather than a claim.
Troubleshooting
its network source differs from the one declared for it in settings-
Claude Code already has a marketplace named
vaadin-marketplacewith a different source, such as the deprecatedvaadin/claude-plugin. Remove it, add the marketplace again, and reinstall the plugin, which the removal disabled:Source code
terminal
/plugin marketplace remove vaadin-marketplace /plugin marketplace add vaadin/agent-marketplace /plugin install vaadin-skills@vaadin-marketplace
For problems with Dev Loop itself, see Troubleshooting in the reference, or the reference.md installed next to the skill, which documents every outcome Dev Loop can report.
Related Topics
-
Dev Loop CLI — the complete command and output reference
-
MCP Server for Vaadin — documentation lookup for AI coding agents
-
Hot Deploy & Live Reload — the other ways to get changes into a running application