Skip to content

Add initial design FAQ. - #3305

Closed
sipsma wants to merge 1 commit into
dagger:mainfrom
sipsma:faq
Closed

sipsma wants to merge 1 commit into
dagger:mainfrom
sipsma:faq

Conversation

@sipsma

@sipsma sipsma commented Oct 11, 2022

Copy link
Copy Markdown
Contributor

Signed-off-by: Erik Sipsma [email protected]

There are a few questions that come up from external users a lot around "why cloak", "why graphql", etc.

This is my first rough pass at trying to capture the main design goals of cloak specifically and why graphql ended up being a good fit for the API framework.

Please feel free to be brutally honest if something doesn't make sense, is too vague, is too wordy, is missing entirely, etc. These sort of high-level why questions are a bit tricky to get right, especially when my head has been buried in all of it for a while and I'm now trying to introduce it all to someone potentially for the first time.

Related: #3014
Also related: many discord questions, questions during demos, etc.

Signed-off-by: Erik Sipsma <[email protected]>
@netlify

netlify Bot commented Oct 11, 2022 •

Copy link
Copy Markdown

👷 Deploy request for cloak-docs accepted.

Name Link
🔨 Latest commit 1288b8f
🔍 Latest deploy log https://app.netlify.com/sites/cloak-docs/deploys/634505ffe8823a00087c3279

@TomChv TomChv left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This FAQ is well redacted and answered to important points of Dagger Cloak.
I left 2 small comments but this is a very useful piece of documentation 🚀

1. Calling an API should not feel very different than just calling functions in the language you choose to use. The conversion of those function calls to language-agnostic API calls should be fully hidden behind the Dagger SDK.
- We support this through code-generated SDKs, which implement typed interfaces to extension APIs.

## FAQ

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not know if that's accurate but that may help to add a section to explain how you can (will) connect Dagger 2.0 to Dagger 3.0.
If I understand well, Cue can just be another supported language, I think it's interesting to talk about that.

- This freedom leaves both caller and callee to choose whichever language fits their particular job the best without having to think about interoperability.
- Rather than reimplementing the same automation in every possible programming language, it only needs to be implemented once and s then re-usable by all.
- Strengths of different languages thus enhance each other rather than creating silos.
- If Python has the world's greatest library for accomplishing X, an extension author should feel free to import+use it; they will be making that functionality available for anyone else in Go, Typescript, Bash and any other Dagger-supported language along the way.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does that mean you can call the library outside Dagger container?
For instance directly call kubectl Go SDK or AWS Python SDK instead of CLI?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you can see some example that do some work on the host directly with some Go package, and my Go extension was called. It was itself doing some Go code directly.
But it could have been called by a python code loading some env with pure python code and sending that to the Go extension.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TomChv TomChv Oct 15, 2022 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's impressive :O
But then how do you manage os compatibilities? If you execute operations on host, there's no buildkit nor qemu involved so how will it be managed? Imagine a Go extension that only work on Armv8 for some reason, what will happens on Windows?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a chance than in general Go is pretty portable :p But yeah, it could be an issue.

@sipsma sipsma mentioned this pull request Oct 13, 2022
@aluzzardi
aluzzardi changed the base branch from cloak to main October 14, 2022 18:25
@github-actions

github-actions Bot commented Nov 3, 2022

Copy link
Copy Markdown
Contributor

This PR is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions

Copy link
Copy Markdown
Contributor

This PR was closed because it has been stalled for 7 days with no activity.

@github-actions github-actions Bot closed this Nov 11, 2022
@gerhard

gerhard commented Nov 17, 2022

Copy link
Copy Markdown
Contributor

@vikram-dagger is this something that would be useful to reopen & merge?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants