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.

gRPC check throws errors

See original GitHub issue

⚠️ Please verify that this bug has NOT been raised before.

  • I checked and didn’t find similar issue

🛡️ Security Policy

Description

The gRPC check fails but i get the expected output in bloomrpc.

👟 Reproduction steps

URL: routing.ot-hosting.de:443

Keyword: version

Enable TLS: ✔️

Proto Service Name:

service.v1.RoutingService

Proto Method:

Info

Proto Content:

syntax = "proto3";

package service.v1;

message Envelope {
    double min_longitude = 1;
    double max_longitude = 2;
    double min_latitude = 3;
    double max_latitude = 4;
}

message InfoRequest {
}

message InfoResponse {
  string version = 1;
  string gh_version = 2;
  int64 data_timestamp = 3;
  Envelope bounding_box = 4;
  map<string,string> configuration = 5;
}

service RoutingService {
    rpc Info (InfoRequest) returns (InfoResponse);
}

Body:

{}

👀 Expected behavior

image

😓 Actual Behavior

Depending on the case of the method Info/info i get the following errors:

WARN: Monitor #67 'routing': Failing: response.substring is not a function | Interval: 60 seconds | Type: grpc-keyword | Down Count: 0 | Resend Interval: 0
WARN: Monitor #67 'routing': Failing: grpcService[grpcMethod] is not a function | Interval: 60 seconds | Type: grpc-keyword | Down Count: 0 | Resend Interval: 0

🐻 Uptime-Kuma Version

1.19.2

💻 Operating System and Arch

Ubuntu 22.04

🌐 Browser

Firefox

🐋 Docker Version

20.10.22

🟩 NodeJS Version

No response

📝 Relevant log output

No response

Issue Analytics

  • State:open
  • Created 9 months ago
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
minhhoangvncommented, Dec 28, 2022

@otbutz, thank you for your help in investigating the issue. The root cause is logic to truncate the response data for displaying in monitor info image

https://github.com/louislam/uptime-kuma/blob/8c684e92936b5860139b09e50917d55c0b041891/server/model/monitor.js#L551

I have created a new PR to fix those issues (can’t update service name and error when truncating response data)

1reaction
otbutzcommented, Dec 28, 2022
syntax = "proto3";

package service.v1;

message Envelope {
    double min_longitude = 1;
    double max_longitude = 2;
    double min_latitude = 3;
    double max_latitude = 4;
}

message InfoRequest {
}

message InfoResponse {
  string version = 1;
  string gh_version = 2;
  int64 data_timestamp = 3;
  Envelope bounding_box = 4;
  map<string,string> configuration = 5;
}

service RoutingService {
    rpc Info (InfoRequest) returns (InfoResponse);
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Error Handling in gRPC - Baeldung
Errors in gRPC are first-class entities, i.e., every call in gRPC is either a payload message or a status error message. The errors...
Read more >
gRPC Errors
A handy guide to gRPC errors ... gRPC is an amazing library, however, the documentation lacks details on error handling. The code examples...
Read more >
Getting Error Handling right in gRPC - Techdozo
Getting error handling right can be very tricky in gRPC. Officially, gRPC heavily relies on status codes and metadata to handle errors. We...
Read more >
gRPC Error Handling | Vinsguru
Learn gRPC Error Handling with Java. Different options to respond with client when some error occurred using Status, metadata & oneof.
Read more >
GRPC Core: Status codes and their use in gRPC
Code Number Description OK 0 Not an error; returned on success. FAILED_PRECONDITION 9 OUT_OF_RANGE 11
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