Simplify Runner further
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 85
- Forks
- 26
- Avg merge
- 11h 49m
- Merged PRs (30d)
- 22
Description
Hello!
- Vote on this issue by adding a 👍 reaction
- If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)
Issue details
Previously in ##642 I've decoupled Stack and Runner and simplified both.
As kindly suggested by @t0yv0 we have an opportunity to simplify Runner even further:
- https://github.com/pulumi/pulumi-java/pull/642/files#r889038759 - try to achieve
<T> CompletableFuture<T> runAsync(Supplier<T> callback);signature or evenCompletableFuture<Void> run()if it does not break the semantics. - we can move the exit code related error handling to the
PulumiInternaland expose it only inPulumibecause it is only useful for the CLI, but not inPulumiTestandPulumiAuto.
This has implications for the Pulumi, PulumiTest and PulumiAuto APIs (because we need to expose to the user all things needed but not more):
- since the exit code is not useful for the user and is internal-ish, we could stop exposing it in the
Result(an maybe removeResult) - knowing what errors and exceptions happened is useful for PulumiTest
- knowing what exceptions happened is useful for PulumiAuto, but maybe better semantics would be to just throw on
join? - mimicking
pulumicommand can also be useful considerations for better DX: https://github.com/pulumi/pulumi-java/pull/642/files#r888932515
This issue can benefit from more careful consideration regarding consistency in the semantics between different flavours of the API as well as from considering inherent similarities and differences between various modes of operation.
Affected area/feature
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing pull request 642 and its linked comments, then trace the Runner, PulumiInternal, Pulumi, PulumiTest, PulumiAuto, and Result APIs named in the issue. Done requires an agreed design and consistent semantics for asynchronous execution, exit-code handling, and exception reporting across the API variants.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend-api-design, developer-experience
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100