-
Notifications
You must be signed in to change notification settings - Fork 8
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: Add a separate web SDK for clients without HTTP 2.0 #568
Conversation
Add a new Momento.Sdk.Web artifact that uses gRPC-Web so that users without access to HTTP 2.0 can use the SDK. Building with the USE_GRPC_WEB will generate the new Momento.Sdk.Web.dll. Note that this will affect the unity build as well. Add a pack and publish step to push the new artifact to nuget.
echo "version: ${VERSION}" | ||
dotnet build -p:DefineConstants=USE_GRPC_WEB --configuration Release | ||
dotnet pack -p:DefineConstants=USE_GRPC_WEB -c Release -p:Version=${VERSION} | ||
# dotnet nuget push ./bin/Release/Momento.Sdk.Web.${VERSION}.nupkg --source https://api.nuget.org/v3/index.json --api-key=${{secrets.NUGET_API_KEY}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've executed the steps up to here locally. Do we have a good place to publish this temporarily to test that it works?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, but since it's a net new package, no one will have deps on it yet, so it's not the end of the world if it's broken as long as we fast follow any necessary fixes.
We should follow this with an addition to the examples that uses the new web SDK dependency. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this lgtm if it looks good to @malandis
@@ -68,7 +79,7 @@ jobs: | |||
dotnet publish --configuration Release -f netstandard2.0 -p:DefineConstants=USE_GRPC_WEB -p:VersionPrefix=${VERSION} | |||
mkdir ./bin/Release/netstandard2.0/MomentoSdkUnity | |||
pushd ./bin/Release/netstandard2.0/publish/ | |||
cp Google.Protobuf.dll Grpc.Core.Api.dll Grpc.Net.Client.dll Grpc.Net.Client.Web.dll Grpc.Net.Common.dll JWT.dll Microsoft.Bcl.AsyncInterfaces.dll Microsoft.Extensions.Logging.Abstractions.dll Momento.Protos.dll Momento.Sdk.dll Newtonsoft.Json.dll System.Diagnostics.DiagnosticSource.dll System.Runtime.CompilerServices.Unsafe.dll System.Threading.Channels.dll ../MomentoSdkUnity/ | |||
cp Google.Protobuf.dll Grpc.Core.Api.dll Grpc.Net.Client.dll Grpc.Net.Client.Web.dll Grpc.Net.Common.dll JWT.dll Microsoft.Bcl.AsyncInterfaces.dll Microsoft.Extensions.Logging.Abstractions.dll Momento.Protos.dll Momento.Sdk.Web.dll Newtonsoft.Json.dll System.Diagnostics.DiagnosticSource.dll System.Runtime.CompilerServices.Unsafe.dll System.Threading.Channels.dll ../MomentoSdkUnity/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we might need to update the unity demo docs after this goes in
Remove redundant build step. Add comments above the standard and web SDK property groups.
Add a new Momento.Sdk.Web artifact that uses gRPC-Web so that users without access to HTTP 2.0 can use the SDK. Building with the USE_GRPC_WEB will generate the new Momento.Sdk.Web.dll. Note that this will affect the unity build as well.
Add a pack and publish step to push the new artifact to nuget.