wcf-ria-services

partial entity loading and management in silverlight / wcf ria

独自空忆成欢 提交于 2019-12-12 10:54:01
问题 I have a Silverlight 4 app which pulls entities down from a database using WCF RIA services. These data objects are fairly simple, just a few fields but one of those fields contains binary data of an arbitrarily size. The application needs access to this data basically asap after a user has logged in, to display in a list, enable selection etc. My problem is because of the size of this data, the load times are not acceptable and can approach the default timeout of the RIA service. I'd like to

WCF RIA Service deployment issue

蓝咒 提交于 2019-12-12 10:35:40
问题 I have a very simple sample silverlight application. I added a domain service to it with an entity model that has one entity. The client app simply loads all rows in the entity at startup. When I run this on my development box, it works as expected. However, when I move it to our test server I get an exception saying that the method I am calling cannot be found (Load operation failed for query 'GetCTCStation'. The remote server returned an error. NotFound.). When I inspected the client/server

WCF RIA services domain service metadata

喜夏-厌秋 提交于 2019-12-12 05:35:39
问题 I am using RIA services in a silverlight application with a RIA domain service that does data transfer. I have made changes to the domain service and metadata in terms of updating methods, adding methods, putting data validation attributes on the metadata fields, etc. When I am in the position where I need to re-generate the domain service due to adding a new table, obviously the generation algorithm doesn't preserve my metadata attributes or additional domain service methods. Is there any

Querying WCF Services with OData Params in POST instead of GET

假如想象 提交于 2019-12-12 03:32:06
问题 We call wcf svcs (not ours) and we're using gets for searching a product database. Example: http://foo.com/SearchProducts.svc?$skip=0$take=10$includeTotalCount=true We were passing the Odata parameters to page the results of the SearchProducts svc. The svc has been changed to a POST because one of our filters "skus" is sometimes huge (hundres of skus) which causes the GET to break because the uri is too large. The easiest solution we thought was to just change the call to a post but now the

How to insert entity over WCF-RIA-Services JSON endpoint

浪尽此生 提交于 2019-12-12 03:22:43
问题 My WCF-RIA DomainService has an insert method that looks like this: public void InsertWidget(WidgetDef widgetDef) class WidgetDef { [Key] int widgetID; string title; int x; int x; // there are more properties, but I think you get the idea... } To access this through the JSON endpoint, I think I need to POST a changeset to the url: [serverURL][namespace]WidgetService.svc/json/SubmitChanges. I'm pretty sure I got the URL correct, because my request reaches the WidgetService.Initialize method,

Join two tables and filter result using EF 4 and RIA services

不羁的心 提交于 2019-12-12 03:18:06
问题 Public Function LoadSiteInfo(ByVal sId As Integer) As IQueryable(Of Site) Return Me.ObjectContext.Sites.Include("SiteData").Where((Function(f) f.SiteID = sId) AndAlso Function(x) x.SiteData.SiteUpdateDate < today)) End Function So, I'm trying to filter on SiteId from the Sites table, ANDALSO on the SiteUpdateDate in the SiteData table, it's the last part where I cannot get the syntax correct - it's just saying that SiteUpdateDate attribute is not a member of ObjectContext.Site, which is

How to store entities context query object into generic list?

为君一笑 提交于 2019-12-12 03:03:51
问题 In my last question, i successfully to dump the data into combo box with solution from Leo but now, i want to get everything of specific user and store into generic list. i tried with this code but it's not working. May i know is there something wrong with my code ? var contexti = new OrganizationContext(); //contexti.Load(contexti.GetAdminPassQuery(userName), LoadInfo, null); EntityQuery query = contexti.GetAdminPassQuery(userName); contexti.Load<tblAdmin>(query).Completed += (sender, args)

Endpoint not found

余生颓废 提交于 2019-12-12 02:42:05
问题 I have created a new WCF RIA service with OData exposed. I wanted to test it out. My project name was ChinookSample and the namespace was ChinookSample.Web.Services When I try to browse... http://localhost:52878/Services/ChinookSample-Web-services-dsAlbumAndArtist.svc I get the service page, but the moment I go for... http://localhost:52878/Services/ChinookSample-Web-services-dsAlbumAndArtist.svc/OData I get EndPoint not found . I have checked my Web.Config and that has the OData defined.

Silverlight & RIA & POCO: SubmitOperationFailed when INSERTING two new child entities. An entity with the same ID exists

末鹿安然 提交于 2019-12-12 01:34:35
问题 Here's my scenario: I am using Silverlight, RIA and POCO objects (no Entity Framework; we're working against Oracle and SP's). I have a Parent object that contains a collection of Child objects. I have setup the Association and Composition attributes on the Parent correctly. When I want to save changes, the entire object graph gets sent to the server correctly. The user can add one or more Child objects to the Parent. Now, if the user adds ONE Child object to the Parent and saves it then

Custom “Basic” Authentication for my WCF services. REST and RIA. Possible?

时光怂恿深爱的人放手 提交于 2019-12-12 01:26:28
问题 My server side contains WCF4 REST services and I'm going to add RIA services for my future SL4 application. Currently I'm doing Basic authentication like this: var auth = HttpContext.Current.Request.Headers.GetValues("Authorization"); And so on.. You get the idea.. I call this on every request. If header not present or I can't validate UN/Password - I do this: outgoingResponse.Headers.Add("WWW-Authenticate: Basic realm=\"Secure Area\""); That got me by so far but I'm refactoring my server