# CPEE Logging XES YAML
To install the logging service go to the commandline
```bash
gem install cpee-logging-xes-yaml
cpee-logging-xes-yaml log
cd log
./log start
```
The service is running under port 9299. If this port has to be changed (or the
host, or local-only access, ...), create a file log.conf and add one
or many of the following yaml keys:
```yaml
:port: 9250
:host: cpee.org
:bind: 127.0.0.1
:log_dir: /var/log/cpee
```
To connec the cpee to the log, one of two things can be done: (1) add a handler to
a testset/template:
```xml
calling,receiving,done
change
change
change
instantiation
```
(2) add a default handler to the cpee by adding
```ruby
Riddl::Server.new(CPEE::SERVER, options) do
...
@riddl_opts[:notifications_init] = File.join(__dir__,'resources','notifications')
...
use CPEE::implementation(@riddl_opts)
end.loop!
```
to the server (or alternatively to a log.conf with :notification_init
beeing a top-level yaml key). Then add a subscription file to
notifications/logging/subscription.xml
```xml
calling
receiving
done
change
change
change
instantiation
```