Questions tagged [servicehost]

Implements the hosting object used to host a WCF service in self-hosted scenarios. Used for loading a service, configuring endpoints, applying security settings, and starting listeners to handle incoming requests.

Implements the hosting object used to host a WCF service in self-hosted scenarios. Used for loading a service, configuring endpoints, applying security settings, and starting listeners to handle incoming requests.

161 questions
0
votes
1 answer

Can WCF hosted in Windows Service accessible over internet?

I need some understanding about WCF. I am working on a client server application. Project plan is something like this. We have one server running a SQL Server 2008 over Windows 7 (I know windows 7 is not best choice for server but it has windows 7…
0
votes
1 answer

WCF Launching host error

I want to launch the following WCF service:
Juergen
  • 3,489
  • 6
  • 35
  • 59
0
votes
1 answer

Retrieving data received by the server using WCF Web Services

I'd like to use a web service (created in my main thanks to new ServiceHost(typeof(..)) ) and I would like to retrieve data received by my server to process it in my main. I've begun with a simple event handler but it is impossible because I have to…
Marti
  • 35
  • 1
  • 1
  • 3
0
votes
2 answers

WCF inter server code does not trigger TCP timeouts and Faults

I've tried to make an inter-server communication protocol with WCF. But for some reason, when a server disconnects, the Faulted neither the Closed events are called. This is really annoying but I haven't found a solution to it. private static…
Diamondo25
  • 769
  • 1
  • 8
  • 21
0
votes
1 answer

using custom principal in Workflow

I have an application that hosts several WCF services. I have created a custom ServiceAuthorizationManager that is working perfectly. I inspect a few elements on the OperationContext.IncomingMessageHeaders to get a username and password. This was…
Joshua
  • 839
  • 4
  • 12
  • 15
0
votes
1 answer

WCF constructor Service Type via DI

I'm currently trying to build a small App-Server which shall host multiple WCF services. These services (and their dependencies of course) should be instantiated by an DI/IoC Container (currently LightCore but since I am using it via the…
Pharao2k
  • 685
  • 4
  • 24
0
votes
2 answers

NetNamedPipeBinding: parameter in pipe method is empty

I have a ServiceHost listening on a NetNamedPipeBinding endpoint. I have a service contract class with a single method which is being called by the client and handled by the server. The method (We'll call it PipeRequest()) has a Request parameter.…
Trevor
  • 13,085
  • 13
  • 76
  • 99
0
votes
0 answers

Two WebServiceHost instances

I am using a library called SwaggerWcf to generate Swagger definitions for my application hosting a WCF REST API. I have finally made it work as I want it with the following code: var swaggerHost = new WebServiceHost(typeof(SwaggerWcfEndpoint)); …
Smith5727
  • 402
  • 4
  • 15
0
votes
1 answer

WCF - How to pass service class constructor parameter when initializing Service Host(TypeOf(Service-Class))

I have WCF service class 'MusicServiceManager' with the constructor that takes the parameter of IAppAmbientState. I need to pass parameter value to MusicServiceManager constructor at time initializing Service Host. I don't want singleton…
K.Z
  • 5,201
  • 25
  • 104
  • 240
0
votes
1 answer

Where should I cleanup private resources for a ServiceHost?

I've set up a WCF NamedPipes Server/Client pair of applications but when the Host stops and calls ServiceHost.Close() it doesn't seem to appropriately cleanup the object from which the Host was created (using an object rather than a type to…
chrisb2244
  • 2,940
  • 22
  • 44
0
votes
0 answers

WCF handle ungraceful disconnects in serviceHost

Is there a way to handle disconnects from a client that hasn't Closed the connection properly? I set up a test program that opened alot of connections to my wcf ServiceHost. I didn't close those connections properly. After awhile the Server stopped…
merger
  • 698
  • 1
  • 10
  • 28
0
votes
0 answers

Unable to start Topshelf service with command line parameter

I am using topshelf along with .net core and registering it with command line parameter something like below. x.AddCommandLineDefinition("mode", f => { mode = f; }); x.ApplyCommandLine(); The below commands for installing service works perfectly…
Prashant Mohite
  • 758
  • 2
  • 7
  • 19
0
votes
1 answer

Capture global WCF ServiceHost request events

I'm using a really simple WCF project which is being hosted by a WPF application. It basically operates as a REST server for dishing up data on my PC. No IIS, and it runs as SingleInstance. I want to see what IP's are accessing MyService, and what…
Tom
  • 3,354
  • 1
  • 22
  • 25
0
votes
1 answer

Calling WCF Service using NetTcpBinding from the same winform

Hey all I have the following code that allows me to start a temp web service for WCF services without spooling up IIS Express myself. However, the code below works just fine if I have the fetching of the data in another winform. Copying the same…
StealthRT
  • 10,108
  • 40
  • 183
  • 342
0
votes
1 answer

Host Service to receive notifications from Web Service in UWP

I'll explain my use case that I'm trying to solve which will give you clear picture of what I need? We have a web service hosted on a device and I'm able to consume the API's exposed by the service through the wsdl files that they share. But for…
SiD
  • 109
  • 1
  • 8