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

Feature Request: Export Mux when generating typescript server #1342

Open
fangyi-zhou opened this issue Jul 17, 2024 · 0 comments · May be fixed by #1344
Open

Feature Request: Export Mux when generating typescript server #1342

fangyi-zhou opened this issue Jul 17, 2024 · 0 comments · May be fixed by #1344

Comments

@fangyi-zhou
Copy link

Hello team,

We're using Smithy TypeScript server code generator for an AWS lambda function, and it's been working greatly. We've recently encountered a use case where we're trying to write an authorizer lambda for the lambda function that is dependent on the HTTP path. We've noticed that the default code generation provides a Mux inside get$OPERATIONHandler and get$SERVICEHandler, and it looks like we can reuse the Mux for implementing our authorizer lambda. Is it possible to export the Mux in a separate function?

Thanks!

fangyi-zhou added a commit to fangyi-zhou/smithy-typescript that referenced this issue Jul 18, 2024
Closes smithy-lang#1342

It's useful to export the multiplexer that is automatically generated
for a service, e.g. for use in anauthorizor lambda. This commit exports
the generated multiplexer that is generated inside the service handler
so that the multiplexer can be used in other packages.
fangyi-zhou added a commit to fangyi-zhou/smithy-typescript that referenced this issue Jul 18, 2024
Closes smithy-lang#1342

It's useful to export the multiplexer that is automatically generated
for a service, e.g. for use in anauthorizor lambda. This commit exports
the generated multiplexer that is generated inside the service handler
so that the multiplexer can be used in other packages.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant