Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introducing Liferay Standalone Applications
Search
Eduardo Lundgren
November 06, 2014
3
520
Introducing Liferay Standalone Applications
Eduardo Lundgren
November 06, 2014
Tweet
Share
More Decks by Eduardo Lundgren
See All by Eduardo Lundgren
WeDeploy
eduardolundgren
0
49
Single Page Applications in Liferay
eduardolundgren
5
2.5k
Single Page Applications done right
eduardolundgren
10
770
tracking.js with Maira Bello
eduardolundgren
0
120
Single Page Application
eduardolundgren
0
410
Getting Started with YUI3 and AlloyUI
eduardolundgren
0
79
Getting started with AlloyUI
eduardolundgren
0
82
Augmented Reality.js
eduardolundgren
0
160
Liferay UI revolution
eduardolundgren
0
190
Featured
See All Featured
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.2k
The Art of Programming - Codeland 2020
erikaheidi
56
14k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.1k
KATA
mclloyd
PRO
32
15k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.7k
Practical Orchestrator
shlominoach
190
11k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
A better future with KSS
kneath
239
18k
It's Worth the Effort
3n
187
28k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
116
20k
A Tale of Four Properties
chriscoyier
161
23k
How STYLIGHT went responsive
nonsquared
100
5.9k
Transcript
Standalone Applications in Liferay @eduardolundgren
“Liferay isn't sexy...”
None
One of the most efficient animal in the kingdom
None
None
They have 360-degree view
360-degree view
They are immortal
None
None
The most deadly creature on earth
None
None
None
None
None
What is the secret behind the jellyfish ? ? ?
? ? ? ? ? ? ? ? ?
None
“Teams with a better distribution of skills, not segmented by
roles, produce better results” Jared Spool User Interface Engineering
None
@rotty3000 (he also loves cars)
Standalone app is our Jellyfish
2013
None
None
None
None
None
None
!
None
Datastore
Datastore " Liferay A B Schemaless NoSQL Robust Scalable
A B " Datastore Liferay
Datastore ( your code goes here ) A B Deploy
Liferay
Datastore ( your code goes here ) A B Deploy
Liferay
Datastore API Clients A B Cross domain requests Promises Error
handling Batch Real time Liferay HTTP JavaScript Java ObjectiveC
Datastore RESTful Web Services API Clients A B Restful Liferay
HTTP JavaScript Java ObjectiveC
<script src="//apis.liferay.com/client.js" /> 8KB
lfr.request('http://api.example.com/v1/users') .then(function(response) { // success }) .catch(function(reason) { // failure
});
Your clients can talk directly to the back end services
without needing to go through your server side code
Autogenerated RESTful apis
The secret to machines talking to machines is to speak
human first
None
None
Users
Users https://api.example.com/v1/users Version Entity
Users /v1/users/ec557f-b045-0bad-5130-1347
Users /v1/users/559743231794
App id = 1, 2, 3... Normal DB
App id = 7 Sharded id = 46 id =
wat? DB DB DB
App id = 7 Sharded id = 46 id =
wat? DB 1) Random 2) Ordered 3) Unique 4) Distributed 5) Human Readable DB DB
64 bits IDs 0000000000000000000000000000000000000000000 0 00000000000000000000 |------------------------------------------| |---| |------------------| timestamp
sequence random bits safety bit bits Liferay's Simpleflake IDs /v1/users/559743231794
64 bits IDs 0000000000000000000000000000000000000000000 0 00000000000000000000 |------------------------------------------| |---| |------------------| timestamp
sequence random bits safety bit bits Chances of collision Liferay's Simpleflake IDs
Places for data: method and url, headers and body
POST https://api.example.com/v1/users PUT https://api.example.com/v1/users ! { "about": "Start simple. Dream
big. Do good. Be well.", "city": "Recife", "country": "BR" } ! HTTP 1.1/201 Created HTTP 1.1/202 Accepted (pending) Create
PUT https://api.example.com/v1/users/1 PATCH https://api.example.com/v1/users/1 ! { "about": "Updated", "city": "Recife",
"country": "BR" } ! HTTP 1.1/200 OK HTTP 1.1/202 Accepted (pending) Update
DELETE https://api.example.com/v1/users/1 ! HTTP 1.1/204 No content Delete
GET https://api.example.com/v1/users ! HTTP/1.1 200 OK Content-Type: application/json ! {
"users": [ { "about": "Start simple. Dream big. Do good. Be well.", "city": "Recife", "country": "BR" } ]} GET
GET https://api.example.com/v1/users.json ! HTTP/1.1 200 OK Content-Type: application/json ! {
"users": [ { "about": "Start simple. Dream big. Do good. Be well.", "city": "Recife", "country": "BR" } ]} GET JSON output
GET https://api.example.com/v1/users.xml ! HTTP/1.1 200 OK Content-Type: text/xml ! <?xml
version="1.0" encoding="UTF-8" ?> <users> <about>Start simple. Dream big. Do good. Be well.</aboutMe> <city>Recife</city> <country>BR</country> </users> GET XML output
POST https://api.example.com/v1/users/1/publish POST https://api.example.com/v1/users/1/star ! HTTP 1.1/200 OK HTTP 1.1/202
Accepted (pending) ! Custom verbs
Real-time
RESTful Web Services API Clients Restful HTTP JavaScript Java ObjectiveC
None
lfr.subscribe('http://api.example.com/v1/users') .on('data', function(response) { // data has arrived... });
Push notifications for all your services for free
Routing !
http://example.com/special/women
http://example.com/special/men
routes.txt
None
Automated tools
None
None
None
None
Management
Quota, Billing, Security policies, Reports, available at one click
Architecture
Database Service Builder Portlet Portlet Portlet JSON Web Services
RESTful Web Services Real-time Datastore MongoDB Elasticsearch RID Generator Auth
Permissions
Service Builder RESTful Web Services JSON Web Services Database Real-time
Datastore MongoDB Elasticsearch RID Generator Auth Permissions Portlet Portlet Portlet
None
Concrete Abstract "
" Concrete Abstract
Concrete Abstract "
None
" Concrete Abstract
DATASTORE RESTFUL REAL TIME ROUTING MANAGEMENT AUTHENTICATION TOOLS
We wanna be more than sexy.
Thank you! @eduardolundgren