Enable raw metrics for Gravitee

To enable raw metrisc in Gravitee, you need to enable the file reporter in the Gravitee gateway. If you are running the gateway as a container, the easiest way to achive this, is to provide an environment variable named gravitee_reporters_file_enabled and set its value to true. Click here to learn more about configuring file reporter. You do not need to enable all event types for file reporter. Only the request event type needs to be enabled. Also, you can change the default file name pattern, as long as the filename always contains ‘request’, as this is how the agent identifies the correct files.

Once file reporter is enabled, the files must be made accessible by API Control Plane agent. If you run the gateway in a container, you will have to mount a volume to the path where the files are stored. The same volume must then be mounted somewhere into the agent container. To actually enable the processing of raw metrics by the agent, you must add a configuration parameter named metricsDir (either in agent config file, or as enviornment variable gateway.metricsDir) and set it to the path inside the agent container, where you mounted the report files directory.