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

feat: support .NET Framework 4.61+ using gRPC-Web #426

Merged
merged 7 commits into from
Apr 27, 2023

Conversation

malandis
Copy link
Contributor

@malandis malandis commented Apr 26, 2023

Because .NET Framework does not support gRPC over HTTP/2, we fall back
to using gRPC for those older versions. To do this we:

  1. Add another target framework for the library, net461. This is the
    lowest .NET Framework version also supported by netstandard2.0.

  2. Conditional on a net461 build, link the gRPC-Web client
    dependency.

  3. Conditional on a net461 build, use a gRPC-Web HttpHandler for
    the control and data gRPC channels.

  4. Update the test projects to exercise the net461 build as well.

closes: https://github.com/momentohq/dev-eco-issue-tracker/issues/317

@malandis malandis force-pushed the feat/support-net-framework-461 branch from ef8ecac to 4e1b2ad Compare April 26, 2023 19:18
@malandis malandis marked this pull request as ready for review April 26, 2023 20:00
@malandis malandis requested a review from cprice404 April 26, 2023 20:00
@malandis
Copy link
Contributor Author

malandis commented Apr 26, 2023

Opening for review. I will build a test app and manually run on Windows Server 2016.

Copy link
Contributor

@cprice404 cprice404 left a comment

Choose a reason for hiding this comment

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

this is awesome! thanks for figuring it out. I just had a few minor questions.

src/Momento.Sdk/Internal/ControlGrpcManager.cs Outdated Show resolved Hide resolved
src/Momento.Sdk/Momento.Sdk.csproj Show resolved Hide resolved
Because .NET Framework does not support gRPC over HTTP/2, we fall back
to using gRPC for those older versions. To do this we:

1. Add another target framework for the library, `net461`. This is the
lowest .NET Framework version also supported by `netstandard2.0`.

2. Conditional on a `net461` build, link the gRPC-Web client
dependency.

3. Conditional on a `net461` build, use a gRPC-Web `HttpHandler` for
the control and data gRPC channels.

4. Update the test projects to exercise the `net461` build as well.
cprice404
cprice404 previously approved these changes Apr 26, 2023
Copy link
Contributor

@cprice404 cprice404 left a comment

Choose a reason for hiding this comment

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

amazing

src/Momento.Sdk/Momento.Sdk.csproj Show resolved Hide resolved
@malandis malandis merged commit 6b87c89 into main Apr 27, 2023
@malandis malandis deleted the feat/support-net-framework-461 branch April 27, 2023 00:49
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