SlideShare ist ein Scribd-Unternehmen logo
1 von 16
Downloaden Sie, um offline zu lesen
WRITING BROWSER RELOAD
FUNCTIONALITY FROM SCRATCH
Anze Znidarsic, Flycom d.o.o.
WHAT DOYOU GUYS DO?
more: bit.ly/gms3video
Geographic Information System
STACK
• Ubuntu Linux
• Nginx
• PHP (Laravel) - App & API
• NodeJS - Real time communications
• Many small integrated GIS related components
DEV ENVIRONMENT
• Macs
• Vagrant +VirtualBox (VmWare on production)
• Looking into microservices (Docker and friends)
• PhpStorm IDE
• Gulp task runner
YES,WE USE GULP..
• .. I know, Gulp is like sooooo 2014
• npm install --save-dev gulp-babel
BROWSER RELOAD SOLUTION GOALS
• A developer changes php/js/css code
• All opened browsers (on all connected devices) refresh
• Solution criteria: works on any browser, supports http2
• Possible upgrades (e.g., hot reload, HMR, action sync)
PROCESS
Code change
if .scss then process SCSS to CSS
if .js then process ES201x to ES5
if .php then just go on
Reload all opened
browsers
Local browsers (Chrome,
Safari, Firefox..)
VM browsers (Internet
Explorer, Edge)
Simulators
(iOS, Android)
Devices
(iPhone,
Android, iPad)
EXISTING SOLUTIONS
• livereload.com
• browser extension
• paid solution
• browsersync.io
• proxy solution
• does not support http2
OUR SOLUTION
Page requested
NodeJS Server
Page displayed
Laravel app
Secure WebSocket connection established
Open website in all
browsers (either manually
or through a script)
BROWSERSERVERDEVELOPER
OUR SOLUTION
Page requested
NodeJS Server
Page displayed
Laravel app
Reload
Open website in all
browsers (either manually
or through a script)
BROWSERSERVERDEVELOPER
Code change in
i.e. PhpStorm
Task runner (Gulp)
Compile JS, CSS and other
files
Code change detected
Request reload
WHYTHAT NODEJS SERVER?
• We already had it, it’s not required, server-side of web sockets can be
included in the file watcher (Gulp task runner in our example)
NODEJS SERVER
BROWSER
HM…YOU DIDN’T USE PORT 5000!
• We proxy WS through nginx so it works behind corporate firewalls
GULP
We’re always looking for new talent to join our growing team.
For more contact me at anze@flycom.si
Thank you
twitter.com/anzeznidarsic

Weitere ähnliche Inhalte

Was ist angesagt?

OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph GaluschkaOpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
NETWAYS
 
Workshop For pycon13
Workshop For pycon13Workshop For pycon13
Workshop For pycon13
Steven Pousty
 
Scale Big With Docker — Moboom 2014
Scale Big With Docker — Moboom 2014Scale Big With Docker — Moboom 2014
Scale Big With Docker — Moboom 2014
Jérôme Petazzoni
 
Using Nagios to monitor your WO systems
Using Nagios to monitor your WO systemsUsing Nagios to monitor your WO systems
Using Nagios to monitor your WO systems
WO Community
 
Docker session I: Continuous integration, delivery and deployment
Docker session I: Continuous integration, delivery and deploymentDocker session I: Continuous integration, delivery and deployment
Docker session I: Continuous integration, delivery and deployment
Degendra Sivakoti
 
DevOps: Using Vagrant to Enhance Your Day to Day Development
DevOps: Using Vagrant to Enhance Your Day to Day DevelopmentDevOps: Using Vagrant to Enhance Your Day to Day Development
DevOps: Using Vagrant to Enhance Your Day to Day Development
Rob Reynolds
 

Was ist angesagt? (20)

Grunt JS - Getting Started With Grunt
Grunt JS - Getting Started With GruntGrunt JS - Getting Started With Grunt
Grunt JS - Getting Started With Grunt
 
OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph GaluschkaOpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
OpenNebula Conf 2014: CentOS, QA an OpenNebula - Christoph Galuschka
 
Introducing docker
Introducing dockerIntroducing docker
Introducing docker
 
Docker e git lab
Docker e git labDocker e git lab
Docker e git lab
 
Introduction to Docker Compose
Introduction to Docker ComposeIntroduction to Docker Compose
Introduction to Docker Compose
 
Workshop For pycon13
Workshop For pycon13Workshop For pycon13
Workshop For pycon13
 
Grunt
GruntGrunt
Grunt
 
Masterless puppet
Masterless puppetMasterless puppet
Masterless puppet
 
Scale Big With Docker — Moboom 2014
Scale Big With Docker — Moboom 2014Scale Big With Docker — Moboom 2014
Scale Big With Docker — Moboom 2014
 
Wt vs phalcon
Wt vs phalconWt vs phalcon
Wt vs phalcon
 
Beyond Puppet
Beyond PuppetBeyond Puppet
Beyond Puppet
 
Intro to Linux - Skillswap
Intro to Linux - Skillswap Intro to Linux - Skillswap
Intro to Linux - Skillswap
 
Using Nagios to monitor your WO systems
Using Nagios to monitor your WO systemsUsing Nagios to monitor your WO systems
Using Nagios to monitor your WO systems
 
Jimmy Tang - Deploying with Ansible
Jimmy Tang - Deploying with AnsibleJimmy Tang - Deploying with Ansible
Jimmy Tang - Deploying with Ansible
 
Docker session I: Continuous integration, delivery and deployment
Docker session I: Continuous integration, delivery and deploymentDocker session I: Continuous integration, delivery and deployment
Docker session I: Continuous integration, delivery and deployment
 
Heketi Functionality into Glusterd2
Heketi Functionality into Glusterd2Heketi Functionality into Glusterd2
Heketi Functionality into Glusterd2
 
DevOps: Using Vagrant to Enhance Your Day to Day Development
DevOps: Using Vagrant to Enhance Your Day to Day DevelopmentDevOps: Using Vagrant to Enhance Your Day to Day Development
DevOps: Using Vagrant to Enhance Your Day to Day Development
 
Anton Cherednikov "Modules and Artifacts in NPM"
Anton Cherednikov "Modules and Artifacts in NPM"Anton Cherednikov "Modules and Artifacts in NPM"
Anton Cherednikov "Modules and Artifacts in NPM"
 
Gluster as Native Storage for Containers - past, present and future
Gluster as Native Storage for Containers - past, present and futureGluster as Native Storage for Containers - past, present and future
Gluster as Native Storage for Containers - past, present and future
 
OpenNebula Conf 2014 | Building Hybrid Cloud Federated Environments with Open...
OpenNebula Conf 2014 | Building Hybrid Cloud Federated Environments with Open...OpenNebula Conf 2014 | Building Hybrid Cloud Federated Environments with Open...
OpenNebula Conf 2014 | Building Hybrid Cloud Federated Environments with Open...
 

Ähnlich wie Writing your own browser reload functionality

Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9 Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9
Jérôme Petazzoni
 
A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and Containers
Docker, Inc.
 

Ähnlich wie Writing your own browser reload functionality (20)

Docker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los AngelesDocker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los Angeles
 
Docker+java
Docker+javaDocker+java
Docker+java
 
Docker and-containers-for-development-and-deployment-scale12x
Docker and-containers-for-development-and-deployment-scale12xDocker and-containers-for-development-and-deployment-scale12x
Docker and-containers-for-development-and-deployment-scale12x
 
Rapid and Reliable Developing with HTML5 & GWT
Rapid and Reliable Developing with HTML5 & GWTRapid and Reliable Developing with HTML5 & GWT
Rapid and Reliable Developing with HTML5 & GWT
 
Implementing your own Google App Engine
Implementing your own Google App Engine Implementing your own Google App Engine
Implementing your own Google App Engine
 
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special EditionIntroduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
 
Getting started with AMD GPUs
Getting started with AMD GPUsGetting started with AMD GPUs
Getting started with AMD GPUs
 
Gitlab ci-cd
Gitlab ci-cdGitlab ci-cd
Gitlab ci-cd
 
Introduction to node.js By Ahmed Assaf
Introduction to node.js  By Ahmed AssafIntroduction to node.js  By Ahmed Assaf
Introduction to node.js By Ahmed Assaf
 
Multi-stage Docker builds to make building easy!
Multi-stage Docker builds to make building easy!Multi-stage Docker builds to make building easy!
Multi-stage Docker builds to make building easy!
 
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsI Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
 
How to deploy a Java application on Google App engine Flexible environment
How to deploy a Java application on Google App engine Flexible environmentHow to deploy a Java application on Google App engine Flexible environment
How to deploy a Java application on Google App engine Flexible environment
 
LUG - Install Fest 2008
LUG - Install Fest 2008LUG - Install Fest 2008
LUG - Install Fest 2008
 
Modern web technologies
Modern web technologiesModern web technologies
Modern web technologies
 
Docker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQ
Docker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQDocker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQ
Docker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQ
 
Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9 Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9
 
OSDC.no 2015 introduction to node.js workshop
OSDC.no 2015 introduction to node.js workshopOSDC.no 2015 introduction to node.js workshop
OSDC.no 2015 introduction to node.js workshop
 
OpenStack - JobShop @Iași, 2016
OpenStack - JobShop @Iași, 2016OpenStack - JobShop @Iași, 2016
OpenStack - JobShop @Iași, 2016
 
State of Big Data on ARM64 / AArch64 - Apache Bigtop
State of Big Data on ARM64 / AArch64 - Apache BigtopState of Big Data on ARM64 / AArch64 - Apache Bigtop
State of Big Data on ARM64 / AArch64 - Apache Bigtop
 
A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and Containers
 

Kürzlich hochgeladen

TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 

Kürzlich hochgeladen (20)

Pharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodologyPharm-D Biostatistics and Research methodology
Pharm-D Biostatistics and Research methodology
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdfThe Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
ManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide DeckManageIQ - Sprint 236 Review - Slide Deck
ManageIQ - Sprint 236 Review - Slide Deck
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verifiedSector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
Sector 18, Noida Call girls :8448380779 Model Escorts | 100% verified
 
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456LEVEL 5   - SESSION 1 2023 (1).pptx - PDF 123456
LEVEL 5 - SESSION 1 2023 (1).pptx - PDF 123456
 

Writing your own browser reload functionality

  • 1. WRITING BROWSER RELOAD FUNCTIONALITY FROM SCRATCH Anze Znidarsic, Flycom d.o.o.
  • 2. WHAT DOYOU GUYS DO? more: bit.ly/gms3video Geographic Information System
  • 3. STACK • Ubuntu Linux • Nginx • PHP (Laravel) - App & API • NodeJS - Real time communications • Many small integrated GIS related components
  • 4. DEV ENVIRONMENT • Macs • Vagrant +VirtualBox (VmWare on production) • Looking into microservices (Docker and friends) • PhpStorm IDE • Gulp task runner
  • 5. YES,WE USE GULP.. • .. I know, Gulp is like sooooo 2014 • npm install --save-dev gulp-babel
  • 6. BROWSER RELOAD SOLUTION GOALS • A developer changes php/js/css code • All opened browsers (on all connected devices) refresh • Solution criteria: works on any browser, supports http2 • Possible upgrades (e.g., hot reload, HMR, action sync)
  • 7. PROCESS Code change if .scss then process SCSS to CSS if .js then process ES201x to ES5 if .php then just go on Reload all opened browsers Local browsers (Chrome, Safari, Firefox..) VM browsers (Internet Explorer, Edge) Simulators (iOS, Android) Devices (iPhone, Android, iPad)
  • 8. EXISTING SOLUTIONS • livereload.com • browser extension • paid solution • browsersync.io • proxy solution • does not support http2
  • 9. OUR SOLUTION Page requested NodeJS Server Page displayed Laravel app Secure WebSocket connection established Open website in all browsers (either manually or through a script) BROWSERSERVERDEVELOPER
  • 10. OUR SOLUTION Page requested NodeJS Server Page displayed Laravel app Reload Open website in all browsers (either manually or through a script) BROWSERSERVERDEVELOPER Code change in i.e. PhpStorm Task runner (Gulp) Compile JS, CSS and other files Code change detected Request reload
  • 11. WHYTHAT NODEJS SERVER? • We already had it, it’s not required, server-side of web sockets can be included in the file watcher (Gulp task runner in our example)
  • 14. HM…YOU DIDN’T USE PORT 5000! • We proxy WS through nginx so it works behind corporate firewalls
  • 15. GULP
  • 16. We’re always looking for new talent to join our growing team. For more contact me at anze@flycom.si Thank you twitter.com/anzeznidarsic