Skip to content
Merged
1 change: 1 addition & 0 deletions legacy/LegacyNetworkAPIs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ namespace WPEFramework

const string Network::Initialize(PluginHost::IShell* service )
{
NetworkManagerLogger::Init();
m_service = service;
m_service->AddRef();
string message{};
Expand Down
1 change: 1 addition & 0 deletions legacy/LegacyWiFiManagerAPIs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ namespace WPEFramework

const string WiFiManager::Initialize(PluginHost::IShell* service )
{
NetworkManagerLogger::Init();
m_service = service;
string message{};

Expand Down
11 changes: 5 additions & 6 deletions plugin/NetworkManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,6 @@ namespace WPEFramework
// Still running inside the main WPEFramework process - the child process will have now been spawned and registered if necessary
if (_networkManager != nullptr)
{

// Set the plugin log level
Exchange::INetworkManager::Logging _loglevel;
_networkManager->GetLogLevel(_loglevel);
NetworkManagerLogger::SetLevel(static_cast <NetworkManagerLogger::LogLevel>(_loglevel));

// Register Notifications
SYSLOG(Logging::Startup, (_T("Registering Notification to NetworkManager")));
_networkManager->Register(&_notification);
Expand All @@ -103,6 +97,11 @@ namespace WPEFramework
{
SYSLOG(Logging::Startup, (_T("Configuring successful")));
}

// Set the plugin log level
Exchange::INetworkManager::Logging _loglevel;
_networkManager->GetLogLevel(_loglevel);
NetworkManagerLogger::SetLevel(static_cast <NetworkManagerLogger::LogLevel>(_loglevel));
Comment thread
gururaajar marked this conversation as resolved.
// Register all custom JSON-RPC methods
SYSLOG(Logging::Startup, (_T("Registering JSONRPC Methods")));
RegisterAllMethods();
Expand Down
6 changes: 3 additions & 3 deletions plugin/NetworkManagerImplementation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ namespace WPEFramework

/* Initialize Network Manager */
NetworkManagerLogger::Init();
NMLOG_INFO((_T("NWMgrPlugin Out-Of-Process Instantiation; SHA: " _T(EXPAND_AND_QUOTE(PLUGIN_BUILD_REFERENCE)))));
SYSLOG(::WPEFramework::Logging::Startup, (_T("NWMgrPlugin Out-Of-Process Instantiation; SHA: ") _T(EXPAND_AND_QUOTE(PLUGIN_BUILD_REFERENCE))));
m_processMonThread = std::thread(&NetworkManagerImplementation::processMonitor, this, NM_PROCESS_MONITOR_INTERVAL_SEC);
#if USE_TELEMETRY
// Initialize Telemetry T2 for NwMgrPlugin
Expand Down Expand Up @@ -142,12 +142,12 @@ namespace WPEFramework
Configuration config;
if(configLine.empty())
{
NMLOG_FATAL("config line : is empty !");
SYSLOG(::WPEFramework::Logging::Shutdown, (_T("config line is empty")));
return Core::ERROR_GENERAL;
Comment thread
gururaajar marked this conversation as resolved.
}
else
{
NMLOG_INFO("Loading the incoming configuration : %s", configLine.c_str());
SYSLOG(::WPEFramework::Logging::Startup, (_T("Loading incoming configuration")));
config.FromString(configLine);
}

Expand Down
Loading