Expose domain object metadata to breeze js and track changes - asp.net-web-api

I wanted to start using breeze js with an existing application. This application already has existing service that expose domain objects that are mapped from entity framework data object.
I wanted to expose these domain objects meta data to breeze so i could use it to track these entities on the client side and save changes. When these changes are saved from breeze I would then work out server side what needed to be done to persist these changes to my data objects.
I've looked at the EF context provider supplied in the breeze samples and was wondering what would be required to create a new context provider that would wrap my domain model ( not DBContext) exposing its metadata and also implement custom saving logic?
Has anyone done this already? Is there pipeline for breeze I've had a look on the user voice site and it looks like Extensible saveOptions and queryOptions are already under review but there is not much detail.

There is a ToDo-NoEF sample provided in the samples zip found here. It shows how to communicate with an arbitrary IQueryable on the server. Is this what you were looking for?

Related

Ember: What is the accepted paradigm for saving data to the back-end?

I am new to Ember and am used to the MVC model of creating controllers to move data between the view and the server. With Ember, it appears that controllers are support but there is very little documentation on them on the Ember website. From what I can tell, there is an alternative method to save data through the route. Is there an accepted paradigm for how to save data from the front-end to the back-end in Ember?
The Ember guides show you how to use different alternatives.
One easy way is to use Ember data to handle the rest interface with the backend.
Regarding architecture design, you can use the routes or the controllers to interact with you backend using the store.
In our projects we retrieve data in the route, and store it from the controllers.

Syncing with an External API in Volt Ruby Framework

I'm looking into Volt as an option for building an Admin interface to our REST API. The API is a separate application. I would like the Admin application to persist data to the API but also store it's own data that is irrelevant to the API (such as admin users and notes on the API data objects) locally.
Is there a way to sync each local change in the Admin with our remote API, like a callback, for example? Or do I need to wait until the Data Provider API is ready as mentioned in the most recent Volt blog post (as of writing)?
So this is a fairly common thing, so I think long term the solution will be to support multiple stores in an app and have a REST data provider that you can extend. However that might be a while before that's ready. In the mean time, you can always load and save data via tasks. (I realize its not ideal, but it will work right now) Let me know if you need more info on using tasks to load and save. I'll add the REST data provider to the TODO list.

Spring MVC - How to manage Reference Data on Web Clients

I have a Typical SOA web application which has the following components as expected.
The Web Client - Sprinv MVC
SOAP Services - Spring
The Reference Data is centralized which is exposed thru its own SOAP Services.
The SOAP webservice responses have codes for elements(like CountryCode, CityCode etc).
I need the suggestions as to what should be the best approach to for ex display the Country Description instead of the country code (which needs another SOAP call to reference data and same with other codes) on the web page ?
Few options are like:
Write a custom tag library which would do the necessary calls and get the data.
Fetch all the ReferenceData descriptions and put it into some kind of HashMap, add it to the model to be consumed by the web page.
Any other better ways please advice.
Since it's reference data, no one expect it to change very often, right? Retrieve them once and serve them up using #ModelAttribute. See here.
Spring MVC is still server side, so it can handle very large data e.g. all the street addresses in US. You simply need to make sure you add some sort of filter if you don't want to serve the entire collection. And simply partial update these reference data with the latest on regular basis.

Exposing navigation properties for related entities in a Web API

What is the recommended way to get to the related entities of parent entity using ASPNET WebAPI? If I have an an Album entity which has a collection of Song entities,does it make sense to
return the related Songs when fetching a specific Album OR does it make sense to have a set of navigation relationships exposed so that the client can fetch those as needed(such as in OData).
If so are there any samples that illustrate this.
I'm just looking for the best guidance here for building a Web API for a domain model.

Eager loading child properties using LINQ to CRM

Is there anyway I can eager load client defined child properties on a CRM entity using the LINQ to CRM Provider supplied in SDK 4.0.12? I'm looking for something the same as the pattern in Entity Framework as shown here. I'd love to be able to do this so we can align our repository interfaces with those we already have against EF.
As an aside, I know I can do it client side via a WCF Data Service exposing my DataContext and then use the .Expand() extension method. Therefore, it doesn't seem like such a stretch to allow me to perform the same at the server.

Resources