2011-09-07 3 views
1

MVC 응용 프로그램에서 WCF 메서드를 호출하려고합니다. WCF 메서드를 호출하는 동안 "원격 서버에서 예기치 않은 응답을 반환했습니다 : (400) Bad Request"오류가 발생합니다.받기 원격 서버가 예기치 않은 응답을 반환했습니다. (400) WCF를 호출하는 중에 잘못된 요청 예외가 발생했습니다.

항목 목록을 전달 중입니다. 내가 50 만 지나면, 들어간다. 그러나 그 이상이라면, 그것은 오류 메시지를 보여준다.

이 문제에 대한 도움을 주시면 감사하겠습니다.

내 클라이언트 설정 :

<basicHttpBinding> 
    <binding name="BasicHttpBinding_IPaymentRequestService" 
     closeTimeout="00:10:00" openTimeout="00:10:00" receiveTimeout="00:10:00" 
     sendTimeout="00:10:00" 
     allowCookies="false" bypassProxyOnLocal="false" 
     hostNameComparisonMode="StrongWildcard" 
     maxBufferSize="2147483647" maxBufferPoolSize="2147483647" 
     maxReceivedMessageSize="2147483647" 
     messageEncoding="Text" textEncoding="utf-8" transferMode="StreamedRequest" 
     useDefaultWebProxy="true"> 
     <readerQuotas 
      maxDepth="2147483647" maxStringContentLength="2147483647" 
      maxArrayLength="2147483647" maxBytesPerRead="2147483647" 
      maxNameTableCharCount="2147483647" /> 
     <security mode="None"> 
     <transport clientCredentialType="None" proxyCredentialType="None" realm="" /> 
     <message clientCredentialType="UserName" algorithmSuite="Default" /> 
     </security> 
    </binding> 
    </basicHttpBinding> 

서버 구성 :

<services> 
    <service name="BasicHttpBinding_IPaymentRequestService" > 
    <endpoint name="BasicEndpoint" 
     address="http://localhost/Intel.IIP.WCF.Hosting/PaymentRequestServiceHost.svc" 
     binding="basicHttpBinding" bindingConfiguration="ServiceBinding" 
     contract="IPaymentRequestService"> 
    </endpoint> 
    </service> 
</services> 
<bindings> 
    <basicHttpBinding > 
    <binding name="ServiceBinding" 
     transferMode="StreamedRequest" allowCookies="false" useDefaultWebProxy="true" 
     messageEncoding="Text" hostNameComparisonMode="StrongWildcard" 
     bypassProxyOnLocal="false" maxBufferPoolSize="2147483647" textEncoding="utf-8" 
     closeTimeout="00:10:00" openTimeout="00:10:00" receiveTimeout="00:10:00" 
     sendTimeout="00:10:00" maxBufferSize="2147483647" 
     maxReceivedMessageSize="2147483647"> 
     <readerQuotas 
       maxStringContentLength="2147483647" maxArrayLength="2147483647" 
       maxDepth="2147483647" maxBytesPerRead="2147483647" 
       maxNameTableCharCount="2147483647"/> 
     <security mode="None" ></security> 
    </binding> 
    </basicHttpBinding> 
</bindings> 

감사 아말은

+1

아말, 우리가 놓치고있는 생각 클라이언트 구성. .. 업데이트 할 수 있습니까? 또한 더 자세한 정보를 얻을 수 있는지 확인하려면 Service Trace Viewer (http://msdn.microsoft.com/en-us/library/ms732023.aspx 참조)와 같은 내용을 확인하십시오. –

+0

나머지 클라이언트 구성을 표시 할 수 있습니까 ?? 현재 거기에는 바인딩 만 있습니다. 클라이언트 측 구성에는''섹션이 있습니까? –

답변

1

당신은 시도해 봤어 :

<system.web> 
    <httpRuntime maxRequestLength="2097151" /> 
</system.web> 
관련 문제