oracle / oci-grafana-logs

Grafana datasource plugin for OCI logs
https://grafana.com/grafana/plugins/oci-logs-datasource
Universal Permissive License v1.0
12 stars 12 forks source link

Sample Query #60

Closed YogiTiwari closed 9 months ago

YogiTiwari commented 1 year ago

Hi, We have installed and set the permission for Grafana OCI log plugin but when we query using wild card search () it giver error that Message: GSL:line 1:0 unexpected input '' expecting one of CAST, FILE, SEARCH, SET\n*\n^\n\nOperation Name: SearchLogs\nTimestamp: 2022-12-19 14:46:58 +0000 GMT\nClient Version: Oracle-GoSDK/65.23.0\nRequest Endpoint: POST https://logging.eu-frankfurt-1.oci.oraclecloud.com/20190909/search?limit=1000\nTroubleshooting Tips: See https://docs.oracle.com/iaas/Content/API/References/apierrors.htm#apierrors_400__400_cannotparserequest for more information about resolving this error

Do you have a sample query that we can try?

Regards Yogesh

mamorett commented 1 year ago

Hi. I do not know your use case, but something like this is working (with wild card set): search "ocid1.compartment.oc1..xxx/ocid1.loggroup.oc1.eu-zurich-1.xxx/ocid1.log.oc1.eu-zurich-1.xxx" | subject = '/var/log/*' | summarize count(subject) by source,subject