Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing handling for LoggingEvent properties #7

Merged

Conversation

@asser-dk
Copy link

@asser-dk asser-dk commented Mar 3, 2017

Occasionally we need properties tied to a specific event and not a ThreadContext which is shared across the entire thread. This hooks into the built in functionality in log4net for this scenario.

Occasionally we need properties tied to a specific event and not a ThreadContext which is shared across the entire thread. This hooks into the built in functionality in log4net for this scenario.
@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 3, 2017

Thanks this looks like a good addition I just need someone else to test it since we don't have unit tests set up yet

@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 8, 2017

@mostlyjason do you want me to set up a unit test project and add some tests for this PR?

@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 8, 2017

@asser-dk oh wow I wasn't expecting you to volunteer, but it would definitely be appreciated!

@asser-dk asser-dk force-pushed the asser-dk:add-handling-for-logging-event-properties branch from 706a4ab to 37baefd Mar 9, 2017
@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 9, 2017

@mostlyjason There we go. I've added some unit tests for the pre parse method in the LogglyFormatter.

I also found an issue (I guess it qualifies as that) when writing these tests. Depending on which context you used, if you stored a complex type (like a model object) it would either be serialized as "MyNamespace.Models.MyComplexType" or it would be serialized as a proper json object. My "Harmonize" commit aligns all these cases so complex types are always serialized as json objects.

If you want that change in a separate pull request let me know and I'll do that instead :)

@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 9, 2017

Wow this is really awesome! Thanks for making the contribution. Since this is a big change in the first time we are adding unit tests, I'm going to ask our developer to do some manual testing as well.

…ndling-for-logging-event-properties

Conflicts:
	source/log4net-loggly/LogglyFormatter.cs
	source/log4net-loggly/log4net-loggly.csproj
@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 13, 2017

@mostlyjason do you have an idea of when you'll be able to look at this and hopefully merge+release it? I have some PO's breathing down my neck (and they have very bad breath) 😄

@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 13, 2017

@asser-dk I understand let me talk to my developer and see if we can get this one moved up. I'm hoping she can take a look in the next couple days.

@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 16, 2017

Our engineer tested this and it worked fine. Thanks so much @asser-dk! I'm merging these changes and our engineer will release a new beta version on nuget.

@mostlyjason mostlyjason merged commit a2892c6 into loggly:master Mar 16, 2017
@asser-dk asser-dk deleted the asser-dk:add-handling-for-logging-event-properties branch Mar 16, 2017
@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 17, 2017

@asser-dk we published the new package can you test this one? https://www.nuget.org/packages/log4net-loggly/7.3.2-beta

@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 20, 2017

@mostlyjason sure. I'll have a look at it later today.

@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 20, 2017

@mostlyjason There seems to be an issue with the nuget package. It doesn't contain the lib folder (or anything for that matter besides the .nupkg file). I downloaded the 7.2.3 version which contains this.

log4net-loggly.7.3.2-beta package contents:

log4net-loggly.7.3.2-beta.nupkg

log4net-loggly.7.2.3 package contents:

log4net-loggly.7.2.3.nupkg
lib
    net40
          log4net-loggly.dll
@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 20, 2017

@Shwetajain148 can you take a look at the package to make sure it was built correctly?

@asser-dk
Copy link
Author

@asser-dk asser-dk commented Mar 22, 2017

works :)

@mostlyjason
Copy link

@mostlyjason mostlyjason commented Mar 23, 2017

Great thanks we will work on releasing a new production version

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.