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

Fix issues with WcfLogReceiverClient - alternative #821

Merged
merged 25 commits into from
Aug 26, 2015
Merged

Fix issues with WcfLogReceiverClient - alternative #821

merged 25 commits into from
Aug 26, 2015

Conversation

304NotModified
Copy link
Member

More backwardscompatible to v4. Both one and two way are now unit tested with a ServiceHost

Keep the facade idea, but a bit different

  • WcfLogReceiverClient is renamed to WcfLogReceiverOneWayClient. We have now WcfLogReceiverOneWayClient and WcfLogReceiverTwoWayClient. Both will implement the same (new) interface.
  • WcfLogReceiverClientFacade is renamed to WcfLogReceiverClient
  • WcfLogReceiverClient (the facade) now delegates (almost) everything of WcfLogReceiverOneWayClient/WcfLogReceiverTwoWayClient.
  • WcfLogReceiverClient has a Proxy property, if still something is missing (cast is probably required for the end-user)

Things to think about:

  • ILogReceiverClient is renamed to ILogReceiverOneWayClient. This is not needed, maybe revert it. (there are already some inconsistent namings to bad)
  • The WcfLogReceiverOneWayClient and WcfLogReceiverTwoWayClient does contain code duplication due to the ClientBase inheritance. Difficult to solve with delegates. Maybe fix with T4.

TODO

  • re-enable the warnings as error, and fix the xmldocs
  • enable cookiecontainer

@304NotModified 304NotModified changed the title Wcf backwardsomp t4 Fix issues with WcfLogReceiverClient #2 Jul 26, 2015
@304NotModified 304NotModified modified the milestone: 4.1 Aug 13, 2015
@304NotModified 304NotModified changed the title Fix issues with WcfLogReceiverClient #2 Fix issues with WcfLogReceiverClient - alternative Aug 13, 2015
@304NotModified
Copy link
Member Author

  • compare code with NLog 3.2.1
  • revert ILogReceiverClient is renamed to ILogReceiverOneWayClient ?

@kevindaub
Copy link
Contributor

ILogReceiverClient.cs - Breaks compatibility because it doesn't have any of the methods from 3.2.1
WcfLogReceiverClient.cs - No longer inherits from Clientbase.
WcfLogReceiverOneWayClient.cs - is equivalent to WcfLogReceiver in 3.2.1

For better backwards compatibility to 3.2.1:

  • Keep methods and attributes 3.2.1 in ILogReceiverClient
  • Keep WcfLogReceiverClient using ILogReceiverClient, but mark as deprecated, so that we can clean up and move people to ILogReceiverOneWayClient/ILogReceiverTwoWayClient

For better backwards compatibility to 4.0.1:

  • Keep methods and attributes in ILogReceiverOneWayClient

For TwoWay Client:

  • Duplicate ILogReceiverOneWayClient, but make it replace OneWay with TwoWay

Long Term Suggestions:

  • As already suggested, use T4 template to generate ILogReceiverClient, ILogReceiverOneWayClient, and ILogReceiverTwoWayClient
  • As already suggested, use T4 template to generate LogReceiverClients

@kevindaub kevindaub mentioned this pull request Aug 24, 2015
5 tasks
@304NotModified 304NotModified merged commit 3caca67 into NLog:master Aug 26, 2015
@304NotModified
Copy link
Member Author

fixed by #874

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

Successfully merging this pull request may close these issues.

None yet

2 participants