wcf - Could not find a base address that matches scheme net.msmq -
i trying create self-hosted service listens amessage queue, , sends email when message put in queue. however, getting rather known error
could not find base address matches scheme net.msmq endpoint binding netmsmqbinding. registered base address schemes [http].
i have removed http stuff in config file, know fact msmq working on computer, have msmq running fine. mailnotificationagentqueue created.
here config:
<?xml version="1.0"?> <configuration> <appsettings> <add key="aspnet:usetaskfriendlysynchronizationcontext" value="true" /> </appsettings> <system.web> <compilation debug="true" targetframework="4.5" /> <httpruntime targetframework="4.5"/> </system.web> <system.servicemodel> <bindings> <netmsmqbinding> <binding exactlyonce="false" deadletterqueue="none" durable="true" maxretrycycles="10" receiveretrycount="10" useactivedirectory="true" receiveerrorhandling="fault"> <security mode="transport"> <transport msmqauthenticationmode="windowsdomain" /> </security> </binding> </netmsmqbinding> </bindings> <behaviors> <servicebehaviors> <behavior name="mailnotificationagentendpointbehavior"> <servicedebug includeexceptiondetailinfaults="true"/> </behavior> </servicebehaviors> </behaviors> <protocolmapping> <add binding="netmsmqbinding" scheme="net.msmq" /> </protocolmapping> <servicehostingenvironment aspnetcompatibilityenabled="true" multiplesitebindingsenabled="true" /> <services> <service name="mailnotificationagent.mailnotificationagentservice" behaviorconfiguration="mailnotificationagentendpointbehavior"> <endpoint address="" binding="netmsmqbinding" name="msmqendpoint" contract="mailnotificationagent.imailnotificationagentservice" /> <host> <baseaddresses> <add baseaddress="net.msmq://<mycomputername>/private/mailnotificationagentqueue" /> </baseaddresses> </host> </service> </services> </system.servicemodel> <system.webserver> <modules runallmanagedmodulesforallrequests="true"/> <directorybrowse enabled="true"/> </system.webserver>
thanks in advance!
Comments
Post a Comment