mirror of
https://github.com/Telecominfraproject/wlan-cloud-ucentralsec.git
synced 2025-11-03 12:17:46 +00:00
Logging and framework update
This commit is contained in:
@@ -118,44 +118,12 @@ storage.type.mysql.database = ucentral
|
|||||||
storage.type.mysql.port = 3306
|
storage.type.mysql.port = 3306
|
||||||
storage.type.mysql.connectiontimeout = 60
|
storage.type.mysql.connectiontimeout = 60
|
||||||
|
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
########################################################################
|
########################################################################
|
||||||
#
|
#
|
||||||
# Logging: please leave as is for now.
|
# Logging: please leave as is for now.
|
||||||
#
|
#
|
||||||
########################################################################
|
########################################################################
|
||||||
logging.formatters.f1.class = PatternFormatter
|
logging.type = file
|
||||||
logging.formatters.f1.pattern = %s: [%p] %t
|
logging.path = $OWSEC_ROOT/logs
|
||||||
logging.formatters.f1.times = UTC
|
logging.level = debug
|
||||||
logging.channels.c1.class = ConsoleChannel
|
|
||||||
logging.channels.c1.formatter = f1
|
|
||||||
|
|
||||||
# This is where the logs will be written. This path MUST exist
|
|
||||||
logging.channels.c2.class = FileChannel
|
|
||||||
logging.channels.c2.path = $OWSEC_ROOT/logs/log
|
|
||||||
logging.channels.c2.formatter.class = PatternFormatter
|
|
||||||
logging.channels.c2.formatter.pattern = %Y-%m-%d %H:%M:%S %s: [%p] %t
|
|
||||||
logging.channels.c2.rotation = 20 M
|
|
||||||
logging.channels.c2.archive = timestamp
|
|
||||||
logging.channels.c2.purgeCount = 20
|
|
||||||
logging.channels.c3.class = ConsoleChannel
|
|
||||||
logging.channels.c3.pattern = %s: [%p] %t
|
|
||||||
|
|
||||||
# External Channel
|
|
||||||
logging.loggers.root.channel = c2
|
|
||||||
logging.loggers.root.level = debug
|
|
||||||
|
|
||||||
# Inline Channel with PatternFormatter
|
|
||||||
# logging.loggers.l1.name = logger1
|
|
||||||
# logging.loggers.l1.channel.class = ConsoleChannel
|
|
||||||
# logging.loggers.l1.channel.pattern = %s: [%p] %t
|
|
||||||
# logging.loggers.l1.level = information
|
|
||||||
# SplitterChannel
|
|
||||||
# logging.channels.splitter.class = SplitterChannel
|
|
||||||
# logging.channels.splitter.channels = l1,l2
|
|
||||||
# logging.loggers.l2.name = logger2
|
|
||||||
# logging.loggers.l2.channel = splitter
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -192,6 +192,10 @@ namespace OpenWifi::GWObjects {
|
|||||||
field_to_json(Obj,"lastContact", LastContact);
|
field_to_json(Obj,"lastContact", LastContact);
|
||||||
field_to_json(Obj,"associations_2G", Associations_2G);
|
field_to_json(Obj,"associations_2G", Associations_2G);
|
||||||
field_to_json(Obj,"associations_5G", Associations_5G);
|
field_to_json(Obj,"associations_5G", Associations_5G);
|
||||||
|
field_to_json(Obj,"webSocketClients", webSocketClients);
|
||||||
|
field_to_json(Obj,"websocketPackets", websocketPackets);
|
||||||
|
field_to_json(Obj,"kafkaClients", kafkaClients);
|
||||||
|
field_to_json(Obj,"kafkaPackets", kafkaPackets);
|
||||||
|
|
||||||
switch(VerifiedCertificate) {
|
switch(VerifiedCertificate) {
|
||||||
case NO_CERTIFICATE:
|
case NO_CERTIFICATE:
|
||||||
|
|||||||
@@ -34,6 +34,10 @@ namespace OpenWifi::GWObjects {
|
|||||||
std::string Firmware;
|
std::string Firmware;
|
||||||
CertificateValidation VerifiedCertificate = NO_CERTIFICATE;
|
CertificateValidation VerifiedCertificate = NO_CERTIFICATE;
|
||||||
std::string Compatible;
|
std::string Compatible;
|
||||||
|
uint64_t kafkaClients=0;
|
||||||
|
uint64_t webSocketClients=0;
|
||||||
|
uint64_t kafkaPackets=0;
|
||||||
|
uint64_t websocketPackets=0;
|
||||||
void to_json(Poco::JSON::Object &Obj) const;
|
void to_json(Poco::JSON::Object &Obj) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ namespace OpenWifi::KafkaTopics {
|
|||||||
static const std::string COMMAND{"command"};
|
static const std::string COMMAND{"command"};
|
||||||
static const std::string SERVICE_EVENTS{"service_events"};
|
static const std::string SERVICE_EVENTS{"service_events"};
|
||||||
static const std::string DEVICE_EVENT_QUEUE{"device_event_queue"};
|
static const std::string DEVICE_EVENT_QUEUE{"device_event_queue"};
|
||||||
|
static const std::string DEVICE_TELEMETRY{"device_telemetry"};
|
||||||
|
|
||||||
namespace ServiceEvents {
|
namespace ServiceEvents {
|
||||||
static const std::string EVENT_JOIN{"join"};
|
static const std::string EVENT_JOIN{"join"};
|
||||||
|
|||||||
@@ -84,6 +84,7 @@ namespace OpenWifi::RESTAPI::Protocol {
|
|||||||
static const char * GETSUBSYSTEMNAMES = "getsubsystemnames";
|
static const char * GETSUBSYSTEMNAMES = "getsubsystemnames";
|
||||||
static const char * GETLOGLEVELNAMES = "getloglevelnames";
|
static const char * GETLOGLEVELNAMES = "getloglevelnames";
|
||||||
static const char * STATS = "stats";
|
static const char * STATS = "stats";
|
||||||
|
static const char * PING = "ping";
|
||||||
static const char * PARAMETERS = "parameters";
|
static const char * PARAMETERS = "parameters";
|
||||||
static const char * VALUE = "value";
|
static const char * VALUE = "value";
|
||||||
static const char * LASTONLY = "lastOnly";
|
static const char * LASTONLY = "lastOnly";
|
||||||
|
|||||||
Reference in New Issue
Block a user