question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

After upgrade to Google.Cloud.Logging.V2 (3.0.0) container restarts on LoggingServiceV2Client.WriteLogEntriesAsync call

See original GitHub issue
  • OS: docker image on mcr.microsoft.com/dotnet/core/aspnet:3.1-alpine + glibc package
  • .NET version: 3.1.3
  • Package name and version: Google.Cloud.Logging.V2 (3.0.0)
  • GKE cluster + gitlab + helm charts

Everything works fine if I downgrade to 2.X

Steps to reproduce

var client = LoggingServiceV2Client.Create(); //success
var platform = Platform.Instance(); //success
var resource = platform.Type == PlatformType.Unknown
                ? MonitoredResourceBuilder.GlobalResource
                : MonitoredResourceBuilder.FromPlatform(platform);
// success: platform.Type is "gke"
var response = await client.WriteLogEntriesAsync(
                    CreateLogName("development-platform-221211", "Probe2-WebApi-Dev"),
                    resource,
                    null,
                    new[]{ new LogEntry
                    {
                        Severity = LogSeverity.Error,
                        Timestamp = Timestamp.FromDateTimeOffset(DateTimeOffset.UtcNow),
                        TextPayload = "Test, Test, Test",
                    }});

On the last call container is restarting. I use google cloud logging for a long time (1.5 years). But currently I need to implement gRPC service and have to upgrade to Google.Cloud.Logging.V2 (3.0.0). May be I do something wrong could you please help.

Thanks!

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:12

github_iconTop GitHub Comments

1reaction
jskeetcommented, Apr 3, 2020

Success! Replacing your section starting # Resolving gRPC dependencies with

RUN echo 'http://dl-cdn.alpinelinux.org/alpine/v3.8/main' >> /etc/apk/repositories && \
    apk update --no-cache && \
    apk add --no-cache bash libc6-compat=1.1.19-r11

worked for my console app. Now, I can’t tell if there are any other issues that might cause within ASP.NET Core, unfortunately. This is outside the areas I know in depth - but I hope it’s helpful. If it doesn’t work for you, it’s probably worth posting more details on the gRPC issue where there are rather more knowledgeable users.

0reactions
slim1305commented, Apr 3, 2020

Yee, your solution works fine. Great job, thanks. Screen

Read more comments on GitHub >

github_iconTop Results From Across the Web

Python client library | Google Cloud
0 Migration Guide. The 2.0 release of the google-cloud-logging client is a significant upgrade based on a next-gen code generator, and includes ...
Read more >
google cloud platform - Writing to Stackdriver can be slow
NET SDK Google.Cloud.Logging.V2 version 2.3.0 library. Measurement is done using Stopwatch before and after the call to the logging method.
Read more >
Google Cloud Logging, streaming logs constantly stops ...
Logs continue streaming until you select the scroll bar on the logs panel. When streaming has stopped, a Restart streaming button is shown....
Read more >
Introducing Google Cloud Logging Python v3.0.0
We're excited to announce the release of a major update to the Google Cloud Python logging library! v3.0.0 makes it even easier for...
Read more >
Incident affecting Google Kubernetes Engine
Containers within GKE cluster node pools using docker are getting restarted in the event of docker restarts. This issue affects the following node...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found