Results 1 to 12 of 12

Thread: Self-Hosted WCF Application Deployment Problem

  1. #1

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Exclamation Self-Hosted WCF Application Deployment Problem

    I have a middle-ware project/application that all of the in-coming and out-going requests through TCP are Add-ins.
    And one of the front-side add-ins is a Self-Hosted Web Service through WCF that allows anonymous connection.

    It is working properly when I run it with Debugging; I can access the Web-Service properly in my test-client application and even in a Web-browser.
    However, when I'm going to run it without Debugging, I can't access the Web Service in my test application and Web-Browser.

    Thanks for any help.

  2. #2

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    Any idea about this problem?
    Thanks.

  3. #3
    Frenzied Member Lightning's Avatar
    Join Date
    Oct 2002
    Location
    Eygelshoven
    Posts
    1,611

    Re: Self-Hosted WCF Application Deployment Problem

    Is the service started???? Because the debugger automatically starts the service,
    VB6 & C# (WCF LINQ) mostly


    If you need help with a WPF/WCF question post in the NEW WPF & WCF forum and we will try help the best we can

    My site

    My blog, couding troubles and solutions

    Free online tools

  4. #4

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    Yes, it is started.
    When I try to start another service using a console command with; it raise an exception that tells me that the URL is already in use.

  5. #5
    Frenzied Member Lightning's Avatar
    Join Date
    Oct 2002
    Location
    Eygelshoven
    Posts
    1,611

    Re: Self-Hosted WCF Application Deployment Problem

    Do you get an error? or just: page not found?
    VB6 & C# (WCF LINQ) mostly


    If you need help with a WPF/WCF question post in the NEW WPF & WCF forum and we will try help the best we can

    My site

    My blog, couding troubles and solutions

    Free online tools

  6. #6

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    I think I found out the problem.

    The project is a console-based middle-ware application which establishes multiple socket connections for inbound and outbound requests as plug-ins through System.Addins.
    And one of these add-ins is a self-hosted Web Service through WCF.
    The pre-requisites for this class-library project(Self-hosted Web Service) to become an add-in; it must add a reference of the Addin.View DLL and implement one of the class-library's abstract classes. The output file(DLL) must be placed in Addins directory but the Addins.View DLL must not be copied there or it won't be loaded as its add-ins.
    But the WCF's service won't start probably because of it can't find its reference DLLs.

  7. #7

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    Quote Originally Posted by Lightning View Post
    Do you get an error? or just: page not found?
    On the Web Browser; the error message is Unable to Connect but through WCF Test Client(WcfTestClient.exe); the error message is:
    Error: Cannot obtain Metadata from http://localhost:8001/PRG?wsdl If this is a Windows (R) Communication Foundation service to which you have access, please check that you have enabled metadata publishing at the specified address. For help enabling metadata publishing, please refer to the MSDN documentation at http://go.microsoft.com/fwlink/?Link...55.WS-Metadata Exchange Error URI: http://localhost:8001/PRG?wsdl Metadata contains a reference that cannot be resolved: 'http://localhost:8001/PRG?wsdl'. An error occurred while receiving the HTTP response to http://localhost:8001/PRG?wsdl. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details. The underlying connection was closed: An unexpected error occurred on a receive. Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. An existing connection was forcibly closed by the remote hostHTTP GET Error URI: http://localhost:8001/PRG?wsdl There was an error downloading 'http://localhost:8001/PRG?wsdl'. The underlying connection was closed: An unexpected error occurred on a receive. Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. An existing connection was forcibly closed by the remote host

  8. #8
    Frenzied Member Lightning's Avatar
    Join Date
    Oct 2002
    Location
    Eygelshoven
    Posts
    1,611

    Re: Self-Hosted WCF Application Deployment Problem

    This error means that you don't have a "mex" endpoint defined in you config file.
    ex.
    <endpoint address="" binding="basicHttpBinding" contract="Test.TestSevice">

    </endpoint>
    <!-- Metadata Endpoints -->
    <!-- The Metadata Exchange endpoint is used by the service to describe itself to clients. -->
    <!-- This endpoint does not use a secure binding and should be secured or removed before deployment -->
    <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>
    VB6 & C# (WCF LINQ) mostly


    If you need help with a WPF/WCF question post in the NEW WPF & WCF forum and we will try help the best we can

    My site

    My blog, couding troubles and solutions

    Free online tools

  9. #9

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    The config file exists but when the reference DLL, the Addin.View part, have a copy in the directory where my WCF-based front-end plug-in located, it doesn't work.
    But if the Addin.View DLL is present on the plug-ins directory; it can't be read as a plug-in.

  10. #10

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    I'll re-open this issue.

    The WCF-based web-service and it's WSDL can be browse through a Web Browser in both debug and without debugging.
    I can add the reference and call the methods from my test applications in debug mode(server), but when I run the server without debugging and add reference or call a method; I can't browse the service through a web browser and it shows the error message "Connection Reset".

    To be able to see the service in a browser during the "run without debugging"; I need to re-run the application in debug mode then re-run it without debugging.

    Thanks for the help.

  11. #11
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Self-Hosted WCF Application Deployment Problem

    Not sure if someone's ask this but is the console app actually running when you attempt to browse to it? I don't know what you're referring to by run without debugging and rerunning here. If this is a console based self hosted WCF service, then you need to keep it running at all times.

  12. #12

    Thread Starter
    Fanatic Member eSPiYa's Avatar
    Join Date
    Jun 2006
    Location
    in our house
    Posts
    751

    Re: Self-Hosted WCF Application Deployment Problem

    Hi Mendhak, about running without debugging; I'm referring about the sub-menu under the Debug menu in MSVS2008 and I'm sure the console and service is running.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width