original working draft of bancha project

Post on 22-Jun-2015

705 Views

Category:

Technology

0 Downloads

Preview:

Click to see full reader

DESCRIPTION

This is the original working draft, presented at the JavaScript User Group in Vienna. We are happy that this project could be realized and now can be found at banchaproject.org

TRANSCRIPT

ExtCakeRapid Developmentfor ExtJS and CakePHP

WorkingDraft

The Goal Enable asynchronous RPCs Enable synchronized Models Make webdevelopment easier

The Strategies TRY - Don‘t repeat yourself Save bandwidth

Send only relevant data Batch requests

Handle consistancy in distributed systems

How does it work?

CV

M

General RIA Architecture

Model

Controller

View

Model

Controller

View

Dat

a

Model

General RIA Architecture

Model

Controller

View

Controller

View

Dat

a

Our Architecture

Model

Controller

View

Model

Controller

View

Schema, Type

D

ata

Templates

Model

Controller

View

Model

Controller

View

DirectController

ExtDirect

Validation & Relations

D

ata

Templates

Model

Controller

View

RemoteableBehaviour

Model

Controller

View

DirectController

ExtDirectValidation &

Relations

D

ata

Templates

Model

Controller

View

RemoteableBehaviour

Direct Component

Model

Controller

View

DirectController

ExtDirectValidation &

Relations

D

ata

Templates

Model

Controller

View

RemoteableBehaviour

Direct Component

TemplateHelper

Model

Controller

View

DirectController

ExtDirectValidation &

Relations

D

ata

Templates

The Consistent ModelUsed for crutial data like orders.Solves typical problems of distributed systems

The Consistent Model Race Conditions Lost Requests

Consistancy

Client

Create Record 1

Edit Record 1

ServerWaiting..

.

Edit Record 1

Create Record 1

slow req.

Fast request

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1Version 2

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1Version 2

Write to Queue

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1Version 2

Write to Queue

delayed

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1Version 2

Create, then edit (Queue)

Write to Queue

delayed

Consistancy

Client

Create Record 1

Edit Record 1

Commit

ServerWaiting..

.

Edit Record 1

Create Record 1

Version 1Version 2

Create, then edit (Queue)

Write to Queue

delayed

Commit V. 1 & 2

The Consistent Model Race Conditions Lost Requests

Lost Requests - Resend

Client

Create Record 1

Create Record 1

ServerWaiting..

.

Create Record 1

lost

sent CreateRecord

Timed out, resend

Lost Requests – Slow Response

Client

Create Record 1

Create Record 1

ServerWaiting..

.

Create Record 1

Create Record 1

send

sendCreatesecond Record

Create Record

Timed out, before receivedso resend

Lost Requests – Slow Response

Client

Create Record 1

Create Record 1

ServerWaiting..

.

Create Record 1

Create Record 1

Send

sendAlreadycreated

Create Record,Save UUID

Add temp.UUID

Lost Requests – Slow Response

Client

Delete Record 1

Delete Record 1

ServerWaiting..

.

Delete Record 1

Delete Record 1

Send

sendJust ignore

Delete Record

The Consistent ModelRace Conditions

Lost Requests

The Client API ExtCake.registerModel(modelName,option

s) ExtCake.loadModel(modelName,options)

clientName: the clientside model name forceConsistancy: use the consistant model

ExtCake.loadTemplate(tplName)

The Server Classes RemotableBehaviour DirectController

Router Data-Schema

DirectComponent handles RPCs

TemplateHelper provides templates to

cake and ext views

So we gotFast and reliable RPCs

Synchronized models

Shared templates

We will also haveSupport for Sencha TouchPHPUnit-, Jasmin- & Selenium-TestsPolling Model

Polls the server for changesRapid Development

Command Line Tool

What else?Lazy Loading

Runtime dependency managementPersistent Data (?)

Cache Data & changes offlineNext time online update local and

remote dataEven more?

More Infos

@extcake

www.extcake.org

Thx for these used icons: Under construction by iconfactory.comCheck symbol by dezinerfolio.comDelete icon by everaldo.comWarning icon by vistaico.comTwitter icon by addictedtocoffee.deWebsite icon by bogo-d.deviantart.com

top related