# Accessing the controller event metrics

**URL:** <https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525>\
**Category:** Ziti Overlay\
**Created:** [May 25, 2022, 9:41am UTC](https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525 "2022-05-25T09:41:18Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![markamind](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/markamind/32/157_2.png) [@markamind](https://openziti.discourse.group/u/markamind)\
**Post date:** [May 25, 2022, 9:41am UTC](https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525/1 "2022-05-25T09:41:18Z")

</div>

There are some goroutine pool metrics mentioned in the latest release.

I am keen to analyse them… how do you access the data?

Ant tips?

> <https://github.com/openziti/ziti/blob/release-next/CHANGELOG.md>

---

<div class="post-metadata">

**Author:** ![TheLumberjack](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/thelumberjack/32/113_2.png) [@TheLumberjack](https://openziti.discourse.group/u/TheLumberjack)\
**Post date:** [May 25, 2022, 12:17pm UTC](https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525/2 "2022-05-25T12:17:25Z")

</div>

I’ll get someone to comment on this who’s configured the metrics lately. It’s not been something I’ve done myself. in the NetFoundry platform we send them to a file, that file is then shipped to kibana for ingest. that’s all done outside of openziti

---

<div class="post-metadata">

**Author:** ![mguthrie88](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/mguthrie88/32/151_2.png) [@mguthrie88](https://openziti.discourse.group/u/mguthrie88)\
**Post date:** [May 25, 2022, 12:42pm UTC](https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525/3 "2022-05-25T12:42:06Z")

</div>

Ziti has a LOT of data that you can tap into, this example is perhaps a bit overkill, but it should demonstrate how to pick and choose certain namespaces if you want to create filters or drop certain data types to specific files. This would need to go into your controller config.

```auto
metrics:
  reportInterval: 1m

events:

  jsonLogger:
    subscriptions:
     - type: metrics
       metricFilter: "link.latency.*"
     - type: metrics
       sourceFilter: .*
       metricFilter: "(.*session.create.*)|(bolt.*)"
     - type: metrics
       sourceFilter: .*
       metricFilter: "/edge*"
     - type: metrics
       metricFilter: "ctrl.*"
    handler:
      type: file
      format: json
      path: /var/log/ziti/metrics.log
      maxsizemb: 1024
      maxbackups: 1

  edgeSessionLogger:
    subscriptions:
     - type: edge.sessions
       include:
        - created
    handler:
      type: file
      format: json
      path: /var/log/ziti/edgesessions.log
      maxsizemb: 1024
      maxbackups: 1

```

If you want everything for a given type, just add:

```auto
  jsonLogger:
    subscriptions:
     - type: metrics
    handler:
      type: file
      format: json
      path: /var/log/ziti/metrics.log
      maxsizemb: 1024
      maxbackups: 1

```

---

<div class="post-metadata">

**Author:** ![markamind](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/markamind/32/157_2.png) [@markamind](https://openziti.discourse.group/u/markamind)\
**Post date:** [May 25, 2022, 1:14pm UTC](https://openziti.discourse.group/t/accessing-the-controller-event-metrics/525/4 "2022-05-25T13:14:32Z")

</div>

very cool… I will play with this tomorrow… 🙂
