SlideShare a Scribd company logo
1 of 28
Download to read offline
Firebase defines for
everyone
By Apaichon Punopas
• Realtime Database call by API
• Store as JSON format
• Sync data from multiple applications
• Only write front end code
• Secure and monitor your data
• Access from everywhere
What is Firebase ?
• Originally referring to "non SQL", "non relational" or "not
only SQL"
• Simplicity of design, simpler "horizontal" scaling to
clusters of machines
• key-value, wide column, graph, or document
• "more flexible" than relational database tables
• Most NoSQL stores lack true ACID transactions
• Most NoSQL use JSON format
What is NO SQL ?
• This model organizes data into one or more tables
(or "relations") of columns and rows, with a unique
key identifying each row. Rows are also called
records or tuples.
What is Relational DB ?
• Move fast
• Forget about infrastructure
• Make smart, data-driven decisions
• Work across platforms
• Free to start, scale with ease
Why use Firebase ?
Who use Firebase ?
• Single JSON format
Firebase structure
{"firstName":"John",
"lastName":"Doe" ,
"age":30 ,
"gender":"M" ,
“birthDay":"1/1/1986"
}
• Go to https://www.firebase.com/
• Click
• Click
• Fill Project Information
Register Firebase
Manual edit data
• Node.js is a server-side platform.
• Built on Google Chrome's JavaScript Engine (V8 Engine).
• It was developed by Ryan Dahl in 2009.
• It is an open source.
• Cross-platform runtime environment for developing
server-side and networking applications.
• Node.js uses an event-driven, non-blocking I/O model.
What is NodeJS ?
• The term I/O is used to describe any program,
operation or device that transfers data to or from a
computer and to or from a peripheral device.
What is I/O ?
• Most I/O requests are considered blocking
requests, meaning that control does not return to
the application until the I/O is complete. The
delayed from systems calls such read() and write()
can be quite long. Using systems call that block is
sometimes call synchronous programming.
What is Blocking I/O ?
• Programs that use non-blocking I/O tend to follow
the rule that every function has to return
immediately, i.e. all the functions in such programs
are nonblocking. Thus control passes very quickly
from one routine to the next.
What is non blocking I/O ?
1. Go to https://nodejs.org/en/download/
2. Choose NodeJS for your OS.
3. Extract file and Click on Installer package.
4. After finish installed then open terminal and type
command.
Installation NodeJS
>node -v
1. Create file name package.json
Integrate Firebase with
NodeJS #2
{
"name": "testfirebase",
"version": "1.0.0",
"description": "MyService is Rest Api Application for our core system.",
"scripts": {
"test": "echo "Error: no test specified" && exit 1"
},
"keywords": [
"Test Firebase"
],
"author": “Your Name",
"license": "MIT",
"dependencies": {
"body-parser": ">= 1.14.2",
"express": "^4.14.0",
"firebase": "^3.5.2",
"guid": "latest"
}
}
2. Install NodeJS Package
3. Create file name “app.js” and put code following.
Integrate Firebase with
NodeJS
>npm install
var express = require("express");
var app = express();
require('rootpath')();
var bodyParser = require('body-parser');
app.use(bodyParser.json());
app.listen(3000);
console.log("My Service is listening to port 3000.");
4. Go to Firebase console and copy code for web on
overview section then paste to app.js .
Integrate Firebase with
NodeJS
var firebase = require("firebase");
// Initialize the app with a service account, granting admin privileges
firebase.initializeApp({
apiKey: "AIzaSyBrzkaCzORJfYizrjeIij3rbl6d-EYswt0",
authDomain: "ibcrm-b1a74.firebaseapp.com",
databaseURL: "https://ibcrm-b1a74.firebaseio.com",
storageBucket: "ibcrm-b1a74.appspot.com",
messagingSenderId: "810901210082"
});
1.Put code in app.js following.
2. Open Terminal then run nodejs > node app.js
Create data
var Guid = require('guid');
app.post('/members/add',function(req,res){
var _guid = Guid.create();
var guid = _guid.toString();
firebase.database().ref('members/' + guid.toString())
.set(req.body,function(err){
var message ={code:200,status:"Insert completed"}
if(err)
message ={code:500,status:"error",message:err}
else
message.result = req.body;
res.send(message);
});
});
Objective
Install Chrome Postman for test Restful API.
1. Find in Google by wording is “Chrome Postman”
2. Click add chrome plugin
Install Postman
Objective
Test CRUD Rest API by Postman to make sure that all function
are work correctly .
1. Open “Chrome Postman” then set parameter following.
Setup Postman’s Parameters
1
2
3
4
2
1.Go to Firebase web console then set JSON
following.
Open Authorise
• Rerun app.js
• Back to Chrome Postman then click send button.
Test Rest API
>node app.js
We have created solution like below picture.
What we’ve done ?
23
1.Put code in app.js following.
2. Open Terminal then run nodejs > node app.js
3. On Chrome Postman click Send button.
Get data
app.get('/members/getMany',function(req,res){
firebase.database().ref('members').once('value')
.then(function(data){
res.send(data.val());
})
});
1.Put code in app.js following.
2. Open Terminal then run nodejs > node app.js
Edit data
app.put('/members/edit',function(req,res){
var memberId = req.body.memberId;
var memberInfo = req.body.memberInfo;
firebase.database().ref('members/' + memberId)
.update(memberInfo,function(err){
var message ={code:200,status:"Update completed"}
if(err)
message ={code:500,status:"error",message:err}
else
message.result = req.body;
res.send(message);
});
});
1.Put code in app.js following.
2. Open Terminal then run nodejs > node app.js
Delete data
app.delete('/members/delete',function(req,res){
var memberId = req.body.memberId;
firebase.database().ref('members/' + memberId)
.remove(function(err){
var message ={code:200,status:"Remove completed"}
if(err)
message ={code:500,status:"error",message:err}
else
message.result = req.body;
res.send(message);
});
});
Human are social animals
Give and Take:
Why Helping Others Drives Our
Success
END
Delete

More Related Content

What's hot

Firebase Introduction
Firebase Introduction Firebase Introduction
Firebase Introduction 9xdot
 
Google Firebase
Google FirebaseGoogle Firebase
Google FirebaseAliZaidi94
 
Firebase Auth Tutorial
Firebase Auth TutorialFirebase Auth Tutorial
Firebase Auth TutorialBukhori Aqid
 
Database, data storage, hosting with Firebase
Database, data storage, hosting with FirebaseDatabase, data storage, hosting with Firebase
Database, data storage, hosting with FirebaseTu Pham
 
Intoduction of FIrebase Realtime Database
Intoduction of FIrebase Realtime DatabaseIntoduction of FIrebase Realtime Database
Intoduction of FIrebase Realtime DatabaseSahil Maiyani
 
Redis + Apache Spark = Swiss Army Knife Meets Kitchen Sink
Redis + Apache Spark = Swiss Army Knife Meets Kitchen SinkRedis + Apache Spark = Swiss Army Knife Meets Kitchen Sink
Redis + Apache Spark = Swiss Army Knife Meets Kitchen SinkDatabricks
 
Logic Apps and Azure Functions
Logic Apps and Azure FunctionsLogic Apps and Azure Functions
Logic Apps and Azure FunctionsDaniel Toomey
 
Web analytics at scale with Druid at naver.com
Web analytics at scale with Druid at naver.comWeb analytics at scale with Druid at naver.com
Web analytics at scale with Druid at naver.comJungsu Heo
 
Firebase Analytics
Firebase AnalyticsFirebase Analytics
Firebase AnalyticsMariam Aslam
 
Introducing firebase
Introducing firebaseIntroducing firebase
Introducing firebaseFarouk Touzi
 
12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQLKonstantin Gredeskoul
 
Firebase in action 2021
Firebase in action 2021Firebase in action 2021
Firebase in action 2021NhanNguyen534
 

What's hot (20)

Firebase Overview
Firebase OverviewFirebase Overview
Firebase Overview
 
Firebase Introduction
Firebase Introduction Firebase Introduction
Firebase Introduction
 
Firebase
FirebaseFirebase
Firebase
 
Introduction to Firebase from Google
Introduction to Firebase from GoogleIntroduction to Firebase from Google
Introduction to Firebase from Google
 
Firebase PPT
Firebase PPTFirebase PPT
Firebase PPT
 
Google Firebase
Google FirebaseGoogle Firebase
Google Firebase
 
Firebase Auth Tutorial
Firebase Auth TutorialFirebase Auth Tutorial
Firebase Auth Tutorial
 
Firebase
FirebaseFirebase
Firebase
 
Firebase
Firebase Firebase
Firebase
 
Database, data storage, hosting with Firebase
Database, data storage, hosting with FirebaseDatabase, data storage, hosting with Firebase
Database, data storage, hosting with Firebase
 
Intoduction of FIrebase Realtime Database
Intoduction of FIrebase Realtime DatabaseIntoduction of FIrebase Realtime Database
Intoduction of FIrebase Realtime Database
 
Firebase.pptx
Firebase.pptxFirebase.pptx
Firebase.pptx
 
Redis + Apache Spark = Swiss Army Knife Meets Kitchen Sink
Redis + Apache Spark = Swiss Army Knife Meets Kitchen SinkRedis + Apache Spark = Swiss Army Knife Meets Kitchen Sink
Redis + Apache Spark = Swiss Army Knife Meets Kitchen Sink
 
Logic Apps and Azure Functions
Logic Apps and Azure FunctionsLogic Apps and Azure Functions
Logic Apps and Azure Functions
 
Web analytics at scale with Druid at naver.com
Web analytics at scale with Druid at naver.comWeb analytics at scale with Druid at naver.com
Web analytics at scale with Druid at naver.com
 
Firebase Analytics
Firebase AnalyticsFirebase Analytics
Firebase Analytics
 
Introducing firebase
Introducing firebaseIntroducing firebase
Introducing firebase
 
Firebase
FirebaseFirebase
Firebase
 
12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL12-Step Program for Scaling Web Applications on PostgreSQL
12-Step Program for Scaling Web Applications on PostgreSQL
 
Firebase in action 2021
Firebase in action 2021Firebase in action 2021
Firebase in action 2021
 

Viewers also liked

Firebase - A real-time server
Firebase - A real-time serverFirebase - A real-time server
Firebase - A real-time serverAneeq Anwar
 
Introduction to Firebase [Google I/O Extended Bangkok 2016]
Introduction to Firebase [Google I/O Extended Bangkok 2016]Introduction to Firebase [Google I/O Extended Bangkok 2016]
Introduction to Firebase [Google I/O Extended Bangkok 2016]Sittiphol Phanvilai
 
Quickie auth with firebase and polymer
Quickie auth with firebase and polymerQuickie auth with firebase and polymer
Quickie auth with firebase and polymerSylia Baraka
 
Node.js - A practical introduction (v2)
Node.js  - A practical introduction (v2)Node.js  - A practical introduction (v2)
Node.js - A practical introduction (v2)Felix Geisendörfer
 
Change RelationalDB to GraphDB with OrientDB
Change RelationalDB to GraphDB with OrientDBChange RelationalDB to GraphDB with OrientDB
Change RelationalDB to GraphDB with OrientDBApaichon Punopas
 
Building an alarm clock with node.js
Building an alarm clock with node.jsBuilding an alarm clock with node.js
Building an alarm clock with node.jsFelix Geisendörfer
 
Forensic Tools for In-Depth Performance Investigations
Forensic Tools for In-Depth Performance InvestigationsForensic Tools for In-Depth Performance Investigations
Forensic Tools for In-Depth Performance InvestigationsNicholas Jansma
 
Introduction to Firebase with Android and Beyond...
Introduction to Firebase with Android and Beyond...Introduction to Firebase with Android and Beyond...
Introduction to Firebase with Android and Beyond...Kasper Loevborg Jensen
 
Introduction to Firebase on Android
Introduction to Firebase on AndroidIntroduction to Firebase on Android
Introduction to Firebase on Androidamsanjeev
 
Firebase Adventures - Real time platform for your apps
Firebase Adventures - Real time platform for your appsFirebase Adventures - Real time platform for your apps
Firebase Adventures - Real time platform for your appsJuarez Filho
 
Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture AppDynamics
 
Nodejs Explained with Examples
Nodejs Explained with ExamplesNodejs Explained with Examples
Nodejs Explained with ExamplesGabriele Lana
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.jsVikash Singh
 
Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907NodejsFoundation
 
Firebase Dev Day Bangkok: Keynote
Firebase Dev Day Bangkok: KeynoteFirebase Dev Day Bangkok: Keynote
Firebase Dev Day Bangkok: KeynoteSittiphol Phanvilai
 

Viewers also liked (20)

Firebase - A real-time server
Firebase - A real-time serverFirebase - A real-time server
Firebase - A real-time server
 
Introduction to Firebase [Google I/O Extended Bangkok 2016]
Introduction to Firebase [Google I/O Extended Bangkok 2016]Introduction to Firebase [Google I/O Extended Bangkok 2016]
Introduction to Firebase [Google I/O Extended Bangkok 2016]
 
Quickie auth with firebase and polymer
Quickie auth with firebase and polymerQuickie auth with firebase and polymer
Quickie auth with firebase and polymer
 
Node.js - A practical introduction (v2)
Node.js  - A practical introduction (v2)Node.js  - A practical introduction (v2)
Node.js - A practical introduction (v2)
 
It jobs road show
It jobs road showIt jobs road show
It jobs road show
 
Change RelationalDB to GraphDB with OrientDB
Change RelationalDB to GraphDB with OrientDBChange RelationalDB to GraphDB with OrientDB
Change RelationalDB to GraphDB with OrientDB
 
Building an alarm clock with node.js
Building an alarm clock with node.jsBuilding an alarm clock with node.js
Building an alarm clock with node.js
 
Node.js - As a networking tool
Node.js - As a networking toolNode.js - As a networking tool
Node.js - As a networking tool
 
Forensic Tools for In-Depth Performance Investigations
Forensic Tools for In-Depth Performance InvestigationsForensic Tools for In-Depth Performance Investigations
Forensic Tools for In-Depth Performance Investigations
 
Introduction to Firebase with Android and Beyond...
Introduction to Firebase with Android and Beyond...Introduction to Firebase with Android and Beyond...
Introduction to Firebase with Android and Beyond...
 
Introduction to Firebase on Android
Introduction to Firebase on AndroidIntroduction to Firebase on Android
Introduction to Firebase on Android
 
Firebase Adventures - Real time platform for your apps
Firebase Adventures - Real time platform for your appsFirebase Adventures - Real time platform for your apps
Firebase Adventures - Real time platform for your apps
 
Why use slideshare
Why use slideshareWhy use slideshare
Why use slideshare
 
NodeJS for Beginner
NodeJS for BeginnerNodeJS for Beginner
NodeJS for Beginner
 
Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture Anatomy of a Modern Node.js Application Architecture
Anatomy of a Modern Node.js Application Architecture
 
Nodejs Explained with Examples
Nodejs Explained with ExamplesNodejs Explained with Examples
Nodejs Explained with Examples
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907Node Foundation Membership Overview 20160907
Node Foundation Membership Overview 20160907
 
How to Use Slideshare
How to Use SlideshareHow to Use Slideshare
How to Use Slideshare
 
Firebase Dev Day Bangkok: Keynote
Firebase Dev Day Bangkok: KeynoteFirebase Dev Day Bangkok: Keynote
Firebase Dev Day Bangkok: Keynote
 

Similar to Firebase slide

System insight without Interference
System insight without InterferenceSystem insight without Interference
System insight without InterferenceTony Tam
 
Introduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azureIntroduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azureColin Mackay
 
Building Your First App with MongoDB
Building Your First App with MongoDBBuilding Your First App with MongoDB
Building Your First App with MongoDBMongoDB
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101Rami Sayar
 
Intro to node and mongodb 1
Intro to node and mongodb   1Intro to node and mongodb   1
Intro to node and mongodb 1Mohammad Qureshi
 
Intro to node.js - Ran Mizrahi (27/8/2014)
Intro to node.js - Ran Mizrahi (27/8/2014)Intro to node.js - Ran Mizrahi (27/8/2014)
Intro to node.js - Ran Mizrahi (27/8/2014)Ran Mizrahi
 
Intro to node.js - Ran Mizrahi (28/8/14)
Intro to node.js - Ran Mizrahi (28/8/14)Intro to node.js - Ran Mizrahi (28/8/14)
Intro to node.js - Ran Mizrahi (28/8/14)Ran Mizrahi
 
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWS
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWSAWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWS
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWSAmazon Web Services
 
Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?Christian Joudrey
 
Advanced Web Technology.pptx
Advanced Web Technology.pptxAdvanced Web Technology.pptx
Advanced Web Technology.pptxssuser35fdf2
 
Coders Workshop: API First Mobile Development Featuring Angular and Node
Coders Workshop: API First Mobile Development Featuring Angular and NodeCoders Workshop: API First Mobile Development Featuring Angular and Node
Coders Workshop: API First Mobile Development Featuring Angular and NodeApigee | Google Cloud
 
Node.js 101 with Rami Sayar
Node.js 101 with Rami SayarNode.js 101 with Rami Sayar
Node.js 101 with Rami SayarFITC
 
Android pentesting the hackers-meetup
Android pentesting the hackers-meetupAndroid pentesting the hackers-meetup
Android pentesting the hackers-meetupkunwaratul hax0r
 
Node.js to the rescue
Node.js to the rescueNode.js to the rescue
Node.js to the rescueMarko Heijnen
 
Practical Use of MongoDB for Node.js
Practical Use of MongoDB for Node.jsPractical Use of MongoDB for Node.js
Practical Use of MongoDB for Node.jsasync_io
 
SOLID Programming with Portable Class Libraries
SOLID Programming with Portable Class LibrariesSOLID Programming with Portable Class Libraries
SOLID Programming with Portable Class LibrariesVagif Abilov
 
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic Beanstalk
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic BeanstalkDeploy, Manage, and Scale Your Apps with OpsWorks and Elastic Beanstalk
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic BeanstalkAmazon Web Services
 

Similar to Firebase slide (20)

System insight without Interference
System insight without InterferenceSystem insight without Interference
System insight without Interference
 
Introduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azureIntroduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azure
 
Building Your First App with MongoDB
Building Your First App with MongoDBBuilding Your First App with MongoDB
Building Your First App with MongoDB
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101
 
Intro to node and mongodb 1
Intro to node and mongodb   1Intro to node and mongodb   1
Intro to node and mongodb 1
 
Intro to node.js - Ran Mizrahi (27/8/2014)
Intro to node.js - Ran Mizrahi (27/8/2014)Intro to node.js - Ran Mizrahi (27/8/2014)
Intro to node.js - Ran Mizrahi (27/8/2014)
 
Intro to node.js - Ran Mizrahi (28/8/14)
Intro to node.js - Ran Mizrahi (28/8/14)Intro to node.js - Ran Mizrahi (28/8/14)
Intro to node.js - Ran Mizrahi (28/8/14)
 
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWS
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWSAWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWS
AWS Summit Stockholm 2014 – T5 – Deploy, manage and scale applications on AWS
 
Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?
 
Advanced Web Technology.pptx
Advanced Web Technology.pptxAdvanced Web Technology.pptx
Advanced Web Technology.pptx
 
Basic API Creation with Node.JS
Basic API Creation with Node.JSBasic API Creation with Node.JS
Basic API Creation with Node.JS
 
Coders Workshop: API First Mobile Development Featuring Angular and Node
Coders Workshop: API First Mobile Development Featuring Angular and NodeCoders Workshop: API First Mobile Development Featuring Angular and Node
Coders Workshop: API First Mobile Development Featuring Angular and Node
 
Node.js 101 with Rami Sayar
Node.js 101 with Rami SayarNode.js 101 with Rami Sayar
Node.js 101 with Rami Sayar
 
Android pentesting the hackers-meetup
Android pentesting the hackers-meetupAndroid pentesting the hackers-meetup
Android pentesting the hackers-meetup
 
My Saminar On Php
My Saminar On PhpMy Saminar On Php
My Saminar On Php
 
Nodejs web,db,hosting
Nodejs web,db,hostingNodejs web,db,hosting
Nodejs web,db,hosting
 
Node.js to the rescue
Node.js to the rescueNode.js to the rescue
Node.js to the rescue
 
Practical Use of MongoDB for Node.js
Practical Use of MongoDB for Node.jsPractical Use of MongoDB for Node.js
Practical Use of MongoDB for Node.js
 
SOLID Programming with Portable Class Libraries
SOLID Programming with Portable Class LibrariesSOLID Programming with Portable Class Libraries
SOLID Programming with Portable Class Libraries
 
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic Beanstalk
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic BeanstalkDeploy, Manage, and Scale Your Apps with OpsWorks and Elastic Beanstalk
Deploy, Manage, and Scale Your Apps with OpsWorks and Elastic Beanstalk
 

Recently uploaded

openEuler Community Overview - a presentation showing the current scale
openEuler Community Overview - a presentation showing the current scaleopenEuler Community Overview - a presentation showing the current scale
openEuler Community Overview - a presentation showing the current scaleShane Coughlan
 
Unlocking AI: Navigating Open Source vs. Commercial Frontiers
Unlocking AI:Navigating Open Source vs. Commercial FrontiersUnlocking AI:Navigating Open Source vs. Commercial Frontiers
Unlocking AI: Navigating Open Source vs. Commercial FrontiersRaphaël Semeteys
 
8 key point on optimizing web hosting services in your business.pdf
8 key point on optimizing web hosting services in your business.pdf8 key point on optimizing web hosting services in your business.pdf
8 key point on optimizing web hosting services in your business.pdfOffsiteNOC
 
Technical improvements. Reasons. Methods. Estimations. CJ
Technical improvements.  Reasons. Methods. Estimations. CJTechnical improvements.  Reasons. Methods. Estimations. CJ
Technical improvements. Reasons. Methods. Estimations. CJpolinaucc
 
MUT4SLX: Extensions for Mutation Testing of Stateflow Models
MUT4SLX: Extensions for Mutation Testing of Stateflow ModelsMUT4SLX: Extensions for Mutation Testing of Stateflow Models
MUT4SLX: Extensions for Mutation Testing of Stateflow ModelsUniversity of Antwerp
 
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...jackiepotts6
 
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...Splashtop Inc
 
Building Generative AI-infused apps: what's possible and how to start
Building Generative AI-infused apps: what's possible and how to startBuilding Generative AI-infused apps: what's possible and how to start
Building Generative AI-infused apps: what's possible and how to startMaxim Salnikov
 
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...Maxim Salnikov
 
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdf
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdfFlutter the Future of Mobile App Development - 5 Crucial Reasons.pdf
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdfMind IT Systems
 
User Experience Designer | Kaylee Miller Resume
User Experience Designer | Kaylee Miller ResumeUser Experience Designer | Kaylee Miller Resume
User Experience Designer | Kaylee Miller ResumeKaylee Miller
 
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...MyFAA
 
Practical Advice for FDA’s 510(k) Requirements.pdf
Practical Advice for FDA’s 510(k) Requirements.pdfPractical Advice for FDA’s 510(k) Requirements.pdf
Practical Advice for FDA’s 510(k) Requirements.pdfICS
 
Enterprise Content Managements Solutions
Enterprise Content Managements SolutionsEnterprise Content Managements Solutions
Enterprise Content Managements SolutionsIQBG inc
 
Boost Efficiency: Sabre API Integration Made Easy
Boost Efficiency: Sabre API Integration Made EasyBoost Efficiency: Sabre API Integration Made Easy
Boost Efficiency: Sabre API Integration Made Easymichealwillson701
 
Unlocking the Power of IoT: A comprehensive approach to real-time insights
Unlocking the Power of IoT: A comprehensive approach to real-time insightsUnlocking the Power of IoT: A comprehensive approach to real-time insights
Unlocking the Power of IoT: A comprehensive approach to real-time insightsconfluent
 
BusinessGPT - SECURITY AND GOVERNANCE FOR GENERATIVE AI.pptx
BusinessGPT  - SECURITY AND GOVERNANCE  FOR GENERATIVE AI.pptxBusinessGPT  - SECURITY AND GOVERNANCE  FOR GENERATIVE AI.pptx
BusinessGPT - SECURITY AND GOVERNANCE FOR GENERATIVE AI.pptxAGATSoftware
 
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityLarge Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityRandy Shoup
 
Leveling Up your Branding and Mastering MERN: Fullstack WebDev
Leveling Up your Branding and Mastering MERN: Fullstack WebDevLeveling Up your Branding and Mastering MERN: Fullstack WebDev
Leveling Up your Branding and Mastering MERN: Fullstack WebDevpmgdscunsri
 
BATbern52 Swisscom's Journey into Data Mesh
BATbern52 Swisscom's Journey into Data MeshBATbern52 Swisscom's Journey into Data Mesh
BATbern52 Swisscom's Journey into Data MeshBATbern
 

Recently uploaded (20)

openEuler Community Overview - a presentation showing the current scale
openEuler Community Overview - a presentation showing the current scaleopenEuler Community Overview - a presentation showing the current scale
openEuler Community Overview - a presentation showing the current scale
 
Unlocking AI: Navigating Open Source vs. Commercial Frontiers
Unlocking AI:Navigating Open Source vs. Commercial FrontiersUnlocking AI:Navigating Open Source vs. Commercial Frontiers
Unlocking AI: Navigating Open Source vs. Commercial Frontiers
 
8 key point on optimizing web hosting services in your business.pdf
8 key point on optimizing web hosting services in your business.pdf8 key point on optimizing web hosting services in your business.pdf
8 key point on optimizing web hosting services in your business.pdf
 
Technical improvements. Reasons. Methods. Estimations. CJ
Technical improvements.  Reasons. Methods. Estimations. CJTechnical improvements.  Reasons. Methods. Estimations. CJ
Technical improvements. Reasons. Methods. Estimations. CJ
 
MUT4SLX: Extensions for Mutation Testing of Stateflow Models
MUT4SLX: Extensions for Mutation Testing of Stateflow ModelsMUT4SLX: Extensions for Mutation Testing of Stateflow Models
MUT4SLX: Extensions for Mutation Testing of Stateflow Models
 
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...
03.2024_North America VMUG Optimizing RevOps using the power of ChatGPT in Ma...
 
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...
Splashtop Enterprise Brochure - Remote Computer Access and Remote Support Sof...
 
Building Generative AI-infused apps: what's possible and how to start
Building Generative AI-infused apps: what's possible and how to startBuilding Generative AI-infused apps: what's possible and how to start
Building Generative AI-infused apps: what's possible and how to start
 
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...
If your code could speak, what would it tell you? Let GitHub Copilot Chat hel...
 
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdf
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdfFlutter the Future of Mobile App Development - 5 Crucial Reasons.pdf
Flutter the Future of Mobile App Development - 5 Crucial Reasons.pdf
 
User Experience Designer | Kaylee Miller Resume
User Experience Designer | Kaylee Miller ResumeUser Experience Designer | Kaylee Miller Resume
User Experience Designer | Kaylee Miller Resume
 
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...
Take Advantage of Mx Tracking Flight Scheduling Solutions to Streamline Your ...
 
Practical Advice for FDA’s 510(k) Requirements.pdf
Practical Advice for FDA’s 510(k) Requirements.pdfPractical Advice for FDA’s 510(k) Requirements.pdf
Practical Advice for FDA’s 510(k) Requirements.pdf
 
Enterprise Content Managements Solutions
Enterprise Content Managements SolutionsEnterprise Content Managements Solutions
Enterprise Content Managements Solutions
 
Boost Efficiency: Sabre API Integration Made Easy
Boost Efficiency: Sabre API Integration Made EasyBoost Efficiency: Sabre API Integration Made Easy
Boost Efficiency: Sabre API Integration Made Easy
 
Unlocking the Power of IoT: A comprehensive approach to real-time insights
Unlocking the Power of IoT: A comprehensive approach to real-time insightsUnlocking the Power of IoT: A comprehensive approach to real-time insights
Unlocking the Power of IoT: A comprehensive approach to real-time insights
 
BusinessGPT - SECURITY AND GOVERNANCE FOR GENERATIVE AI.pptx
BusinessGPT  - SECURITY AND GOVERNANCE  FOR GENERATIVE AI.pptxBusinessGPT  - SECURITY AND GOVERNANCE  FOR GENERATIVE AI.pptx
BusinessGPT - SECURITY AND GOVERNANCE FOR GENERATIVE AI.pptx
 
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityLarge Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
 
Leveling Up your Branding and Mastering MERN: Fullstack WebDev
Leveling Up your Branding and Mastering MERN: Fullstack WebDevLeveling Up your Branding and Mastering MERN: Fullstack WebDev
Leveling Up your Branding and Mastering MERN: Fullstack WebDev
 
BATbern52 Swisscom's Journey into Data Mesh
BATbern52 Swisscom's Journey into Data MeshBATbern52 Swisscom's Journey into Data Mesh
BATbern52 Swisscom's Journey into Data Mesh
 

Firebase slide

  • 2. • Realtime Database call by API • Store as JSON format • Sync data from multiple applications • Only write front end code • Secure and monitor your data • Access from everywhere What is Firebase ?
  • 3. • Originally referring to "non SQL", "non relational" or "not only SQL" • Simplicity of design, simpler "horizontal" scaling to clusters of machines • key-value, wide column, graph, or document • "more flexible" than relational database tables • Most NoSQL stores lack true ACID transactions • Most NoSQL use JSON format What is NO SQL ?
  • 4. • This model organizes data into one or more tables (or "relations") of columns and rows, with a unique key identifying each row. Rows are also called records or tuples. What is Relational DB ?
  • 5. • Move fast • Forget about infrastructure • Make smart, data-driven decisions • Work across platforms • Free to start, scale with ease Why use Firebase ?
  • 7. • Single JSON format Firebase structure {"firstName":"John", "lastName":"Doe" , "age":30 , "gender":"M" , “birthDay":"1/1/1986" }
  • 8. • Go to https://www.firebase.com/ • Click • Click • Fill Project Information Register Firebase
  • 10. • Node.js is a server-side platform. • Built on Google Chrome's JavaScript Engine (V8 Engine). • It was developed by Ryan Dahl in 2009. • It is an open source. • Cross-platform runtime environment for developing server-side and networking applications. • Node.js uses an event-driven, non-blocking I/O model. What is NodeJS ?
  • 11. • The term I/O is used to describe any program, operation or device that transfers data to or from a computer and to or from a peripheral device. What is I/O ?
  • 12. • Most I/O requests are considered blocking requests, meaning that control does not return to the application until the I/O is complete. The delayed from systems calls such read() and write() can be quite long. Using systems call that block is sometimes call synchronous programming. What is Blocking I/O ?
  • 13. • Programs that use non-blocking I/O tend to follow the rule that every function has to return immediately, i.e. all the functions in such programs are nonblocking. Thus control passes very quickly from one routine to the next. What is non blocking I/O ?
  • 14. 1. Go to https://nodejs.org/en/download/ 2. Choose NodeJS for your OS. 3. Extract file and Click on Installer package. 4. After finish installed then open terminal and type command. Installation NodeJS >node -v
  • 15. 1. Create file name package.json Integrate Firebase with NodeJS #2 { "name": "testfirebase", "version": "1.0.0", "description": "MyService is Rest Api Application for our core system.", "scripts": { "test": "echo "Error: no test specified" && exit 1" }, "keywords": [ "Test Firebase" ], "author": “Your Name", "license": "MIT", "dependencies": { "body-parser": ">= 1.14.2", "express": "^4.14.0", "firebase": "^3.5.2", "guid": "latest" } }
  • 16. 2. Install NodeJS Package 3. Create file name “app.js” and put code following. Integrate Firebase with NodeJS >npm install var express = require("express"); var app = express(); require('rootpath')(); var bodyParser = require('body-parser'); app.use(bodyParser.json()); app.listen(3000); console.log("My Service is listening to port 3000.");
  • 17. 4. Go to Firebase console and copy code for web on overview section then paste to app.js . Integrate Firebase with NodeJS var firebase = require("firebase"); // Initialize the app with a service account, granting admin privileges firebase.initializeApp({ apiKey: "AIzaSyBrzkaCzORJfYizrjeIij3rbl6d-EYswt0", authDomain: "ibcrm-b1a74.firebaseapp.com", databaseURL: "https://ibcrm-b1a74.firebaseio.com", storageBucket: "ibcrm-b1a74.appspot.com", messagingSenderId: "810901210082" });
  • 18. 1.Put code in app.js following. 2. Open Terminal then run nodejs > node app.js Create data var Guid = require('guid'); app.post('/members/add',function(req,res){ var _guid = Guid.create(); var guid = _guid.toString(); firebase.database().ref('members/' + guid.toString()) .set(req.body,function(err){ var message ={code:200,status:"Insert completed"} if(err) message ={code:500,status:"error",message:err} else message.result = req.body; res.send(message); }); });
  • 19. Objective Install Chrome Postman for test Restful API. 1. Find in Google by wording is “Chrome Postman” 2. Click add chrome plugin Install Postman
  • 20. Objective Test CRUD Rest API by Postman to make sure that all function are work correctly . 1. Open “Chrome Postman” then set parameter following. Setup Postman’s Parameters 1 2 3 4 2
  • 21. 1.Go to Firebase web console then set JSON following. Open Authorise
  • 22. • Rerun app.js • Back to Chrome Postman then click send button. Test Rest API >node app.js
  • 23. We have created solution like below picture. What we’ve done ? 23
  • 24. 1.Put code in app.js following. 2. Open Terminal then run nodejs > node app.js 3. On Chrome Postman click Send button. Get data app.get('/members/getMany',function(req,res){ firebase.database().ref('members').once('value') .then(function(data){ res.send(data.val()); }) });
  • 25. 1.Put code in app.js following. 2. Open Terminal then run nodejs > node app.js Edit data app.put('/members/edit',function(req,res){ var memberId = req.body.memberId; var memberInfo = req.body.memberInfo; firebase.database().ref('members/' + memberId) .update(memberInfo,function(err){ var message ={code:200,status:"Update completed"} if(err) message ={code:500,status:"error",message:err} else message.result = req.body; res.send(message); }); });
  • 26. 1.Put code in app.js following. 2. Open Terminal then run nodejs > node app.js Delete data app.delete('/members/delete',function(req,res){ var memberId = req.body.memberId; firebase.database().ref('members/' + memberId) .remove(function(err){ var message ={code:200,status:"Remove completed"} if(err) message ={code:500,status:"error",message:err} else message.result = req.body; res.send(message); }); });
  • 27. Human are social animals Give and Take: Why Helping Others Drives Our Success END