Problem: When generating dashboard panels using Python Requests, unless the panel query is manually clicked ‘Run’ on Grafana UI, there is no data displayed.
Attached image shows how it does not display any panel data
Steps To Reproduce: Once the python code generates the panels, i click on edit panel --> re select the drop down options for the query and click run
Details: The dashboard setting is set to refresh continuously. However only when i manually select the dropdown for region, data source, database etc, does the query work and display data. My data source is athena and it is set as default
I have only 1 data source that is set as the default. What causes this behavior and how do i fix it?
Code :"targets": [ { "connectionArgs": { "catalog": "__default", "database": "db_name", "region": "__default" }, "datasource": { "type": "grafana-athena-datasource", "uid": "i3443ih4k" }, "format": 1, "rawSQL": athena_query, "refId": "A", "table": table_name }
Please see images below
1st snapshot, generated by code
2nd snapshot when i manually select for dropdown
Related
According to the documentation:
Document metadata added by steps
For every content object outputted by a Data Hub step, regardless of the step type, Data Hub will add the following document metadata keys and values to the document wrapped by the content object:
datahubCreatedOn = the date and time at which the document is written
datahubCreatedBy = the MarkLogic user used to run the step
datahubCreatedInFlow = the name of the flow containing the step being run
datahubCreatedByStep = the name of the step being run
datahubCreatedByJob = the ID of the job being run; this will contain the job ID of every flow run on the step, with multiple values being space-delimited
Is there any possibility to add some extra metadata keys and values to the document?
It is possible to add additional static values in your headers options or use one of these keywords to dynamically add values.
{
"headers": {
"sources": [{
"name": "loadCustomersJSON"
}],
"createdOn": "datahubCreatedOn",
"createdBy": "datahubCreatedBy"
}
}
You can also dynamically add values by using an interceptor
(See: https://docs.marklogic.com/datahub/5.6/flows/about-interceptors-custom-hooks.html) or updating the header value in a custom step if you are already using one (See:https://docs.marklogic.com/datahub/5.6/modules/editing-custom-step-module.html
Framework: react
Example: https://plnkr.co/edit/ONnLsqILeHCV7fyX
Current behavior
Prerequisite: set the column property cellrendererframework.
field: colName,
cellRendererFramework: CellRender,
When I click the refresh data button, the table appears blank first, and then the new data is rendered.
Expected behavior
The table does not appear blank and directly displays the latest data
Is there any easy method to getting the Column Title when using GET Row with the API? New to API. I'm utilizing Microsoft Power Automate for these calls to push updates to Teams and such (more custom than what comes natively from Smartsheet).
I'm utilizing this address from the documentation:
https://api.smartsheet.com/2.0/sheets/{SheetID}/rows/{rowID}, and then I add this string to the end of that URL to get discussions and columns: "?include=discussions,columns"
which will include a separate array named "Columns".
What I'm wanting to do is get the "Column title" within the initial GET Row action. It would show up within the "cells" array when doing a GET Row API call.
Here's an example of what is obtained in the "cells" array when GET Row is used:
"cells": [
{
"columnId": 4151830841190276,
"value": "New task.",
"displayValue": "New task."
}
]
And here's an example of what's obtained in that Columns array, which comes separate:
"columns": [
{
"id": 4151830841190276,
"version": 0,
"index": 3,
"title": "Item Name",
"type": "TEXT_NUMBER",
"primary": true,
"validation": false,
"width": 300
}
Which is fine, I can do lookups to bridge the gap between the ColumnID I obtain from "get row" and the Columns array that's also returned...but ideally I'd like to just get the ColumnID Title in the native "GET Row" action, preventing this workaround. Any ideas, or am I doing it the best way?
You can't get column information (title, type, options...) while specifically reading rows.
You have 2 options:
Make another call to get the column information
https://smartsheet-platform.github.io/api-docs/#get-column)
Read all
the sheet (both columns and rows at once)
https://smartsheet-platform.github.io/api-docs/#get-sheet
Both solution should be working, I would suggest the second solution since only one API call is needed, but need more work processing the data.
I am capturing live streaming of data and processing it. I configured my logstash.conf file.
I started my ElasticSearch, Logstash and Kibana.
I created my index in kibana and when I do a get index in the dev tools,
I have something like this
"message": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
}
I want to change the type of message from String to Double. How can I do it?
You can't change mapping after an index is created - you'll have to create the mapping yourself in a new index explicitly create the fields/types you need:
https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping.html
then re-index from the old to the new index:
https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-reindex.html
Note the type you want is 'double' not 'Double':
https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-types.html
Changing the data type of a field in Elasticsearch(ES) is a breaking change. In your case, you need an update the mapping and update in ES.
Please use https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-get-mapping.html to verify, that mapping is updated successfully in ES.
Reindex API requires _source to be enabled, Please refer https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-source-field.html for more information on _source field and whether it's enabled in your case.
If it's not enabled in your case, then the only option you have it to delete the old index(which has older mapping) and create it again with the new mapping.
Let me know if you have any doubt or face any issue implementing this.
I am creating a VSTS Kanban Epic using the REST API. This creates an Epic in the first column of the Kanban.
I want to be able to choose which column it goes into, and also as a second operation be able to move it from column to column using the REST API.
Looking at the list of fields available there is a field 'System.BoardColumn' - is this the correct field to modify to alter the Epic's column?
Thanks
You just need to specify the System.State field value (New, In process and Done) in REST API, then it will go the related column. Since New is the default value for System.State field, it will create in first column if you are not specify the value for System.State.
Create Epic in second column
To create an Epic shows in second column (In process) of Epics board, you can use create a work item REST API. Such as below example (create Epic epic3):
PATCH https://account.visualstudio.com/DefaultCollection/Git2/_apis/wit/workitems/$Epic?api-version=1.0
Content-Type: application/json-patch+json
[
{
"op": "add",
"path": "/fields/System.Title",
"value": "epic3"
},
{
"op": "add",
"path": "/fields/System.State",
"value": "In Progress"
}
]
Then the epic3 will show in second column:
Update an existing Epic from a column to another column
You just need to replace the value for System.State field by update a field REST API.
Such as above example, to move e1 (id=53) from first (New) column to second (IN process) column:
PATCH https://marinaliu.visualstudio.com/DefaultCollection/_apis/wit/workitems/53?api-version=1.0
Content-Type: application/json-patch+json
[
{
"op": "replace",
"path": "/fields/System.State",
"value": "In Progress"
}
]
Then the work item e1 will show in the second column: