├── CODEOWNERS ├── LICENSE ├── README.md ├── dashboards ├── altinn │ ├── publicip.json │ ├── pod-console-error-logs.json │ ├── traefik-official.json │ └── blackbox-exporter.json └── fluxcd │ ├── gitops-flux-application-deployments-dashboard.json │ ├── flux-cluster-stats.json │ └── flux-control-plane.json └── .gitignore /CODEOWNERS: -------------------------------------------------------------------------------- 1 | # Owners for the whole repo (will be added to all PRs) 2 | * @Altinn/team-platform 3 | 4 | # Add specific ownership for further needs here 5 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Altinn 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Altinn Grafana Dashboards 2 | 3 | A collection of Grafana dashboard configurations for monitoring Altinn infrastructure and services. This repository contains JSON dashboard definitions that can be imported into Grafana for comprehensive observability across different components of the Altinn platform. 4 | 5 | ## Repository Structure 6 | 7 | ``` 8 | dashboards/ 9 | ├── altinn/ # Altinn-specific monitoring dashboards 10 | ├── fluxcd/ # FluxCD GitOps monitoring dashboards 11 | └── linkerd/ # Linkerd service mesh monitoring dashboards 12 | ``` 13 | 14 | ## Dashboard Categories 15 | 16 | ### Altinn Dashboards (`dashboards/altinn/`) 17 | 18 | Core monitoring dashboards for Altinn platform components: 19 | 20 | - **`blackbox-exporter.json`** - Prometheus Blackbox Exporter dashboard for endpoint monitoring 21 | - HTTP status codes and response times 22 | - DNS lookup performance 23 | - SSL certificate expiry monitoring 24 | - TLS version tracking 25 | - Network connectivity health checks 26 | 27 | - **`pod-console-error-logs.json`** - Pod Console Error Logs dashboard 28 | - Kubernetes pod error log aggregation 29 | - Console error tracking and analysis 30 | 31 | - **`publicip.json`** - Public IP monitoring dashboard 32 | - Inbound and outbound IP address tracking 33 | - Network connectivity monitoring 34 | 35 | - **`traefik-official.json`** - Traefik reverse proxy monitoring 36 | - Instance health and status 37 | - Request routing metrics 38 | - Load balancer performance 39 | 40 | ### FluxCD Dashboards (`dashboards/fluxcd/`) 41 | 42 | GitOps monitoring dashboards for FluxCD operations: 43 | 44 | - **`flux-cluster-stats.json`** - Cluster-wide FluxCD statistics 45 | - **`flux-control-plane.json`** - FluxCD control plane monitoring 46 | - **`gitops-flux-application-deployments-dashboard.json`** - Application deployment tracking 47 | 48 | ### Linkerd Dashboards (`dashboards/linkerd/`) 49 | 50 | Service mesh monitoring for Linkerd: 51 | 52 | - **`daemonset.json`** - DaemonSet monitoring and metrics 53 | - **`deployment.json`** - Deployment health and performance tracking 54 | 55 | ## Usage 56 | 57 | ### Importing Dashboards 58 | 59 | 1. **Via Grafana UI:** 60 | - Navigate to Grafana → Dashboards → Import 61 | - Upload the JSON file or paste the JSON content 62 | - Configure data sources as needed 63 | 64 | 2. **Via API:** 65 | ```bash 66 | curl -X POST \ 67 | http://your-grafana-instance/api/dashboards/db \ 68 | -H "Authorization: Bearer YOUR_API_KEY" \ 69 | -H "Content-Type: application/json" \ 70 | -d @path/to/dashboard.json 71 | ``` 72 | 73 | 3. **Via Provisioning:** 74 | - Place JSON files in Grafana's provisioning directory 75 | - Configure `dashboards.yaml` provisioning file 76 | 77 | ### Data Source Requirements 78 | 79 | These dashboards require the following data sources to be configured in Grafana: 80 | 81 | - **Prometheus** - For metrics collection and monitoring 82 | - **Loki** (for log dashboards) - For log aggregation and analysis 83 | 84 | ### Configuration 85 | 86 | Before importing, ensure your Grafana instance has: 87 | 88 | 1. Prometheus data source configured and accessible 89 | 2. Appropriate permissions for dashboard management 90 | 3. Required Grafana version (8.1.0 or higher recommended) 91 | 92 | ## Dashboard Customization 93 | 94 | Each dashboard JSON file can be customized by: 95 | 96 | 1. Modifying panel queries and visualizations 97 | 2. Adjusting time ranges and refresh intervals 98 | 3. Updating variable definitions and filters 99 | 4. Customizing alert thresholds and notifications 100 | 101 | ## Contributing 102 | 103 | When contributing new dashboards or modifications: 104 | 105 | 1. Ensure dashboards are exported from Grafana in JSON format 106 | 2. Remove any environment-specific data source UIDs 107 | 3. Test dashboard imports on a clean Grafana instance 108 | 4. Document any special requirements or dependencies 109 | 110 | ## Requirements 111 | 112 | - **Grafana:** 8.1.0 or higher 113 | - **Prometheus:** Compatible version for data source 114 | - **Kubernetes:** For pod and service monitoring dashboards 115 | - **FluxCD:** For GitOps monitoring dashboards 116 | - **Linkerd:** For service mesh monitoring dashboards 117 | 118 | ## License 119 | 120 | This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. 121 | 122 | ## Support 123 | 124 | For issues related to: 125 | - Dashboard functionality: Check Grafana documentation and panel configurations 126 | - Data source connectivity: Verify Prometheus and other data source configurations 127 | - Platform-specific metrics: Consult respective component documentation (FluxCD, Linkerd, etc.) 128 | 129 | --- 130 | 131 | **Note:** These dashboards are designed for the Altinn platform infrastructure. You may need to adjust queries and panel configurations based on your specific environment and metric naming conventions. -------------------------------------------------------------------------------- /dashboards/altinn/publicip.json: -------------------------------------------------------------------------------- 1 | { 2 | "annotations": { 3 | "list": [ 4 | { 5 | "builtIn": 1, 6 | "datasource": { 7 | "type": "grafana", 8 | "uid": "-- Grafana --" 9 | }, 10 | "enable": true, 11 | "hide": true, 12 | "iconColor": "rgba(0, 211, 255, 1)", 13 | "name": "Annotations & Alerts", 14 | "type": "dashboard" 15 | } 16 | ] 17 | }, 18 | "description": "IP adresses for cluster that run your apps.", 19 | "editable": true, 20 | "fiscalYearStartMonth": 0, 21 | "graphTooltip": 0, 22 | "id": 145, 23 | "links": [], 24 | "panels": [ 25 | { 26 | "datasource": {}, 27 | "fieldConfig": { 28 | "defaults": { 29 | "custom": { 30 | "align": "auto", 31 | "cellOptions": { 32 | "type": "auto" 33 | }, 34 | "inspect": true 35 | }, 36 | "mappings": [], 37 | "thresholds": { 38 | "mode": "absolute", 39 | "steps": [ 40 | { 41 | "color": "green", 42 | "value": null 43 | }, 44 | { 45 | "color": "red", 46 | "value": 80 47 | } 48 | ] 49 | } 50 | }, 51 | "overrides": [ 52 | { 53 | "matcher": { 54 | "id": "byFrameRefID", 55 | "options": "A" 56 | }, 57 | "properties": [ 58 | { 59 | "id": "links" 60 | } 61 | ] 62 | } 63 | ] 64 | }, 65 | "gridPos": { 66 | "h": 5, 67 | "w": 10, 68 | "x": 0, 69 | "y": 0 70 | }, 71 | "id": 2, 72 | "options": { 73 | "cellHeight": "sm", 74 | "footer": { 75 | "countRows": false, 76 | "fields": "", 77 | "reducer": ["sum"], 78 | "show": false 79 | }, 80 | "showHeader": true 81 | }, 82 | "pluginVersion": "10.4.7", 83 | "targets": [ 84 | { 85 | "azureResourceGraph": { 86 | "query": "Resources\n| where type == \"microsoft.network/publicipaddresses\"\n| project Name=name, IPadress=properties.ipAddress" 87 | }, 88 | "datasource": { 89 | "type": "grafana-azure-monitor-datasource", 90 | "uid": "${DS_AZURE_MONITOR}" 91 | }, 92 | "queryType": "Azure Resource Graph", 93 | "refId": "A", 94 | "subscriptions": ["$subscription_id"] 95 | } 96 | ], 97 | "title": "Inbound IP", 98 | "transformations": [ 99 | { 100 | "id": "organize", 101 | "options": { 102 | "excludeByName": { 103 | "IPadress": false 104 | }, 105 | "includeByName": {}, 106 | "indexByName": {}, 107 | "renameByName": { 108 | "Name": "Azure Resource Name" 109 | } 110 | } 111 | } 112 | ], 113 | "type": "table" 114 | }, 115 | { 116 | "datasource": { 117 | "type": "grafana-azure-monitor-datasource", 118 | "uid": "azure-monitor-oob" 119 | }, 120 | "fieldConfig": { 121 | "defaults": { 122 | "custom": { 123 | "align": "auto", 124 | "cellOptions": { 125 | "type": "auto" 126 | }, 127 | "inspect": true 128 | }, 129 | "mappings": [], 130 | "thresholds": { 131 | "mode": "absolute", 132 | "steps": [ 133 | { 134 | "color": "green", 135 | "value": null 136 | }, 137 | { 138 | "color": "red", 139 | "value": 80 140 | } 141 | ] 142 | } 143 | }, 144 | "overrides": [ 145 | { 146 | "matcher": { 147 | "id": "byFrameRefID", 148 | "options": "A" 149 | }, 150 | "properties": [ 151 | { 152 | "id": "links" 153 | } 154 | ] 155 | } 156 | ] 157 | }, 158 | "gridPos": { 159 | "h": 5, 160 | "w": 10, 161 | "x": 0, 162 | "y": 5 163 | }, 164 | "id": 1, 165 | "options": { 166 | "cellHeight": "sm", 167 | "footer": { 168 | "countRows": false, 169 | "fields": "", 170 | "reducer": ["sum"], 171 | "show": false 172 | }, 173 | "showHeader": true 174 | }, 175 | "pluginVersion": "10.4.7", 176 | "targets": [ 177 | { 178 | "azureResourceGraph": { 179 | "query": "Resources\n| where type == \"microsoft.network/publicipprefixes\"\n| project Name=name, IPrange=properties.ipPrefix" 180 | }, 181 | "datasource": { 182 | "type": "grafana-azure-monitor-datasource", 183 | "uid": "${DS_AZURE_MONITOR}" 184 | }, 185 | "queryType": "Azure Resource Graph", 186 | "refId": "A", 187 | "subscriptions": ["$subscription_id"] 188 | } 189 | ], 190 | "title": "Outbound IP", 191 | "transformations": [ 192 | { 193 | "id": "organize", 194 | "options": { 195 | "excludeByName": {}, 196 | "includeByName": {}, 197 | "indexByName": {}, 198 | "renameByName": { 199 | "Name": "Azure Resource Name" 200 | } 201 | } 202 | } 203 | ], 204 | "type": "table" 205 | } 206 | ], 207 | "refresh": "", 208 | "schemaVersion": 39, 209 | "tags": [], 210 | "templating": { 211 | "list": [ 212 | { 213 | "datasource": { 214 | "type": "grafana-azure-monitor-datasource", 215 | "uid": "azure-monitor-oob" 216 | }, 217 | "definition": "", 218 | "hide": 2, 219 | "includeAll": false, 220 | "multi": false, 221 | "name": "subscription_id", 222 | "options": [], 223 | "query": { 224 | "azureLogAnalytics": { 225 | "query": "", 226 | "resources": [] 227 | }, 228 | "queryType": "Azure Subscriptions", 229 | "refId": "A" 230 | }, 231 | "refresh": 1, 232 | "regex": "", 233 | "skipUrlSync": false, 234 | "sort": 0, 235 | "type": "query" 236 | } 237 | ] 238 | }, 239 | "time": { 240 | "from": "now-1h", 241 | "to": "now" 242 | }, 243 | "timepicker": { 244 | "refresh_intervals": ["1h"] 245 | }, 246 | "timezone": "browser", 247 | "title": "Public IPs", 248 | "uid": "de1a1z1zluwaod", 249 | "version": 2, 250 | "weekStart": "" 251 | } 252 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.rsuser 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Mono auto generated files 17 | mono_crash.* 18 | 19 | # Build results 20 | [Dd]ebug/ 21 | [Dd]ebugPublic/ 22 | [Rr]elease/ 23 | [Rr]eleases/ 24 | x64/ 25 | x86/ 26 | [Aa][Rr][Mm]/ 27 | [Aa][Rr][Mm]64/ 28 | bld/ 29 | [Bb]in/ 30 | [Oo]bj/ 31 | [Ll]og/ 32 | [Ll]ogs/ 33 | 34 | # Visual Studio 2015/2017 cache/options directory 35 | .vs/ 36 | # Uncomment if you have tasks that create the project's static files in wwwroot 37 | #wwwroot/ 38 | 39 | # Visual Studio 2017 auto generated files 40 | Generated\ Files/ 41 | 42 | # MSTest test Results 43 | [Tt]est[Rr]esult*/ 44 | [Bb]uild[Ll]og.* 45 | 46 | # NUnit 47 | *.VisualState.xml 48 | TestResult.xml 49 | nunit-*.xml 50 | 51 | # Build Results of an ATL Project 52 | [Dd]ebugPS/ 53 | [Rr]eleasePS/ 54 | dlldata.c 55 | 56 | # Benchmark Results 57 | BenchmarkDotNet.Artifacts/ 58 | 59 | # .NET Core 60 | project.lock.json 61 | project.fragment.lock.json 62 | artifacts/ 63 | 64 | # StyleCop 65 | StyleCopReport.xml 66 | 67 | # Files built by Visual Studio 68 | *_i.c 69 | *_p.c 70 | *_h.h 71 | *.ilk 72 | *.meta 73 | *.obj 74 | *.iobj 75 | *.pch 76 | *.pdb 77 | *.ipdb 78 | *.pgc 79 | *.pgd 80 | *.rsp 81 | *.sbr 82 | *.tlb 83 | *.tli 84 | *.tlh 85 | *.tmp 86 | *.tmp_proj 87 | *_wpftmp.csproj 88 | *.log 89 | *.vspscc 90 | *.vssscc 91 | .builds 92 | *.pidb 93 | *.svclog 94 | *.scc 95 | 96 | # Chutzpah Test files 97 | _Chutzpah* 98 | 99 | # Visual C++ cache files 100 | ipch/ 101 | *.aps 102 | *.ncb 103 | *.opendb 104 | *.opensdf 105 | *.sdf 106 | *.cachefile 107 | *.VC.db 108 | *.VC.VC.opendb 109 | 110 | # Visual Studio profiler 111 | *.psess 112 | *.vsp 113 | *.vspx 114 | *.sap 115 | 116 | # Visual Studio Trace Files 117 | *.e2e 118 | 119 | # TFS 2012 Local Workspace 120 | $tf/ 121 | 122 | # Guidance Automation Toolkit 123 | *.gpState 124 | 125 | # ReSharper is a .NET coding add-in 126 | _ReSharper*/ 127 | *.[Rr]e[Ss]harper 128 | *.DotSettings.user 129 | 130 | # TeamCity is a build add-in 131 | _TeamCity* 132 | 133 | # DotCover is a Code Coverage Tool 134 | *.dotCover 135 | 136 | # AxoCover is a Code Coverage Tool 137 | .axoCover/* 138 | !.axoCover/settings.json 139 | 140 | # Visual Studio code coverage results 141 | *.coverage 142 | *.coveragexml 143 | 144 | # NCrunch 145 | _NCrunch_* 146 | .*crunch*.local.xml 147 | nCrunchTemp_* 148 | 149 | # MightyMoose 150 | *.mm.* 151 | AutoTest.Net/ 152 | 153 | # Web workbench (sass) 154 | .sass-cache/ 155 | 156 | # Installshield output folder 157 | [Ee]xpress/ 158 | 159 | # DocProject is a documentation generator add-in 160 | DocProject/buildhelp/ 161 | DocProject/Help/*.HxT 162 | DocProject/Help/*.HxC 163 | DocProject/Help/*.hhc 164 | DocProject/Help/*.hhk 165 | DocProject/Help/*.hhp 166 | DocProject/Help/Html2 167 | DocProject/Help/html 168 | 169 | # Click-Once directory 170 | publish/ 171 | 172 | # Publish Web Output 173 | *.[Pp]ublish.xml 174 | *.azurePubxml 175 | # Note: Comment the next line if you want to checkin your web deploy settings, 176 | # but database connection strings (with potential passwords) will be unencrypted 177 | *.pubxml 178 | *.publishproj 179 | 180 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 181 | # checkin your Azure Web App publish settings, but sensitive information contained 182 | # in these scripts will be unencrypted 183 | PublishScripts/ 184 | 185 | # NuGet Packages 186 | *.nupkg 187 | # NuGet Symbol Packages 188 | *.snupkg 189 | # The packages folder can be ignored because of Package Restore 190 | **/[Pp]ackages/* 191 | # except build/, which is used as an MSBuild target. 192 | !**/[Pp]ackages/build/ 193 | # Uncomment if necessary however generally it will be regenerated when needed 194 | #!**/[Pp]ackages/repositories.config 195 | # NuGet v3's project.json files produces more ignorable files 196 | *.nuget.props 197 | *.nuget.targets 198 | 199 | # Microsoft Azure Build Output 200 | csx/ 201 | *.build.csdef 202 | 203 | # Microsoft Azure Emulator 204 | ecf/ 205 | rcf/ 206 | 207 | # Windows Store app package directories and files 208 | AppPackages/ 209 | BundleArtifacts/ 210 | Package.StoreAssociation.xml 211 | _pkginfo.txt 212 | *.appx 213 | *.appxbundle 214 | *.appxupload 215 | 216 | # Visual Studio cache files 217 | # files ending in .cache can be ignored 218 | *.[Cc]ache 219 | # but keep track of directories ending in .cache 220 | !?*.[Cc]ache/ 221 | 222 | # Others 223 | ClientBin/ 224 | ~$* 225 | *~ 226 | *.dbmdl 227 | *.dbproj.schemaview 228 | *.jfm 229 | *.pfx 230 | *.publishsettings 231 | orleans.codegen.cs 232 | 233 | # Including strong name files can present a security risk 234 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 235 | #*.snk 236 | 237 | # Since there are multiple workflows, uncomment next line to ignore bower_components 238 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 239 | #bower_components/ 240 | 241 | # RIA/Silverlight projects 242 | Generated_Code/ 243 | 244 | # Backup & report files from converting an old project file 245 | # to a newer Visual Studio version. Backup files are not needed, 246 | # because we have git ;-) 247 | _UpgradeReport_Files/ 248 | Backup*/ 249 | UpgradeLog*.XML 250 | UpgradeLog*.htm 251 | ServiceFabricBackup/ 252 | *.rptproj.bak 253 | 254 | # SQL Server files 255 | *.mdf 256 | *.ldf 257 | *.ndf 258 | 259 | # Business Intelligence projects 260 | *.rdl.data 261 | *.bim.layout 262 | *.bim_*.settings 263 | *.rptproj.rsuser 264 | *- [Bb]ackup.rdl 265 | *- [Bb]ackup ([0-9]).rdl 266 | *- [Bb]ackup ([0-9][0-9]).rdl 267 | 268 | # Microsoft Fakes 269 | FakesAssemblies/ 270 | 271 | # GhostDoc plugin setting file 272 | *.GhostDoc.xml 273 | 274 | # Node.js Tools for Visual Studio 275 | .ntvs_analysis.dat 276 | node_modules/ 277 | 278 | # Visual Studio 6 build log 279 | *.plg 280 | 281 | # Visual Studio 6 workspace options file 282 | *.opt 283 | 284 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 285 | *.vbw 286 | 287 | # Visual Studio LightSwitch build output 288 | **/*.HTMLClient/GeneratedArtifacts 289 | **/*.DesktopClient/GeneratedArtifacts 290 | **/*.DesktopClient/ModelManifest.xml 291 | **/*.Server/GeneratedArtifacts 292 | **/*.Server/ModelManifest.xml 293 | _Pvt_Extensions 294 | 295 | # Paket dependency manager 296 | .paket/paket.exe 297 | paket-files/ 298 | 299 | # FAKE - F# Make 300 | .fake/ 301 | 302 | # CodeRush personal settings 303 | .cr/personal 304 | 305 | # Python Tools for Visual Studio (PTVS) 306 | __pycache__/ 307 | *.pyc 308 | 309 | # Cake - Uncomment if you are using it 310 | # tools/** 311 | # !tools/packages.config 312 | 313 | # Tabs Studio 314 | *.tss 315 | 316 | # Telerik's JustMock configuration file 317 | *.jmconfig 318 | 319 | # BizTalk build output 320 | *.btp.cs 321 | *.btm.cs 322 | *.odx.cs 323 | *.xsd.cs 324 | 325 | # OpenCover UI analysis results 326 | OpenCover/ 327 | 328 | # Azure Stream Analytics local run output 329 | ASALocalRun/ 330 | 331 | # MSBuild Binary and Structured Log 332 | *.binlog 333 | 334 | # NVidia Nsight GPU debugger configuration file 335 | *.nvuser 336 | 337 | # MFractors (Xamarin productivity tool) working folder 338 | .mfractor/ 339 | 340 | # Local History for Visual Studio 341 | .localhistory/ 342 | 343 | # BeatPulse healthcheck temp database 344 | healthchecksdb 345 | 346 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 347 | MigrationBackup/ 348 | 349 | # Ionide (cross platform F# VS Code tools) working folder 350 | .ionide/ 351 | -------------------------------------------------------------------------------- /dashboards/altinn/pod-console-error-logs.json: -------------------------------------------------------------------------------- 1 | { 2 | "annotations": { 3 | "list": [ 4 | { 5 | "builtIn": 1, 6 | "datasource": { 7 | "type": "grafana", 8 | "uid": "-- Grafana --" 9 | }, 10 | "enable": true, 11 | "hide": true, 12 | "iconColor": "rgba(0, 211, 255, 1)", 13 | "name": "Annotations & Alerts", 14 | "type": "dashboard" 15 | } 16 | ] 17 | }, 18 | "description": "Dashboard for monitoring pod console error logs from Altinn applications", 19 | "editable": true, 20 | "fiscalYearStartMonth": 0, 21 | "graphTooltip": 0, 22 | "id": 169, 23 | "links": [], 24 | "panels": [ 25 | { 26 | "datasource": { 27 | "type": "grafana-azure-monitor-datasource", 28 | "uid": "azure-monitor-oob" 29 | }, 30 | "description": "Error logs from selected pod", 31 | "fieldConfig": { 32 | "defaults": { 33 | "color": { 34 | "mode": "thresholds" 35 | }, 36 | "custom": { 37 | "align": "auto", 38 | "cellOptions": { 39 | "type": "auto" 40 | }, 41 | "filterable": true, 42 | "inspect": false 43 | }, 44 | "mappings": [], 45 | "thresholds": { 46 | "mode": "absolute", 47 | "steps": [ 48 | { 49 | "color": "green", 50 | "value": null 51 | }, 52 | { 53 | "color": "red", 54 | "value": 80 55 | } 56 | ] 57 | } 58 | }, 59 | "overrides": [ 60 | { 61 | "matcher": { 62 | "id": "byName", 63 | "options": "TimeGenerated" 64 | }, 65 | "properties": [ 66 | { 67 | "id": "custom.width", 68 | "value": 180 69 | } 70 | ] 71 | }, 72 | { 73 | "matcher": { 74 | "id": "byName", 75 | "options": "LogMessage" 76 | }, 77 | "properties": [ 78 | { 79 | "id": "custom.width", 80 | "value": 800 81 | } 82 | ] 83 | } 84 | ] 85 | }, 86 | "gridPos": { 87 | "h": 16, 88 | "w": 24, 89 | "x": 0, 90 | "y": 0 91 | }, 92 | "id": 1, 93 | "options": { 94 | "cellHeight": "sm", 95 | "footer": { 96 | "countRows": true, 97 | "fields": "", 98 | "reducer": ["sum"], 99 | "show": true 100 | }, 101 | "showHeader": true, 102 | "sortBy": [ 103 | { 104 | "desc": true, 105 | "displayName": "TimeGenerated" 106 | } 107 | ] 108 | }, 109 | "targets": [ 110 | { 111 | "azureLogAnalytics": { 112 | "dashboardTime": true, 113 | "query": "ContainerLogV2\n| where PodName contains \"${PodName}\"\n| project TimeGenerated, PodName, ContainerName, LogMessage", 114 | "resources": ["/subscriptions/${sub}/resourceGroups/${rg}"], 115 | "resultFormat": "logs", 116 | "timeColumn": "TimeGenerated" 117 | }, 118 | "datasource": { 119 | "type": "grafana-azure-monitor-datasource", 120 | "uid": "azure-monitor-oob" 121 | }, 122 | "queryType": "Azure Log Analytics", 123 | "refId": "A" 124 | } 125 | ], 126 | "title": "Error Logs - ${PodName}", 127 | "type": "table" 128 | }, 129 | { 130 | "datasource": { 131 | "type": "grafana-azure-monitor-datasource", 132 | "uid": "azure-monitor-oob" 133 | }, 134 | "description": "Count of error logs over time", 135 | "fieldConfig": { 136 | "defaults": { 137 | "color": { 138 | "mode": "palette-classic" 139 | }, 140 | "custom": { 141 | "axisCenteredZero": false, 142 | "axisColorMode": "text", 143 | "axisLabel": "", 144 | "axisPlacement": "auto", 145 | "barAlignment": 0, 146 | "drawStyle": "line", 147 | "fillOpacity": 10, 148 | "gradientMode": "none", 149 | "hideFrom": { 150 | "legend": false, 151 | "tooltip": false, 152 | "vis": false 153 | }, 154 | "lineInterpolation": "linear", 155 | "lineWidth": 1, 156 | "pointSize": 5, 157 | "scaleDistribution": { 158 | "type": "linear" 159 | }, 160 | "showPoints": "never", 161 | "spanNulls": false, 162 | "stacking": { 163 | "group": "A", 164 | "mode": "none" 165 | }, 166 | "thresholdsStyle": { 167 | "mode": "off" 168 | } 169 | }, 170 | "mappings": [], 171 | "min": 0, 172 | "thresholds": { 173 | "mode": "absolute", 174 | "steps": [ 175 | { 176 | "color": "green", 177 | "value": null 178 | }, 179 | { 180 | "color": "red", 181 | "value": 80 182 | } 183 | ] 184 | }, 185 | "unit": "short" 186 | }, 187 | "overrides": [] 188 | }, 189 | "gridPos": { 190 | "h": 8, 191 | "w": 12, 192 | "x": 0, 193 | "y": 16 194 | }, 195 | "id": 2, 196 | "options": { 197 | "legend": { 198 | "calcs": [], 199 | "displayMode": "list", 200 | "placement": "bottom", 201 | "showLegend": true 202 | }, 203 | "tooltip": { 204 | "mode": "single", 205 | "sort": "none" 206 | } 207 | }, 208 | "targets": [ 209 | { 210 | "azureLogAnalytics": { 211 | "dashboardTime": true, 212 | "query": "ContainerLogV2\n| where PodName contains \"${PodName}\"\n| summarize ErrorCount = count() by bin(TimeGenerated, 5m)", 213 | "resources": ["/subscriptions/${sub}/resourceGroups/${rg}"], 214 | "resultFormat": "time_series", 215 | "timeColumn": "TimeGenerated" 216 | }, 217 | "datasource": { 218 | "type": "grafana-azure-monitor-datasource", 219 | "uid": "azure-monitor-oob" 220 | }, 221 | "queryType": "Azure Log Analytics", 222 | "refId": "A" 223 | } 224 | ], 225 | "title": "Error Count Over Time", 226 | "type": "timeseries" 227 | }, 228 | { 229 | "datasource": { 230 | "type": "grafana-azure-monitor-datasource", 231 | "uid": "azure-monitor-oob" 232 | }, 233 | "description": "Total count of error logs in selected time range", 234 | "fieldConfig": { 235 | "defaults": { 236 | "color": { 237 | "mode": "thresholds" 238 | }, 239 | "mappings": [], 240 | "thresholds": { 241 | "mode": "absolute", 242 | "steps": [ 243 | { 244 | "color": "green", 245 | "value": null 246 | }, 247 | { 248 | "color": "yellow", 249 | "value": 10 250 | }, 251 | { 252 | "color": "red", 253 | "value": 50 254 | } 255 | ] 256 | } 257 | }, 258 | "overrides": [] 259 | }, 260 | "gridPos": { 261 | "h": 8, 262 | "w": 12, 263 | "x": 12, 264 | "y": 16 265 | }, 266 | "id": 3, 267 | "options": { 268 | "colorMode": "value", 269 | "graphMode": "area", 270 | "justifyMode": "auto", 271 | "orientation": "auto", 272 | "reduceOptions": { 273 | "calcs": ["lastNotNull"], 274 | "fields": "", 275 | "values": false 276 | }, 277 | "textMode": "auto" 278 | }, 279 | "targets": [ 280 | { 281 | "azureLogAnalytics": { 282 | "dashboardTime": true, 283 | "query": "ContainerLogV2\n| where PodName contains \"${PodName}\"\n| summarize TotalErrors = count()", 284 | "resources": ["/subscriptions/${sub}/resourceGroups/${rg}"], 285 | "resultFormat": "logs", 286 | "timeColumn": "TimeGenerated" 287 | }, 288 | "datasource": { 289 | "type": "grafana-azure-monitor-datasource", 290 | "uid": "azure-monitor-oob" 291 | }, 292 | "queryType": "Azure Log Analytics", 293 | "refId": "A" 294 | } 295 | ], 296 | "title": "Total Error Count", 297 | "type": "stat" 298 | } 299 | ], 300 | "refresh": "30s", 301 | "schemaVersion": 39, 302 | "tags": ["altinn", "kubernetes", "logs", "errors"], 303 | "templating": { 304 | "list": [ 305 | { 306 | "datasource": { 307 | "type": "grafana-azure-monitor-datasource", 308 | "uid": "azure-monitor-oob" 309 | }, 310 | "definition": "", 311 | "hide": 0, 312 | "includeAll": false, 313 | "label": "Subscription", 314 | "multi": false, 315 | "name": "sub", 316 | "options": [], 317 | "query": { 318 | "azureLogAnalytics": { 319 | "query": "", 320 | "resources": [] 321 | }, 322 | "queryType": "Azure Subscriptions", 323 | "refId": "A" 324 | }, 325 | "refresh": 1, 326 | "regex": "", 327 | "skipUrlSync": false, 328 | "sort": 5, 329 | "type": "query" 330 | }, 331 | { 332 | "datasource": { 333 | "type": "grafana-azure-monitor-datasource", 334 | "uid": "azure-monitor-oob" 335 | }, 336 | "definition": "", 337 | "hide": 0, 338 | "includeAll": false, 339 | "label": "Resource Group", 340 | "multi": false, 341 | "name": "rg", 342 | "options": [], 343 | "query": { 344 | "azureLogAnalytics": { 345 | "query": "", 346 | "resources": [] 347 | }, 348 | "queryType": "Azure Resource Groups", 349 | "refId": "A", 350 | "subscription": "$sub" 351 | }, 352 | "refresh": 1, 353 | "regex": "/^altinnapps-.*(?