Hi everyone and thanks for inviting me to the team!
I’m Uri and I wrote the angular-meteor library - http://angularjs.meteor.com/
I hope I can contribute to the conversation after the work we've done with syncing Angular 1.x with Meteor’s reactive cursors and the DDP protocol.
In angular-meteor 1.x we are prototyping an array so that we can $watch it from the client side (and mimic an Observe API from the client) and Observe the same data from the server side to keep a full data binding.
We are also giving a option of running Angular on the server to create services and call them from the client.
Now I guess we have much less work as we can work directly with the Javascript array and there is no more 2 way data bindings...
Few general points I will probably discuss more within the threads:
API for calling change detection - Object or Array should have a standard API to notify change detection about what's changed. there is the suggested solution of requestCheck() notify the whole object/array has changed or we can use something more precise like - AddedAt, ChangedAt, MovedAt, RemovedAt. it gives better understanding of what has changed and can help performance a lot (also in case one day change detection will be different). It is very similar to the API Lovefield Observe Query and to Meteor’s cursor.observe are exposing.
Communication - I think Angular 2.0 support for HTTP and WebSockets should be a second priority to the first point I've mentioned. As the main goal of Angular 2.0 is to support large consumer facing apps, in most of those applications there are other solutions that take care of syncing the client’s data with the server over the communication layer. it is a big shift of thinking about your app’s architecture but I think it is an important shift that needs to happen in Angular 2.0
Persistence - people will probably hate me for saying that, but I don’t think persistence suppose to be Angular’s job. persistence and local storage suppose to be UI framework agnostic. There are many types of solutions and architectures, some just take care of persistence and some adds latency compensation and conflict resolution between the server and the client. Angular shouldn’t impose a solution. Also, solving that problem to the full extent is not an easy task as people tend to think.
Standard for WebSockets - If Angular does going to create a real time communication service, I wonder what this standard will look like. Reading Rob’s post on Sails’ blueprints is super interesting, it looks like their own implementation that goes in the same direction as the DDP protocol. if Angular 2.0 will support WebSockets, it needs to have a standard across technologies, like HTTP and REST. The only standard I know of is the DDP protocol. there are clients in Javascript, iOS, Java, .NET, Rails etc.. and it looks like the industry is starting to adopt. If we are educating our users, standardizing WebSockets can be a great place.
Thanks and can't wait for more discussions,
Uri
I'm very interested in the web sockets discussion as well. But I don't think Angular, being a frontend framework should standardize on a single protocol. That assumes too much about the backend. For example, at Netflix, I'm much more likely to need something like the proposed Reactive Streams IO protocol.
Pub/sub is tricky and necessary, but there are ways around fixing it to a given protocol at the client.
--
You received this message because you are subscribed to the Google Groups "angular-data-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular-data-d...@googlegroups.com.
To post to this group, send email to angular-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/angular-data-dev/df4d44b0-0684-4552-bb84-77d7990db6e8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To view this discussion on the web visit https://groups.google.com/d/msgid/angular-data-dev/CADcN1GC7Zb37Kj9Wnui2-81oma%2B%2BV_4tZ0%2BreTk6LcdDrx%3D%3DTw%40mail.gmail.com.
Hi everyone and thanks for inviting me to the team!
I’m Uri and I wrote the angular-meteor library - http://angularjs.meteor.com/
I hope I can contribute to the conversation after the work we've done with syncing Angular 1.x with Meteor’s reactive cursors and the DDP protocol.
In angular-meteor 1.x we are prototyping an array so that we can $watch it from the client side (and mimic an Observe API from the client) and Observe the same data from the server side to keep a full data binding.
We are also giving a option of running Angular on the server to create services and call them from the client.
Now I guess we have much less work as we can work directly with the Javascript array and there is no more 2 way data bindings...
Few general points I will probably discuss more within the threads:
API for calling change detection - Object or Array should have a standard API to notify change detection about what's changed. there is the suggested solution of requestCheck() notify the whole object/array has changed or we can use something more precise like - AddedAt, ChangedAt, MovedAt, RemovedAt. it gives better understanding of what has changed and can help performance a lot (also in case one day change detection will be different). It is very similar to the API Lovefield Observe Query and to Meteor’s cursor.observe are exposing.
Communication - I think Angular 2.0 support for HTTP and WebSockets should be a second priority to the first point I've mentioned. As the main goal of Angular 2.0 is to support large consumer facing apps, in most of those applications there are other solutions that take care of syncing the client’s data with the server over the communication layer. it is a big shift of thinking about your app’s architecture but I think it is an important shift that needs to happen in Angular 2.0
Persistence - people will probably hate me for saying that, but I don’t think persistence suppose to be Angular’s job. persistence and local storage suppose to be UI framework agnostic. There are many types of solutions and architectures, some just take care of persistence and some adds latency compensation and conflict resolution between the server and the client. Angular shouldn’t impose a solution. Also, solving that problem to the full extent is not an easy task as people tend to think.
Standard for WebSockets - If Angular does going to create a real time communication service, I wonder what this standard will look like. Reading Rob’s post on Sails’ blueprints is super interesting, it looks like their own implementation that goes in the same direction as the DDP protocol. if Angular 2.0 will support WebSockets, it needs to have a standard across technologies, like HTTP and REST. The only standard I know of is the DDP protocol. there are clients in Javascript, iOS, Java, .NET, Rails etc.. and it looks like the industry is starting to adopt. If we are educating our users, standardizing WebSockets can be a great place.