You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thank you for the suggestion! This is an interesting idea and I have toyed around having a "static" interface that doesn't require the SDK (it's an attractive idea).
With that being said, the SDK is kind of required right now. Why? Because it does all of the source and artifact configuration hashing before handing them off to the CLI via the GRPC service. When the SDK runs in the language of your choice, it has logic in it to transform ArtifactSource types to ArtifactSourceId types then adds those ArtifactSourceId transforms to the Artifact configurations before transforming those configurations to ArtifactId types:
flowchart LR
A[ArtifactSource] --> B[ArtifactSourceId]
C[ArtifactSource] --> D[ArtifactSourceId]
B --> E[Artifact]
D --> E[Artifact]
E --> F[ArtifactId]
Loading
The reason the ArtifactSourceId types are injected into the Artifact configuration is so when evaluated to an ArtifactId it is consistently hashed properly. This was basically inspired somewhat by Input and Output types in Pulumi.
So, why is all of this done in the SDK? Because the SDK provides a GRPC service which basically serves as a data store for the CLI to use. To de-duplicate (since artifacts can reference artifacts), we use the ArtifactId and ArtifactSourceId as look ups and provide a map of references for the entire configuration.
It'd be cool to have a sort of file spec for building simple Vorpal artifacts, similar in nature to RPM specs files.
The idea, using the artifact structure in the README as a base for this, would be a file that looks like this:
Then, you could just use Vorpal's CLI to read this as a form of SDK input, sort of like this;
This would be an interesting thing to play with I think, and would probably help simpler projects adopt Vorpal, before they need to adopt an SDK.
The text was updated successfully, but these errors were encountered: