Skip to content

Commit

Permalink
Ajout de l'ID de thread dans les logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Dolite committed Dec 6, 2023
1 parent 895cc97 commit 21e09dc
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
* Sur les routes admin de ajout, modification et suppression de couche, on peut demander que les capacités des services ne soient pas regénérés
* Un nouvelle route admin (PUT /admin/layers) sans paramètre permet de demander la réécriture des capacités des services

### [Changed]

* Ajout de l'ID de thread dans les logs

## 5.2.1

### [Changed]
Expand Down Expand Up @@ -46,7 +50,7 @@ Implémentation partielle de l'API OGC Tiles - Part 1 [v1.0.0 final release](htt
* /ogcapitiles/collections/{layer}/map/tiles
* /ogcapitiles/collections/{layer}/tiles
* /ogcapitiles/tilematrixsets
* /ogcapitiles/tilematrixsets/{tms}
* /ogcapitiles/tilematrixsets/{tms}

* Liste des nouvelles routes pour obtenir le **GetTile** :

Expand Down
6 changes: 3 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,19 +140,19 @@ Rok4Server* loadConfiguration ( const char* serverConfigFile ) {
logging::add_file_log (
keywords::file_name = serverConf->getLogFilePrefix()+"-%Y-%m-%d-%H-%M-%S.log",
keywords::time_based_rotation = sinks::file::rotation_at_time_interval(boost::posix_time::seconds(serverConf->getLogFilePeriod())),
keywords::format = "%TimeStamp%\t%ProcessID%\t%Severity%\t%Message%",
keywords::format = "%TimeStamp%\t%ProcessID%\t%ThreadID%\t%Severity%\t%Message%",
keywords::auto_flush = true
);
} else if ( serverConf->getLogOutput() == "static_file") {
logging::add_file_log (
keywords::file_name = serverConf->getLogFilePrefix(),
keywords::format = "%TimeStamp%\t%ProcessID%\t%Severity%\t%Message%",
keywords::format = "%TimeStamp%\t%ProcessID%\t%ThreadID%\t%Severity%\t%Message%",
keywords::auto_flush = true
);
} else if ( serverConf->getLogOutput() == "standard_output") {
logging::add_console_log (
std::cout,
keywords::format = "%TimeStamp%\t%ProcessID%\t%Severity%\t%Message%"
keywords::format = "%TimeStamp%\t%ProcessID%\t%ThreadID%\t%Severity%\t%Message%"
);
}

Expand Down

0 comments on commit 21e09dc

Please sign in to comment.