SSIS Script Component destinantion to WCF service
Hi I have been struggling to find a sensible answert to this issue. Using VS2008, we have a package attempting to use a WCF service which has some basic functionality to post user notes to a table. The service has been proven to work outside of the SSIS call. When calling in a script component destination the below error is received. Any direction would be appreciated. So far we have tried various changes to the app.config, including fully qualifying the contract name. Could not find default endpoint element that references contract 'DataService.VanquisDataService' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element. at System.ServiceModel.Description.ConfigLoader.LoadChannelBehaviors(ServiceEndpoint serviceEndpoint, String configurationName) at System.ServiceModel.ChannelFactory.InitializeEndpoint(String configurationName, EndpointAddress address) at System.ServiceModel.ChannelFactory`1..ctor(String endpointConfigurationName, EndpointAddress remoteAddress) at System.ServiceModel.ChannelFactory`1..ctor(String endpointConfigurationName) at System.ServiceModel.EndpointTrait`1.CreateSimplexFactory() at System.ServiceModel.EndpointTrait`1.CreateChannelFactory() at System.ServiceModel.ClientBase`1.CreateChannelFactoryRef(EndpointTrait`1 endpointTrait) at System.ServiceModel.ClientBase`1.InitializeChannelFactoryRef() at System.ServiceModel.ClientBase`1..ctor() at SC_51f3bcd084854b96b8cd4e20323a03d1.csproj.DataService.VanquisDataServiceClient..ctor() at ScriptMain.Input0_ProcessInputRow(Input0Buffer Row) at UserComponent.Input0_ProcessInput(Input0Buffer Buffer) at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.ProcessInput(Int32 inputID, PipelineBuffer buffer)
November 11th, 2010 9:56am

Check your web.config (of the web service). It must have an incorrect entry in it.Arthur My Blog
Free Windows Admin Tool Kit Click here and download it now
November 11th, 2010 10:04am

The service works fine when called outside of SSIS, so I doubt its web.config has any issues? If so can you elaborate? We have this working from SSIS using a .net 2 web reference, but get this error when using a .net 3.5 service reference in the script component.
November 11th, 2010 11:39am

Hi parody1, Based on the error "Could not find default endpoint element that references contract 'DataService.VanquisDataService' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element." and the callstack, the issue is caused by the service binding is invalid. To solve the issue, please follow these steps: Open the script in code designer mode. In the Project Explorer, please open the app.config. Check the binding settings. Below is a sample for your reference: <?xml version="1.0" encoding="utf-8" ?> <configuration> <system.serviceModel> <bindings> <wsHttpBinding> <binding name="WSHttpBinding_IService1" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="524288" maxReceivedMessageSize="65536" messageEncoding="Text" textEncoding="utf-8" useDefaultWebProxy="true" allowCookies="false"> <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384" maxBytesPerRead="4096" maxNameTableCharCount="16384" /> <reliableSession ordered="true" inactivityTimeout="00:10:00" enabled="false" /> <security mode="Message"> <transport clientCredentialType="Windows" proxyCredentialType="None" realm=""> <extendedProtectionPolicy policyEnforcement="Never" /> </transport> <message clientCredentialType="Windows" negotiateServiceCredential="true" algorithmSuite="Default" establishSecurityContext="true" /> </security> </binding> </wsHttpBinding> </bindings> <client> <endpoint address="http://server:10000/Service1.svc" binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_IService1" contract="ServiceReference2.IService1" name="WSHttpBinding_IService1"> <identity> <dns value="localhost" /> </identity> </endpoint> </client> </system.serviceModel> </configuration> Additionally, please test the service in Visual Studio, make sure the service works fine. For more information about invoking WCF service in Script Component, please see: http://blogs.msdn.com/b/dbrowne/archive/2010/07/08/how-to-configure-an-ssis-package-to-access-a-web-service-using-wcf.aspx If you have any more questions, please feel free to ask. Thanks, Jin ChenJin Chen - MSFT
Free Windows Admin Tool Kit Click here and download it now
November 12th, 2010 4:47am

Thanks Jin, The app.config looks correct, however the link you provided includes some code in the pre-execute which we do not have. I will take a look at this next week and get back.
November 12th, 2010 11:12am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics