0

I'm getting the following error while trying to push custom metrics from my code to Google Stackdriver. I'm using the Java SDK.

Caused by: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Unknown metric: custom.googleapis.com/jvm/heap/used (cannot auto-create custom metric descriptors without a Stackdriver account). at io.grpc.Status.asRuntimeException(Status.java:526)
Adam Sandor
  • 382
  • 1
  • 11

1 Answers1

1

The solution is to open Stackdriver Monitoring and add the project under which the agent code is running there. This means either creating a new SD Monitoring project or adding the GCP project to an existing SD Monitoring project. A singe SD Monitoring project can be associated with multiple GCP projects.

Adam Sandor
  • 382
  • 1
  • 11