aerie icon indicating copy to clipboard operation
aerie copied to clipboard

Remove merlin-server as a dependency of orchestration-utils

Open mattdailis opened this issue 6 months ago • 2 comments

  • Tickets addressed: N/A
  • Review: By commit
  • Merge strategy: Merge (no squash)

Description

This is a follow-up to #1700

Currently, users cannot use orchestration-utils without pulling in merlin-server. We don't typically publish merlin-server (#1700 was an exception to that). This PR removes merlin-server from the orchestration-utils dependencies.

There were four things in merlin-server that orchestration-utils needed:

  • pgTimestampP
  • activityArgumentsP
  • simulationArgumentsP
  • realDynamicsP
  • EventGraphFlattener

This PR creates a new Parsers.java file under the gov.nasa.jpl.aerie.merlin.driver.json and moves the four parsers above from merlin-server to this new file.

This PR moves EventGraphFlattener into gov.nasa.jpl.aerie.merlin.driver.timeline alongside the definition of EventGraph itself.

Verification

It compiles!

Documentation

I couldn't find any docs on stateless aerie - if someone knows otherwise, let me know.

Future work

There are a number of duplicated parsers and parsing functions across merlin-server and scheduler-server. I think we can take a careful look at them and move some of them to this new Parsers.java class.

There are a few copy/pasted implementations of the parseJson function that I think can be unified by adding a static method to JsonParser in parsing-utilities. I took a stab at that, but then decided that it would be better for this PR to be minimal. That first attempt is in the branch called dailis/orchestration-utils-dependency-refactor-take-1

mattdailis avatar Jun 26 '25 20:06 mattdailis

Quality Gate Failed Quality Gate failed

Failed conditions
29.7% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

sonarqubecloud[bot] avatar Jun 26 '25 20:06 sonarqubecloud[bot]

Quality Gate Failed Quality Gate failed

Failed conditions
29.7% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

sonarqubecloud[bot] avatar Aug 13 '25 22:08 sonarqubecloud[bot]