You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 23, 2023. It is now read-only.
Copy file name to clipboardExpand all lines: exporters/stats/stackdriver/README.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -156,6 +156,15 @@ Stackdriver exporter adds a new `Metric` label for each custom `Metric` to ensur
156
156
of the `Timeseries`. The format of the label is: `{LANGUAGE}-{PID}@{HOSTNAME}`, if `{PID}` is not
157
157
available a random number will be used.
158
158
159
+
You have the option to override the "opencensus_task" metric label with custom constant labels using
160
+
`StackdriverStatsConfiguration.Builder.setConstantLabels()`. If you do so, make sure that the
161
+
monitored resource together with these labels is unique to the current process. This is to ensure
162
+
that there is only a single writer to each time series in Stackdriver.
163
+
164
+
You can also set `StackdriverStatsConfiguration.Builder.setConstantLabels()` to an empty map to
165
+
avoid getting the default "opencensus_task" label. You should only do this if you know that the
166
+
monitored resource uniquely identifies this process.
167
+
159
168
### Why did I get an error "java.lang.NoSuchMethodError: com.google.common...", like "java.lang.NoSuchMethodError:com.google.common.base.Throwables.throwIfInstanceOf"?
160
169
This is probably because there is a version conflict on Guava in the dependency tree.
Copy file name to clipboardExpand all lines: exporters/stats/stackdriver/src/main/java/io/opencensus/exporter/stats/stackdriver/CreateMetricDescriptorExporter.java
Copy file name to clipboardExpand all lines: exporters/stats/stackdriver/src/main/java/io/opencensus/exporter/stats/stackdriver/CreateTimeSeriesExporter.java
Copy file name to clipboardExpand all lines: exporters/stats/stackdriver/src/main/java/io/opencensus/exporter/stats/stackdriver/StackdriverExportUtils.java
+28-15Lines changed: 28 additions & 15 deletions
Original file line number
Diff line number
Diff line change
@@ -79,9 +79,17 @@
79
79
@SuppressWarnings("deprecation")
80
80
finalclassStackdriverExportUtils {
81
81
82
-
// TODO(songya): do we want these constants to be customizable?
Copy file name to clipboardExpand all lines: exporters/stats/stackdriver/src/main/java/io/opencensus/exporter/stats/stackdriver/StackdriverStatsConfiguration.java
0 commit comments