locked
Host .svg Fail in IIS7 . RRS feed

  • Question

  • User860115423 posted

    I got a error call; how to solve this issus ??? please help

     Server Error in '/WebService' Application.


    This collection already contains an address with scheme http.  There can be at most one address per scheme in this collection.
    Parameter name: item

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: This collection already contains an address with scheme http.  There can be at most one address per scheme in this collection.
    Parameter name: item

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [ArgumentException: This collection already contains an address with scheme http.  There can be at most one address per scheme in this collection. 
    Parameter name: item]
       System.ServiceModel.UriSchemeKeyedCollection.InsertItem(Int32 index, Uri item) +4304549
       System.Collections.Generic.SynchronizedCollection`1.Add(T item) +56
       System.ServiceModel.UriSchemeKeyedCollection..ctor(Uri[] addresses) +120
       System.ServiceModel.ServiceHost..ctor(Type serviceType, Uri[] baseAddresses) +155
       System.ServiceModel.Activation.ServiceHostFactory.CreateServiceHost(Type serviceType, Uri[] baseAddresses) +28
       System.ServiceModel.Activation.ServiceHostFactory.CreateServiceHost(String constructorString, Uri[] baseAddresses) +323
       System.ServiceModel.HostingManager.CreateService(String normalizedVirtualPath) +698
       System.ServiceModel.HostingManager.ActivateService(String normalizedVirtualPath) +31
       System.ServiceModel.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath) +445
    
    [ServiceActivationException: The service '/WebService/sharestateservice.svc' cannot be activated due to an exception during compilation.  The exception message is: This collection already contains an address with scheme http.  There can be at most one address per scheme in this collection. 
    Parameter name: item.]
       System.ServiceModel.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath) +962
       System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath) +419
       System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest() +264
       System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest() +760
       System.ServiceModel.Activation.HostedHttpModuleRequestAsyncResult.BeginRequest() +178
       System.ServiceModel.Activation.HttpModule.StartBeginProcessRequest(Object sender, EventArgs e, AsyncCallback cb, Object extraData) +70
       System.ServiceModel.Activation.HttpModule.ProcessRequest(Object sender, EventArgs e) +195
       System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +92
       System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64
    


    Version Information: Microsoft .NET Framework Version:2.0.50727.312; ASP.NET Version:2.0.50727.312 <!-- [ArgumentException]: This collection already contains an address with scheme http. There can be at most one address per scheme in this collection. Parameter name: item at System.ServiceModel.UriSchemeKeyedCollection.InsertItem(Int32 index, Uri item) at System.Collections.Generic.SynchronizedCollection`1.Add(T item) at System.ServiceModel.UriSchemeKeyedCollection..ctor(Uri[] addresses) at System.ServiceModel.ServiceHost..ctor(Type serviceType, Uri[] baseAddresses) at System.ServiceModel.Activation.ServiceHostFactory.CreateServiceHost(Type serviceType, Uri[] baseAddresses) at System.ServiceModel.Activation.ServiceHostFactory.CreateServiceHost(String constructorString, Uri[] baseAddresses) at System.ServiceModel.ServiceHostingEnvironment.HostingManager.CreateService(String normalizedVirtualPath) at System.ServiceModel.ServiceHostingEnvironment.HostingManager.ActivateService(String normalizedVirtualPath) at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath) [ServiceActivationException]: The service '/WebService/sharestateservice.svc' cannot be activated due to an exception during compilation. The exception message is: This collection already contains an address with scheme http. There can be at most one address per scheme in this collection. Parameter name: item. at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath) at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath) at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest() at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest() at System.ServiceModel.Activation.HostedHttpModuleRequestAsyncResult.BeginRequest() at System.ServiceModel.Activation.HttpModule.StartBeginProcessRequest(Object sender, EventArgs e, AsyncCallback cb, Object extraData) at System.ServiceModel.Activation.HttpModule.ProcessRequest(Object sender, EventArgs e) at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) -->

    Tuesday, May 15, 2007 3:05 AM

All replies

  • User860115423 posted

    Hi. but In fact, I am only using configuration config. no any program control WCF Hosting.

    below is the config.

    <configuration>
      <system.serviceModel>
        <services>
           <service name="ShareStateService" behaviorConfiguration="MyServiceBehaviors">
       <endpoint contract="IShareStateService" binding="wsHttpBinding"/>
          <endpoint contract="IMetadataExchange" binding="mexHttpBinding" address="mex" />
        </service>
       </services>
      
       <behaviors>
           <serviceBehaviors>
               <behavior name="MyServiceBehaviors" >
                        <serviceMetadata httpGetEnabled="true" />
                    </behavior>
                </serviceBehaviors>
        </behaviors>
      
      </system.serviceModel>
    </configuration>

    Friday, May 18, 2007 11:32 PM