0

Silverlight 모듈의 힙은 Entity Framework 4로 빌드 된 Silverlight 응용 프로그램을 가지고 있습니다. 이는 내 DomainService, Model 및 Web.Config가 포함 된 웹 프로젝트입니다.SQL 데이터베이스에서 많은 행을로드 할 때 Silverlight 오류가 발생합니다.

로컬 SQL Server에서 데이터를 가져 와서 잘 작동합니다. 내 SL 모듈 중 하나가 특정 테이블에서 데이터를 가져옵니다.이 테이블에 4000 개 이상의 행이 있으면 응용 프로그램이 다운되고 다음 오류 메시지가 나타납니다. 그것이 약 1000의 roes를 가지고있을 때 그것은 잘 작동합니다. 그래서 DomainService can not가 모든 행을 처리하지 못하거나 어쩌면 webconfig의 바인딩 설정이 어떤 식 으로든 잘못되었다고 생각합니다. 무엇을 할 수 있습니까?

ERR 메시지 :

{System.ServiceModel.DomainServices.Client.DomainOperationException :로드 작업이 쿼리 'LoadSiteCageData'실패했습니다. 원격 서버가 NotFound 오류를 반환했습니다. ---> System.ServiceModel.CommunicationException : 원격 서버 오류를 반환했습니다 : NotFound. ---> System.Net.WebException : 원격 서버 오류를 반환했습니다 : NotFound. ---> System.Net.WebException : 원격 서버 오류를 반환했습니다 : NotFound. at System.Net.Browser.BrowserHttpWebRequest.InternalEndGetResponse (IAsyncResult asyncResult) at System.Net.Browser.BrowserHttpWebRequest. <> c_ DisplayClass5.b _4 (Object sendState) at System.Net.Browser.AsyncHelper. <> C_ DisplayClass4.b _0 (sendState 개체) 내부 예외 스택 추적 --- --- 끝에서 System.Net.Browser.AsyncHelper.BeginOnUI (SendOrPostCallback beginMethod, 객체 상태)에서 System.Net . System.ServiceModel.DomainServices.Client에서 System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse (IAsyncResult를 결과) --- 내부 예외 스택 추적의 끝 --- 에서 Browser.BrowserHttpWebRequest.EndGetResponse (IAsyncResult를 asyncResult) .WebDomainClient`1.EndQueryCore (IAsyncResult asyncResult) (System.ServiceModel.DomainServices.Client.DomainClient.EndQuery (IAsyncResult asyncResult)) at System.ServiceModel.Doma 내부 예외 스택 추적 끝 - at System.ServiceModel.DomainServices.Client.OperationBase.Complete (예외 오류) at System.ServiceModel.DomainServices.Client .LoadOperation.Complete (예외 오류) at System.ServiceModel.DomainServices.Client.DomainContext.CompleteLoad (IAsyncResult asyncResult) at System.ServiceModel.DomainServices.Client.DomainContext. <> C_ DisplayClass1b.b _17 (Object)를

의 Web.config

<?xml version="1.0" encoding="utf-8"?> 
<configuration> 
<configSections> 
    <sectionGroup name="system.serviceModel"> 
     <section name="domainServices" type="System.ServiceModel.DomainServices.Hosting.DomainServicesSection, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" allowDefinition="MachineToApplication" requirePermission="false" /> 
    </sectionGroup> 
</configSections> 
<appSettings /> 
    <system.web> 

    <httpModules> 
       <add name="DomainServiceModule" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /> 
    </httpModules> 
    <compilation debug="true" strict="false" explicit="true" targetFramework="4.0"> 
     <assemblies> 
      <add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> 
     </assemblies> 
    </compilation> 
    <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID"> 

    </pages> 

    <authentication mode="Windows" /> 

</system.web> 
<system.codedom></system.codedom> 

<system.webServer> 
    <modules> 
       <add name="DomainServiceModule" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /> 
    </modules> 
    <validation validateIntegratedModeConfiguration="false" /> 
</system.webServer> 
<system.serviceModel> 
    <behaviors> 
     <serviceBehaviors> 
      <behavior name=""> 
       <serviceMetadata httpGetEnabled="true" /> 
       <serviceDebug includeExceptionDetailInFaults="false" /> 
      </behavior> 
     </serviceBehaviors> 
    </behaviors> 
    <bindings> 
     <customBinding> 
      <binding name="MyService.Web.Service1.customBinding0"> 
       <binaryMessageEncoding /> 
       <httpTransport /> 
      </binding> 
     </customBinding> 
    </bindings> 
    <services> 
     <service name="MyService.Web.Service1"> 
      <endpoint address="" binding="customBinding" bindingConfiguration="MyService.Web.Service1.customBinding0" contract="MyService.Web.Service1" /> 
      <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" /> 
     </service> 
    </services> 
    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" /> 
</system.serviceModel> 

+1

config, 특히 끝점 사양을 게시 할 수 있습니까? 기본적으로 메시지에는 크기 제한이 있습니다 (64kb?). 그걸 늘려야 해. –

+0

처음 게시물에 webconfig를 추가했습니다. 도와주세요. – Mcad001

답변

1

나는이 같은 와이어를 통해 올 수있는 데이터의 크기의 한계로 인해 생각 basichttpbinding에 관한 한 오래. 그것은 64k입니다.

이 문제를 해결하는 데는 두 가지 옵션이 있습니다.

  • 일부 쉼표로 구분 된 파일로 데이터를 다운로드 페이지에서 데이터 페이지를 당겨

내가 일반적으로 할 것은 zip 파일로 데이터를 다운로드하는 것입니다가, 클라이언트 측에서 압축 해제 구문 분석 및 디스플레이 그런 다음 대량의 데이터를 처리 할 수 ​​있습니다.

+0

당기고있는 모든 데이터가 그래프로 표시되기 때문에 페이징으로이 작업을 수행 할 수 없습니다. 그래서 Zip은 대안이 아닙니다. – Mcad001

+0

여전히 데이터를 페이지 할 수 있습니다. 이렇게하려면 한 번에 50 개 정도의 레코드를 검색해야합니다. 모든 레코드가 다운로드되면 그래프에 그릴 수 있습니다. – cadrell0

+0

나는이 개념들을 상당히 새롭게 익혔습니다. 그래서 지금 어떻게해야하는지 명확하게 알지 못합니다. 그래서, 근본적으로 저는이 버퍼에 qucik 픽스를 찾고 있습니다 - 만약 버퍼의 종류가 조금이라도 증가 할 수 있다면 말입니다. – Mcad001

관련 문제