I recently upgraded from 6.0.4 to 6.0.5 and have had some difficulties in making the silverlight application connect to the EntityService/EntityServer.
Here's the error I'm getting
Message: IdeaBlade.EntityModel.EntityServerConnectionException: There is no endpoint listening on http://localhost/eCustody/EntityService.svc/sl that could accept calls from this application. If running in Visual Studio, make sure CopyLocal=true is set for all IdeaBlade assembly references in the web project to ensure that these assemblies are copied to the bin folder. To check if the service is running, open your internet browser and navigate to 'http://localhost/eCustody/EntityService.svc'. If the service page shows errors, these should help diagnose the problem with the service. If the service is running, then also make sure that the endpoint bindings match between client and server, and that the server's ClientApplicationType is either 'Silverlight' or 'Both'. Check the server's debug log file for more information. ---> System.ServiceModel.FaultException: Unable to start EntityServer.svc service: The service '/eCustody/EntityServer.svc' cannot be activated due to an exception during compilation. The exception message is: Type 'TradePMR.eCustody.Data.Models.Core.CoreEntities' cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute. If the type is a collection, consider marking it with the CollectionDataContractAttribute. See the Microsoft .NET Framework documentation for other supported types.. at System.ServiceModel.Channels.Remoting.RealProxy.Invoke(Object[] args) at proxy_2.EndGetEntityServerName(IAsyncResult ) at IdeaBlade.EntityModel.RemoteEntityServiceProxy.GetEntityServerName(String dataSourceExtension, String compositionContextName) at IdeaBlade.EntityModel.RemoteEntityServerProxyBase.Connect(ConnectAction action) --- End of inner exception stack trace ---
Following the exceptions advice, I've gone to http://localhost/eCustody/EntityService.svc and get the service page, so there are no errors. I've attached the debug log below. It looks like everything is started up correctly.
uploads/780/DebugLog.zip - uploads/780/DebugLog.zip
For the record I've opted to use all the DevForce defaults with the virtual path provider, so there are no endpoints defined in my web.config, nor do I have a ServiceReferences.ClientConfig file in my silverlight project. This has all worked for me in the past so I don't know what happened.
Just in case I'm doing something stupid (again) here's my web.config file:
<?xml version="1.0"?> <configuration> <configSections> <section name="ideablade.configuration" type="IdeaBlade.Core.Configuration.IdeaBladeSection, IdeaBlade.Core"/> </configSections>
<connectionStrings> <add name="CoreEntities" connectionString="metadata=res://*/Core.csdl|res://*/Core.ssdl|res://*/Core.msl;provider=System.Data.SqlClient;provider connection string="Data Source=SQL02;Initial Catalog=Core;Persist Security Info=True;User ID=sa;Password=********;MultipleActiveResultSets=True"" providerName="System.Data.EntityClient"/> </connectionStrings>
<system.web> <compilation debug="true" targetFramework="4.0" /> <authentication mode="Forms"/> </system.web>
<system.webServer> <modules> <add name="RequestDBModule" type="TradePMR.eCustody.Web.RequestDBModule"/> </modules> <handlers> <add name="Calendar" verb="*" path="eCustody.ics" type="TradePMR.eCustody.Web.Handlers.Calendar, eCustody.Web"/> </handlers> </system.webServer> <system.serviceModel> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" /> </system.serviceModel> </configuration>
|