Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate all clients? #44

Open
joepjoosten opened this issue Mar 15, 2024 · 5 comments
Open

Generate all clients? #44

joepjoosten opened this issue Mar 15, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@joepjoosten
Copy link

Is there a reason not to generate all clients and create a pull request with the latest version of all clients (with the proper errors per command)?

Just wondering what is holding "us" back? Is there something I'm missing here?

I could spend a day this weekend to generate them all...

@floydspace
Copy link
Owner

hi @joepjoosten nothing stops us, I initiated this repos to first cover what I needed,
so now we have codegen solution which can be used to generate other clients. (thanks to @godu )
I'm still thinking is it correct way to do it like we do, maybe it would be a good idea to generate them during release phase, so we don't have to commit clients, and maintain only the code generator.
for now it is okay to generate and commit, go ahead if you want to contribute, I'm open to it.

@floydspace floydspace added the enhancement New feature or request label Sep 1, 2024
@kondaurovDev
Copy link

Hi @floydspace @joepjoosten,

Apologies for promoting my solution, but I have something that might interest you. I also love Effect and AWS. Here’s my code generator that serves a similar purpose:

GitHub Repository

I believe this solution can generate the necessary code you need.

@floydspace
Copy link
Owner

Hey @kondaurovDev thanks for that.

Ts-morph is in my list of packages which I want to try , thanks for good example

I'm not sure if your package specifically somehow can be used, bc I see the generated output is a bit opinionated.

So it is definitely helpful as inspiration, but not directly imo

But my ultimate goal is to generate all the packages during build time, so we don't have to commit all those code duplicates

@kondaurovDev
Copy link

Hi @floydspace

But my ultimate goal is to generate all the packages during build time, so we don't have to commit all those code duplicates

What do you mean by "all the packages"? And "to commit all those code duplicates"?

I think it's not feasible to generate all of AWS sdk clients (there are ~400 sdk clients) and different project may use different sets of those sdk clients.

I'm still thinking is it correct way to do it like we do, maybe it would be a good idea to generate them during release phase, so we don't have to commit clients, and maintain only the code generator.

In my opinion that decision must be made by developer, whether he wants to commit the generated code or add the generated folder in .gitignore.
I remember the time when I was a scala developer and we used different code generators in our projects (most of them were related to protobuf).

I'm not sure if your package specifically somehow can be used, bc I see the generated output is a bit opinionated.

It's not usable in effect-aws repository I believe but it can be used on its own. It will work with any project that has dependencies on @aws-sdk/client*

@floydspace
Copy link
Owner

What do you mean by "all the packages"? And "to commit all those code duplicates"?

I meant "all the clients", so we generate during build time, and the publish to npm, like it is done in zio-aws I guess.

I think it's not feasible to generate all of AWS sdk clients (there are ~400 sdk clients)

it is the point why we still explicitly have only limited set of clients published, I cannot guaranty it would work for all aws clinets and I'm not comfortable with that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants