Microphone icon indicating copy to clipboard operation
Microphone copied to clipboard

Add WCF support

Open roh85 opened this issue 8 years ago • 2 comments

I like the idea of Microphone. In our enterprise we have a lot of WCF services. Therefore I am investigating if it is possible to add WCF support to Microphone. I would appreciate it if you would be able to help me getting started by giving me some high level info how to best approach this.

roh85 avatar Sep 17 '16 08:09 roh85

It would absolutely be possible. We might end up using that support too at work as we do have a fair share of WCF there.

This would be the absolute bare minimum to get up and running

var loggerFactory = new LoggerFactory();
var logger = loggerFactory.CreateLogger("Cluster");
var options = new OptionsWrapper<ConsulOptions>(new ConsulOptions
{
    //configure consul here               
});
Cluster.RegisterService(new Uri("http://my.service"),new ConsulProvider(loggerFactory, options),"serviceName","1.0", logger);

You can call this from whatever start up code your service have, e.g. global asax or whatever.

rogeralsing avatar Sep 17 '16 17:09 rogeralsing

+1

marcofranssen avatar Oct 20 '16 12:10 marcofranssen