logging - Cannot log to Windows Events system on .Net Core 1.1 -


i'm trying add event logging asp.net core 1.1 web api (running on windows server 2012) such:

public void configure(iapplicationbuilder app, ihostingenvironment env, iloggerfactory loggerfactory)     {         loggerfactory.addconsole(configuration.getsection("logging"));         loggerfactory.adddebug();         loggerfactory.addeventlog();     } 

but tells me:

'iloggerfactory' not contain definition 'addeventlog' , no extension method 'addeventlog' accepting first argument of type 'iloggerfactory' found (are missing using directive or assembly reference?)

i've tried add "microsoft.extensions.logging.eventlog" project via nuget, says:

package microsoft.extensions.logging.eventlog 1.1.2 not compatible netcoreapp1.1 (.netcoreapp,version=v1.1). package microsoft.extensions.logging.eventlog 1.1.2 supports: net451 (.netframework,version=v4.5.1)  1 or more packages incompatible .netcoreapp,version=v1.1.  package restore failed. rolling package changes 'propworx.api'. 

i guess means it's not possible log windos event system on .net core 1.1?

thanks


Comments

Popular posts from this blog

html - How to set bootstrap input responsive width? -

javascript - Highchart x and y axes data from json -

javascript - Get js console.log as python variable in QWebView pyqt -