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

provide request in context transforms #581

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rtkaczyk
Copy link

Goal

Add request parameter to GTransform

Rationale

To be able to decorate a service with an access log, as advertised in the docs.
See LoggingTransform for an example.

@rtkaczyk
Copy link
Author

@thesamet could you kindly consider this PR?

@@ -13,6 +13,8 @@ ThisBuild / resolvers ++= Resolver.sonatypeOssRepos("snapshots")

ThisBuild / versionScheme := Some("early-semver")

ThisBuild / version := "0.6.1"
Copy link
Author

Choose a reason for hiding this comment

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

Not sure about contributing guidelines. Had to add this to make it work locally

@thesamet
Copy link
Contributor

Hi @rtkaczyk , thanks for working on this, I appreciate the time you invested in putting the PR together. Since this is a breaking change that also adds complexity for the type signatures for all users of transformations, I prefer that we explore a different approach. The use case can be accomplished with ServerInterceptor that would override the listener. See this answer here: https://stackoverflow.com/a/68102211/97524 . I wonder if we can provide an idiomatic and this wrapper for this functionality in zio-grpc. Would you be open to look into that too?

@rtkaczyk
Copy link
Author

Thanks for the suggestion, I'll have a look

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 this pull request may close these issues.

2 participants