I have several GCP project that are all monitored by one central project. I want to add a Log-based metric to each of the sub-projects. The structure of the metric is identical across all the projects, with the exception that the name of the project is appended to the name of the metric. To do this, I have a Python Script that can use the GCP API to create the Metric. The script, however, requires the JSON description of the Metric. I cannot, however, find out where to export a metric's JSON. Does anyone know how to export, fetch, or GET a metric in JSON form? I have attempted to use the API call outlined here, but it lacks the filter and lableExtractors fields for the metric.
Looking to export a Log-based Metric in JSON Format
685 Views Asked by AKASynthose At
1
There are 1 best solutions below
Related Questions in JSON
- getting undefined while iterating json
- How can I serialize a numpy array while preserving matrix dimensions?
- What is best way to check if any of the property of object is null or empty?
- How to query JSON data according to JSON array's size with Spark SQL?
- Extracting data from json_decode with lat and lng geolocation
- Convert JSON.gz to JSON in node js
- How do I get the type to convert to when deserializing from Jackson
- Escape dot in jquery validate plugin
- Are allOf and properties keywords interchangeable?
- Sort continents by amount of countries
- Is there a data format lighter than json?
- Object of class CS_REST_Wrapper_Result could not be converted to string in CAMPAIGN MONITOR
- How to read JSON data from a web server running PHP and MySQL?
- Parse Nsmutabledictionary and extract value
- Handle empty JSON values in Java
Related Questions in GOOGLE-CLOUD-PLATFORM
- Google Logging API - What service name to use when writing entries from non-Google application?
- Custom exception message from google endpoints exception
- Unable to connect database of lamp instance from servlet running on tomcat instance of google cloud
- How to launch a Jar file using Spark on hadoop
- Google Cloud Bigtable Durability/Availability Guarantees
- How do I add a startup script to an existing VM from the developer console?
- What is the difference between an Instance and an Instance group
- How do i change files using ftp in google cloud?
- How to update all machines in an instance group on Google Cloud Platform?
- Setting up freeswitch server on Google cloud compute
- Google Cloud Endpoints: verifyToken: Signature length not correct
- Google Cloud BigTable connection setup time
- How GCE HTTP Cross-Region Load Balancing implemented
- Google Cloud Bigtable compression
- Google cloud SDK code to execute via cron
Related Questions in METRICS
- Cohort analysis with Amazon Redshift / PostgreSQL
- Issues Implementing Halstead's Complexity Metrics
- Golang : gocraft/health package 100% CPU
- Percent Metric in Kibana 4?
- Golang: healthd and healthtop of the library "gocraft/health"
- carbon-tagger does not translate received metrics to Grapthite
- Display rich metrics in Spring Boot with Actuator
- DropWizard Metrics Meters vs Timers
- Why ever use CachedGauage in Dropwizard Metrics?
- branch metrics link on Android app
- What is the best algorithms to compare Strings and put the similar together?
- What do "key buffer size" and "total MyISAM indexes" unit sizes mean?
- Hierarchy of variables using my own metric (MATLAB)?
- Google Analytics: dashboard with custom calculations between metrics
- Using weighted minkowski metric in sklearn's BallTree
Related Questions in GOOGLE-CLOUD-MONITORING
- Accessing the subscription/num_oustanding_messages metric in Google PubSub from Python
- How do I add my mobile device to my StackDriver profile?
- Is it possible to access MemoryStore Fragmentation Ratio e.g in Cloud Monitoring?
- How to programatically create a Cloud Monitoring (Stackdriver) Workspace & add a project to it?
- How can I see the total number of rows of a BigQuery table in a chart?
- how to get uptime of GCP VM instance
- Is there a way to count the number of triggered alerts in a period and visualize it in a dashboard?
- Stackdriver monitoring - exclude specific time range in metric
- remove and reinstall/update stackdriver-agent
- Counter metrics in GCP metrics explorer
- Is it possible to make a custom metric about a BigQuery SQL query?
- Google Cloud Monitoring: Extract Alerting Policy status using code
- Google Cloud Platform: Uptime Check / Response Validation "403(Forbidden)"
- Terraform-GCP cloud functions: how to attach log based metrics to google alert policy
- Google Cloud Monitoring - E-mail icon error
Related Questions in GOOGLE-CLOUD-METRICS
- Creating alert policy from log based metrics doesn't show up any logs in the Alert page
- API to calculate the total time a VM is available or down since its creation
- need understanding on guest-metrics in google cloud
- BigQuery - Scheduled Query Update Notification Email
- Monitoring request latencies in Google Metrics Explorer
- Chart multiple percentiles from distributions using Google MQL
- How to report activity by individual API keys in Google Cloud > Google Maps Platform?
- Google managed Prometheus migration issue - No matches for kind "PodMonitoring" in version "monitoring.googleapis.com/v1"
- Google Cloud Metrics - get pub/sub metric filtered by subscription_id
- Incorrect Google Cloud metrics? or what is going on?
- How to get instanceid from cloud_run?
- Looking to export a Log-based Metric in JSON Format
- Running GPU Monitoring on GCP in a container optimized OS
- GCP Cloud Run Revision Request Count Metric Group By Route But Route is Empty
- How to use MQL with node.js?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Since it was created as a log-based metric, you can:
projects.metrics.getwhich returns aLogMetricincluding theMetricDescriptorprojects.metricDescriptors.getwhich returns theMetricDescriptor.