Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6690619
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:39:29+00:00 2026-05-26T05:39:29+00:00

I try to do the following: I have a Windows service which is running

  • 0

I try to do the following:

I have a Windows service which is running a TCP WCF service.

Now, I want to implement a client, which can connect to this service. But this client doesn’t know the contract of the service. He knows that the service does provide a method Download (string path). I want to connect to the service and call Download("c:\\temp\\xxx.exe").

I have tried the following:

var myBinding = new NetTcpBinding(SecurityMode.None)
{
    TransferMode = TransferMode.Streamed,
    MaxBufferPoolSize = 524288,
    MaxBufferSize = 2147483647,
    MaxConnections = 254,
    MaxReceivedMessageSize = 2147483647,
    PortSharingEnabled = true
};

var myEndpoint = new EndpointAddress("net.tcp://localhost:6648/InstallerBootstrapperService");

var myChannelFactory = new ChannelFactory<IInstallerBootstrapperService>(myBinding, myEndpoint);

IInstallerBootstrapperService client = null;

try {
    client = myChannelFactory.CreateChannel();
    client.Download("c:\\temp\\xxx.exe");
    ((ICommunicationObject) client).Close();
} catch {
   if (client != null) {
        ((ICommunicationObject) client).Abort();
   }
}

But this throw an Exception when I call Download(). It says:

The message with Action
‘Prayon.Service.Library/IInstallerBootstrapperService/Download’ cannot
be processed at the receiver, due to a ContractFilter mismatch at the
EndpointDispatcher. This may be because of either a contract mismatch
(mismatched Actions between sender and receiver) or a binding/security
mismatch between the sender and the receiver. Check that sender and
receiver have the same contract and the same binding (including
security requirements, e.g. Message, Transport, None).

Is there a way that I can call the service method without knowing the contract? Can I change something on the service side, that this client can always call the method?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T05:39:29+00:00Added an answer on May 26, 2026 at 5:39 am

    Server has no idea what client has as a contract, what server knows instead is what client sends it as a SOAP request which should has proper information inside, so WCF plumbing would find appropriate contract on the service type and find operation that would match also.
    Depending on the filtering settings service type together with ServiceModel settings can be set up on not using filtering and in this case you do not need to match namespaces for example, moreover server can be setup in such a way that particular method catch all the calls from clients, regardless of information placed in SOAP request.

    So the error you get clearly tells you that filter mismatch which means either Namespace property of contract on client is not the same as on the server or security settings are different

    to fix namespace you define contract on client like this

     [ServiceContract(
          Namespace="namespaceuri",
          Name="contractname")]
     public interface IInstallerBootstrapperService {
    
          [OperationContract(
                 Namespace="namespaceuri", 
                 Action ="actionuri", 
                 ReplyAction="replyactionuri")]
          void Download( string path);
    
     }
    

    and namespace property of both attributes should match those on server.

    to fix other settings that can mismatch you need to know what transactionFlow, transport and message security and encoding and messageversion of server endpoint

    at first try netTcp default settings they are likely to match

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a windows service which i can't run or start, only install or
I have a .NET windows service which acts as a host for some wcf.
I have a sample windows service which I got from the following link. http://an-it-solution.blogspot.com/2009/05/how-to-make-windows-service-using-c.html
How I can start reading from a specific byte? I have following code: try
I have a .NET Windows Service which spawns a thread that basically just acts
I'm trying to create a client for a WCF service that I have hosted
I have a ASMX web services running as 'network service'. I want to be
I wonder if anyone can advise. I have written a .NET 4 WCF service
We have a windows service that has been happily running in production for over
I have the following class in a Windows Service that is experiencing some vary

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.