We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug
The replaceAlias function get ignored when Dashboard Transforms like "Join by label" are applied on the dashboard.
replaceAlias
Expected behavior I would expect the function to keep working.
Screenshots
Software versions
{ "panels": [ { "datasource": { "type": "grafana", "uid": "grafana" }, "fieldConfig": { "defaults": { "custom": { "align": "auto", "cellOptions": { "type": "auto" }, "inspect": false }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "red", "value": 80 } ] }, "color": { "mode": "thresholds" }, "decimals": 0, "displayName": "", "unit": "percent" }, "overrides": [] }, "gridPos": { "h": 13, "w": 15, "x": 0, "y": 0 }, "id": 2, "options": { "showHeader": true, "cellHeight": "sm", "footer": { "show": false, "reducer": [ "sum" ], "countRows": false, "fields": "" } }, "pluginVersion": "11.1.0-68838", "targets": [ { "refId": "A", "datasource": { "type": "grafana", "uid": "grafana" }, "queryType": "snapshot", "snapshot": [ { "schema": { "refId": "A", "name": "Space ", "fields": [ { "name": "Time", "type": "time", "typeInfo": { "frame": "time.Time" }, "config": {} }, { "name": "Value", "type": "number", "typeInfo": { "frame": "float64", "nullable": true }, "labels": { "host": "Zabbix server", "item": "/etc/hostname: Space utilization", "item_key": "vfs.fs.size[/etc/hostname,pused]" }, "config": { "displayNameFromDS": "Space ", "custom": { "scopedVars": { "__zbx_host": { "text": "", "value": "Zabbix server" }, "__zbx_host_name": { "text": "", "value": "Zabbix server" }, "__zbx_item": { "text": "", "value": "/etc/hostname: Space utilization" }, "__zbx_item_interval": { "text": "", "value": "1m" }, "__zbx_item_key": { "text": "", "value": "vfs.fs.size[/etc/hostname,pused]" }, "__zbx_item_name": { "text": "", "value": "/etc/hostname: Space utilization" } }, "units": "%" }, "unit": "percent", "min": 0, "max": 100 } } ] }, "data": { "values": [ [ 1712567580000, 1712567640000, 1712567700000, 1712567760000, 1712567820000, 1712567880000, 1712567940000, 1712568000000, 1712568060000, 1712568120000, 1712568180000, 1712568240000, 1712568300000, 1712568360000, 1712568420000, 1712568480000, 1712568540000, 1712568600000, 1712568660000, 1712568720000, 1712568780000, 1712568840000, 1712568900000, 1712568960000, 1712569020000, 1712569080000, 1712569140000, 1712569200000, 1712569260000, 1712569320000, 1712569380000, 1712569440000, 1712569500000, 1712569560000, 1712569620000, 1712569680000, 1712569740000, 1712569800000, 1712569860000, 1712569920000, 1712569980000, 1712570040000, 1712570100000, 1712570160000, 1712570220000, 1712570280000, 1712570340000, 1712570400000, 1712570460000, 1712570520000, 1712570580000, 1712570640000, 1712570700000, 1712570760000, 1712570820000, 1712570880000, 1712570940000, 1712571000000, 1712571060000, 1712571120000, 1712571180000, 1712571240000, 1712571300000, 1712571360000, 1712571420000, 1712571480000, 1712571540000, 1712571600000, 1712571660000, 1712571720000, 1712571780000, 1712571840000, 1712571900000, 1712571960000, 1712572020000, 1712572080000, 1712572140000, 1712572200000, 1712572260000, 1712572320000, 1712572380000, 1712572440000, 1712572500000, 1712572560000, 1712572620000, 1712572680000, 1712572740000, 1712572800000, 1712572860000, 1712572920000, 1712572980000, 1712573040000, 1712573100000, 1712573160000, 1712573220000, 1712573280000, 1712573340000, 1712573400000, 1712573460000, 1712573520000, 1712573580000, 1712573640000, 1712573700000, 1712573760000, 1712573820000, 1712573880000, 1712573940000, 1712574000000, 1712574060000, 1712574120000, 1712574180000, 1712574240000, 1712574300000, 1712574360000, 1712574420000, 1712574480000, 1712574540000, 1712574600000, 1712574660000, 1712574720000, 1712574780000, 1712574840000, 1712574900000, 1712574960000, 1712575020000, 1712575080000, 1712575140000, 1712575200000, 1712575260000, 1712575320000, 1712575380000, 1712575440000, 1712575500000, 1712575560000, 1712575620000, 1712575680000, 1712575740000, 1712575800000, 1712575860000, 1712575920000, 1712575980000, 1712576040000, 1712576100000, 1712576160000, 1712576220000, 1712576280000, 1712576340000, 1712576400000, 1712576460000, 1712576520000, 1712576580000, 1712576640000, 1712576700000, 1712576760000, 1712576820000, 1712576880000, 1712576940000, 1712577000000, 1712577060000, 1712577120000, 1712577180000, 1712577240000, 1712577300000, 1712577360000, 1712577420000, 1712577480000, 1712577540000, 1712577600000, 1712577660000, 1712577720000, 1712577780000, 1712577840000, 1712577900000, 1712577960000, 1712578020000, 1712578080000, 1712578140000, 1712578200000, 1712578260000, 1712578320000, 1712578380000, 1712578440000, 1712578500000, 1712578560000, 1712578620000, 1712578680000, 1712578740000, 1712578800000, 1712578860000, 1712578920000, 1712578980000, 1712579040000, 1712579100000, 1712579160000, 1712579220000, 1712579280000, 1712579340000, 1712579400000, 1712579460000, 1712579520000, 1712579580000, 1712579640000, 1712579700000, 1712579760000, 1712579820000, 1712579880000, 1712579940000, 1712580000000, 1712580060000, 1712580120000, 1712580180000, 1712580240000, 1712580300000, 1712580360000, 1712580420000, 1712580480000, 1712580540000, 1712580600000, 1712580660000, 1712580720000, 1712580780000, 1712580840000, 1712580900000, 1712580960000, 1712581020000, 1712581080000, 1712581140000, 1712581200000, 1712581260000, 1712581320000, 1712581380000, 1712581440000, 1712581500000, 1712581560000, 1712581620000, 1712581680000, 1712581740000, 1712581800000, 1712581860000, 1712581920000, 1712581980000, 1712582040000, 1712582100000, 1712582160000, 1712582220000, 1712582280000, 1712582340000, 1712582400000, 1712582460000, 1712582520000, 1712582580000, 1712582640000, 1712582700000, 1712582760000, 1712582820000, 1712582880000, 1712582940000, 1712583000000, 1712583060000, 1712583120000, 1712583180000, 1712583240000, 1712583300000, 1712583360000, 1712583420000, 1712583480000, 1712583540000, 1712583600000, 1712583660000, 1712583720000, 1712583780000, 1712583840000, 1712583900000, 1712583960000, 1712584020000, 1712584080000, 1712584140000, 1712584200000, 1712584260000, 1712584320000, 1712584380000, 1712584440000, 1712584500000, 1712584560000, 1712584620000, 1712584680000, 1712584740000, 1712584800000, 1712584860000, 1712584920000, 1712584980000, 1712585040000, 1712585100000, 1712585160000, 1712585220000, 1712585280000, 1712585340000, 1712585400000, 1712585460000, 1712585520000, 1712585580000, 1712585640000, 1712585700000, 1712585760000, 1712585820000, 1712585880000, 1712585940000, 1712586000000, 1712586060000, 1712586120000, 1712586180000, 1712586240000, 1712586300000, 1712586360000, 1712586420000, 1712586480000, 1712586540000, 1712586600000, 1712586660000, 1712586720000, 1712586780000, 1712586840000, 1712586900000, 1712586960000, 1712587020000, 1712587080000, 1712587140000, 1712587200000, 1712587260000, 1712587320000, 1712587380000, 1712587440000, 1712587500000, 1712587560000, 1712587620000, 1712587680000, 1712587740000, 1712587800000, 1712587860000, 1712587920000, 1712587980000, 1712588040000, 1712588100000, 1712588160000, 1712588220000, 1712588280000, 1712588340000, 1712588400000, 1712588460000, 1712588520000, 1712588580000, 1712588640000, 1712588700000, 1712588760000, 1712588820000, 1712588880000, 1712588940000, 1712589000000, 1712589060000, 1712589120000 ], [ 67.720827, 67.720945, 67.721236, 67.721343, 67.721629, 67.721741, 67.722006, 67.722098, 67.722384, 67.722542, 67.722828, 67.72292, 67.723206, 67.723277, 67.723548, 67.723634, 67.72389, 67.723982, 67.724257, 67.72442, 67.724696, 67.724793, 67.725084, 67.725191, 67.725446, 67.725538, 67.725804, 67.72589, 67.726197, 67.726273, 67.726549, 67.726636, 67.726921, 67.727029, 67.727294, 67.727396, 67.727677, 67.727769, 67.728034, 67.728146, 67.728437, 67.728631, 67.728902, 67.729019, 67.729284, 67.729376, 67.729637, 67.729744, 67.730024, 67.730132, 67.730412, 67.730494, 67.73077, 67.730867, 67.731127, 67.731234, 67.731505, 67.731602, 67.731964, 67.73225, 67.732551, 67.732684, 67.732969, 67.733082, 67.733362, 67.733454, 67.733745, 67.733852, 67.734128, 67.734256, 67.734552, 67.734664, 67.734945, 67.735052, 67.735312, 67.735419, 67.735695, 67.735787, 67.736078, 67.736159, 67.736455, 67.736537, 67.736813, 67.737042, 67.737394, 67.737777, 67.738104, 67.738231, 67.738507, 67.738619, 67.738885, 67.739033, 67.739283, 67.739375, 67.739655, 67.739819, 67.740084, 67.740161, 67.740441, 67.740513, 67.740778, 67.740875, 67.741222, 67.741324, 67.74159, 67.741671, 67.741916, 67.742008, 67.742258, 67.742335, 67.742621, 67.742692, 67.742958, 67.743034, 67.743289, 67.743356, 67.743601, 67.743682, 67.743932, 67.744029, 67.74429, 67.744376, 67.744637, 67.744723, 67.744984, 67.745086, 67.745336, 67.745428, 67.745673, 67.745765, 67.746025, 67.746102, 67.746377, 67.746454, 67.746734, 67.746831, 67.747102, 67.747184, 67.747459, 67.747546, 67.747827, 67.747913, 67.748179, 67.748276, 67.748526, 67.748623, 67.748878, 67.74897, 67.749251, 67.749496, 67.749929, 67.750149, 67.75043, 67.750511, 67.750817, 67.750894, 67.751159, 67.751267, 67.751537, 67.751629, 67.751899, 67.751996, 67.752247, 67.752354, 67.752614, 67.752701, 67.752946, 67.753033, 67.753283, 67.753364, 67.753645, 67.753727, 67.753987, 67.754048, 67.754324, 67.754416, 67.754671, 67.754768, 67.755013, 67.755084, 67.755345, 67.755508, 67.755789, 67.755875, 67.756125, 67.756192, 67.756442, 67.756524, 67.756779, 67.756937, 67.757207, 67.757289, 67.757549, 67.757636, 67.757912, 67.757988, 67.758264, 67.75834, 67.758616, 67.758703, 67.758989, 67.75907, 67.759346, 67.759433, 67.759698, 67.75978, 67.760025, 67.760132, 67.760382, 67.760459, 67.760729, 67.760964, 67.77035, 67.771202, 67.771452, 67.767012, 67.767267, 67.767379, 67.76764, 67.767716, 67.767971, 67.768063, 67.762837, 67.762908, 67.763169, 67.76322, 67.763485, 67.763562, 67.763827, 67.763899, 67.764184, 67.764256, 67.764521, 67.764603, 67.764838, 67.764945, 67.76519, 67.765374, 67.765603, 67.765695, 67.76595, 67.765996, 67.766251, 67.766323, 67.766563, 67.76665, 67.76691, 67.767007, 67.767252, 67.767318, 67.767584, 67.76765, 67.767925, 67.767966, 67.768267, 67.768334, 67.768589, 67.768655, 67.768926, 67.768997, 67.769263, 67.769441, 67.769788, 67.769987, 67.770243, 67.770615, 67.771177, 67.771809, 67.772264, 67.772371, 67.772647, 67.772728, 67.773014, 67.773101, 67.773371, 67.773458, 67.773729, 67.773815, 67.774086, 67.774178, 67.774428, 67.774545, 67.774811, 67.774913, 67.775168, 67.775265, 67.775535, 67.775632, 67.775898, 67.776066, 67.776372, 67.776541, 67.776832, 67.776964, 67.777255, 67.777373, 67.777658, 67.777817, 67.778087, 67.778215, 67.778511, 67.778669, 67.77897, 67.779098, 67.779384, 67.779501, 67.779777, 67.780001, 67.780307, 67.784528, 67.784829, 67.781308, 67.781604, 67.781706, 67.782022, 67.782124, 67.782415, 67.782528, 67.782803, 67.782915, 67.783222, 67.783405, 67.784023, 67.784385, 67.784666, 67.784758, 67.785028, 67.78512, 67.785396, 67.785666, 67.785952, 67.786039, 67.786309, 67.786473, 67.786881, 67.786973, 67.787259, 67.787361, 67.787616, 67.78782, 67.788183, 67.788285, 67.788545, 67.788632, 67.788907, 67.788999, 67.789254, 67.789316, 67.789734, 67.789877, 67.790219, 67.790372, 67.790643, 67.790714, 67.791056, 67.791245, 67.791648, 67.791857, 67.792357, 67.792536 ] ] } } ] } ], "title": "Reproduced with embedded data", "transformations": [ { "id": "joinByLabels", "options": { "value": "host", "join": [ "item" ] } } ], "type": "table" }, { "gridPos": { "h": 7, "w": 9, "x": 15, "y": 0 }, "id": 5, "options": { "content": "<table width=\"100%\">\n <tr>\n <th width=\"2%\">Panel</th>\n <td >table @ 11.1.0-68838</td>\n </tr>\n <tr>\n <th>Queries</th>\n <td>A[alexanderzobnin-zabbix-datasource]</td>\n </tr>\n <tr>\n <th>Transform</th>\n <td>joinByLabels</td>\n </tr>\n <tr><th>Data</th><td> 1 frames, 2 fields, 360 rows </td></tr>\n \n <tr>\n <th>Grafana</th>\n <td>Grafana v11.1.0-68838 (22fe7b067c) // Enterprise</td>\n </tr>\n </table>", "mode": "html" }, "title": "Debug info", "type": "text" }, { "id": 6, "title": "Original Panel JSON", "type": "text", "gridPos": { "h": 13, "w": 9, "x": 15, "y": 7 }, "options": { "content": "{\n \"datasource\": {\n \"uid\": \"fc70adf3-0217-4052-be74-1107d78466c7\",\n \"type\": \"alexanderzobnin-zabbix-datasource\"\n },\n \"fieldConfig\": {\n \"defaults\": {\n \"custom\": {\n \"align\": \"auto\",\n \"cellOptions\": {\n \"type\": \"auto\"\n },\n \"inspect\": false\n },\n \"mappings\": [],\n \"thresholds\": {\n \"mode\": \"absolute\",\n \"steps\": [\n {\n \"color\": \"green\",\n \"value\": null\n },\n {\n \"color\": \"red\",\n \"value\": 80\n }\n ]\n },\n \"color\": {\n \"mode\": \"thresholds\"\n },\n \"decimals\": 0,\n \"displayName\": \"\",\n \"unit\": \"percent\"\n },\n \"overrides\": []\n },\n \"gridPos\": {\n \"h\": 7,\n \"w\": 24,\n \"x\": 0,\n \"y\": 0\n },\n \"id\": 9,\n \"options\": {\n \"showHeader\": true,\n \"cellHeight\": \"sm\",\n \"footer\": {\n \"show\": false,\n \"reducer\": [\n \"sum\"\n ],\n \"countRows\": false,\n \"fields\": \"\"\n }\n },\n \"pluginVersion\": \"11.1.0-68838\",\n \"targets\": [\n {\n \"schema\": 12,\n \"queryType\": \"0\",\n \"group\": {\n \"filter\": \"/.*/\"\n },\n \"host\": {\n \"filter\": \"Zabbix server\"\n },\n \"application\": {\n \"filter\": \"\"\n },\n \"itemTag\": {\n \"filter\": \"\"\n },\n \"item\": {\n \"filter\": \"/etc/hostname: Space utilization\"\n },\n \"macro\": {\n \"filter\": \"\"\n },\n \"functions\": [\n {\n \"def\": {\n \"name\": \"replaceAlias\",\n \"category\": \"Alias\",\n \"params\": [\n {\n \"name\": \"regexp\",\n \"type\": \"string\"\n },\n {\n \"name\": \"newAlias\",\n \"type\": \"string\"\n }\n ],\n \"defaultParams\": [\n \"/(.*)/\",\n \"$1\"\n ]\n },\n \"params\": [\n \"/(.*)hostname:\\\\ (.*)utilization/\",\n \"$2\"\n ],\n \"text\": \"replaceAlias(/(.*)/, $1)\",\n \"added\": true\n }\n ],\n \"trigger\": {\n \"filter\": \"\"\n },\n \"countTriggersBy\": \"\",\n \"tags\": {\n \"filter\": \"\"\n },\n \"proxy\": {\n \"filter\": \"\"\n },\n \"textFilter\": \"\",\n \"evaltype\": \"0\",\n \"options\": {\n \"showDisabledItems\": false,\n \"skipEmptyValues\": false,\n \"disableDataAlignment\": false,\n \"useZabbixValueMapping\": false,\n \"useTrends\": \"default\",\n \"count\": false\n },\n \"table\": {\n \"skipEmptyValues\": false\n },\n \"datasource\": {\n \"type\": \"alexanderzobnin-zabbix-datasource\",\n \"uid\": \"fc70adf3-0217-4052-be74-1107d78466c7\"\n },\n \"mode\": 4,\n \"refId\": \"A\",\n \"resultFormat\": \"time_series\",\n \"target\": \"\",\n \"triggers\": {\n \"acknowledged\": 2,\n \"count\": false,\n \"minSeverity\": 0\n }\n }\n ],\n \"title\": \"System status\",\n \"transformations\": [\n {\n \"id\": \"joinByLabels\",\n \"options\": {\n \"value\": \"host\",\n \"join\": [\n \"item\"\n ]\n }\n }\n ],\n \"type\": \"table\"\n}", "mode": "code", "code": { "language": "json", "showLineNumbers": true, "showMiniMap": true } } }, { "id": 3, "title": "Data from panel above (after transformations)", "type": "table", "datasource": { "type": "datasource", "uid": "-- Dashboard --" }, "gridPos": { "h": 7, "w": 15, "x": 0, "y": 13 }, "options": { "showTypeIcons": true }, "targets": [ { "datasource": { "type": "datasource", "uid": "-- Dashboard --" }, "panelId": 2, "withTransforms": true, "refId": "A" } ] }, { "id": 100, "title": "Data (before transformations)", "type": "table", "datasource": { "type": "datasource", "uid": "-- Dashboard --" }, "gridPos": { "h": 7, "w": 24, "x": 0, "y": 13 }, "options": { "showTypeIcons": true }, "targets": [ { "datasource": { "type": "datasource", "uid": "-- Dashboard --" }, "panelId": 2, "withTransforms": false, "refId": "A" } ] } ], "schemaVersion": 37, "title": "Debug: System status // 2024-04-08 18:16:10", "tags": [ "debug", "debug-table" ], "time": { "from": "2024-04-08T09:16:10.824Z", "to": "2024-04-08T15:16:10.824Z" } }
The text was updated successfully, but these errors were encountered:
I created a PR to update the docs on the plugin, as I don't think this is something that can be "fixed" from the plugin side.
Sorry, something went wrong.
Closing the issue as documentation has been updated.
No branches or pull requests
Describe the bug
The
replaceAlias
function get ignored when Dashboard Transforms like "Join by label" are applied on the dashboard.Expected behavior
I would expect the function to keep working.
Screenshots
Software versions
Panel debug snapshot dashboard
The text was updated successfully, but these errors were encountered: