Cascon intro

30
© 2016 IBM Corporation 1 Agenda – CASCON 2016 Why Node.js ? Node.js quick look Node.js community IBM involvement

Transcript of Cascon intro

Page 1: Cascon intro

© 2016 IBM Corporation 1

Agenda – CASCON 2016

• Why Node.js ?

• Node.js quick look

• Node.js community

• IBM involvement

Page 2: Cascon intro

© 2016 IBM Corporation

• What is it ?

• Ecosystem

• Productivity

• Performance

Why Node.js ?

2

Page 3: Cascon intro

© 2016 IBM Corporation 3

Why Node.js –What is it?

• JavaScript != Java

• Node.js = Server-side JavaScript

• Event-oriented

• Non-blocking

• Asynchronous

Page 4: Cascon intro

http://www.modulecounts.com/

© 2016 IBM Corporation

• There is a module for that• 300K modules

• #1 on module counts

• #1 on Github (#projects)

• #1 on StackOverflow(2015)

Why Node.js ? – Ecosystem

4

Page 5: Cascon intro

© 2016 IBM Corporation

• Most used runtime in

Bluemix

TM

Why Node.js ? – Ecosystem

5

Page 6: Cascon intro

Why Node.js ? – Productivity

© 2016 IBM Corporation

• Faster development less code

• PayPal - https://www.paypal-engineering.com/2013/11/22/node-js-at-paypal/

• Took 1/2 time with less people

• 33% fewer lines of code

• NextFlix - http://www.infoworld.com/article/2610110/javascript/paypal-and-netflix-cozy-up-

to-node-js.html

6

Page 7: Cascon intro

Why Node.js ? – Productivity

© 2016 IBM Corporation

• Reuse of “isomorphic” code components

• Availability of JavaScript talent

• Developer satisfaction

7

Page 8: Cascon intro

Why Node.js ? – Performance

© 2016 IBM Corporation

Event based: perfect fit for asynchronous non-blocking I/0

8

Page 9: Cascon intro

Why Node.js ? - Performance

© 2016 IBM Corporation

• Thousands of concurrent connections

• PayPal - https://www.paypal-engineering.com/2013/11/22/node-js-at-paypal/

• Double number of requests/sec

• Response times 35% lower

• Groupon – http://www.nearform.com/nodecrunch/node-js-becoming-go-technology-enterprise/

• Reduced page load times by 50%

9

Page 10: Cascon intro

© 2016 IBM Corporation 10

• Key characteristics

• Components

• Event loop

Node.js – Quick Look

Page 11: Cascon intro

© 2016 IBM Corporation 11

• Small (linux.tar.xz)• Download 8.2MB

• Uncompressed 35.5 MB

• Fast startup• 40 ms

• Small footprint• 16.5 MB

Node.js – Deep Dive – Key Characteristics

https://nodejs.org/en/download/

https://benchmarking.nodejs.org/

Page 12: Cascon intro

Node.js – Deep Dive - Components

© 2016 IBM Corporation

V8 – JavascriptEngine

V8 JavaScript Engine Libuv

Other DependenciesICUCaresZlibhttp_parser

Node Binding Layer

Operating System

Node Libraries

Modules (npm or local) + Application

Op

en

SS

L

12

Page 13: Cascon intro

Node.js – Deep Dive – Event Loop

© 2016 IBM Corporation 13

Page 14: Cascon intro

© 2016 IBM Corporation 14

• History

• Day to Day

Node.js Community

Page 15: Cascon intro

© 2016 IBM Corporation 15

• 2009 – written by Ryan Dhal

• Jan 2010 - npm

• Sep 2010 – Joyent sponsors Node.js

• June 2011 – Windows support

• 2012 – 2014 – Hand over to Isaac Schlueter, then Timothy J. Fontaine

• December 2014 – io.js fork

• June 2015 – Node.js Foundation

• Oct 2015 – Node.js 4.x unites io.js/node.js 0.12.x lines

• Oct 2016 – Node.js 6.x

Node.js Community - History

Page 16: Cascon intro

© 2016 IBM Corporation 16

• TSC - Technical Steering Committee

• CTC – Core technical Committee

• Collaborators (~76)

• Working Groups (Build, LTS, Benchmarking, API etc.)

• Teams

Node.js Community – Day to Day

https://github.com/nodejs/TSC/

https://github.com/nodejs/node/

https://github.com/nodejs/node/blob/master/WORKING_GROUPS.md

https://github.com/orgs/nodejs/teams

Page 17: Cascon intro

© 2016 IBM Corporation 17

• Node.js Community Involvement

• V8 Community Involvement

• Platform Availability

• Tooling

Node.js - IBM

Page 18: Cascon intro

© 2016 IBM Corporation 18

• Leadership

• Founding member of Node.js Foundation (1 board member)

• 4 CTC/TSC members (+2 past members)

• Facilitating multiple working groups

Node.js IBM - Node.js Community Involvement

Page 19: Cascon intro

© 2016 IBM Corporation 19

• Regular contributors• Active in working groups

LTS, build, post-mortem, build, security, api, citgm, dev-policy, benchmarking, internationalization

• 11 IBMr’s with commit rights • including #2, #5, #15, #28, #39, #42, #46

• Driving support for platforms - Linux on PPC, AIX and Linux on Z

Node.js IBM - Node.js Community Involvement

Page 20: Cascon intro

© 2016 IBM Corporation 20

• Deep expertise at V8• Developed ports to IBM Platforms• Contribution back to official V8 repositories:

https://github.com/v8/v8• PPC: V8 4.3 and later have full functional PPC implementation• s390: V8 5.1 and later have full functional implementation

• ~10-15 commits per week to V8 to maintain PPC/zlinux port• Port to z/OS in progress:

• https://github.com/ibmruntimes/v8z/tree/3.28-zos

Node.js IBM –V8 Community Involvement

Page 21: Cascon intro

© 2016 IBM Corporation 21

Node.js IBM – Platform Availability

• IBM SDK for Node.js– Shipping Node.js releases since 2013

– 0.10.x + 0.12.x + 4.x + 6.x

– Linux on x / p / z, AIX, Windows, Mac

– Working on support for z/OS

• Community

Page 22: Cascon intro

© 2016 IBM Corporation 22

Node.js Long Term Support (LTS)

https://github.com/nodejs/lts

• Current Release

– every 6 months

– Semver major

• LTS release every

October

– Even semver majors

– 30 months of support

Page 23: Cascon intro

© 2016 IBM Corporation 23

• Appmetrics

• Health Center

• NodeReport

• Core inspection - IDDE/LLNODE

• GCMV

Node.js IBM – Tooling

Page 24: Cascon intro

© 2016 IBM Corporation 24

Node.js IBM – Appmetrics

https://www.npmjs.com/package/appmetrics

Page 25: Cascon intro

© 2016 IBM Corporation 25

Node.js IBM – Tooling - Healthcenter

https://marketplace.eclipse.org/content/

ibm-monitoring-and-diagnostic-tools-

health-center

• Free download

• Node.js + Java

Page 26: Cascon intro

© 2016 IBM Corporation 26

Node.js IBM – Tooling - NodeReport

NodeReport example - heap

out of memory error

NodeReport content:

● Event summary

● Node.js and OS versions

● JavaScript stack trace

● Native stack trace

● Heap and GC statistics

● Resource usage

● libuv handle summary

● Environment variables

● OS ulimit settings

https://github.com/nodejs/nodereport

© 2016 IBM Corporation

Page 27: Cascon intro

© 2016 IBM Corporation 27

• MDB/LLNODE/IDDE

• Working in community to

standardize

Node.js IBM – Tooling - Core Inspection

Page 28: Cascon intro

• Free download

• --trace_gc

• --trace_gc_nvp

• --trace_gc_verbose

• Node.js + Java

© 2016 IBM Corporation 28

Node.js IBM – Tooling - GCMV

https://marketplace.eclipse.org/content/ibm-monitoring-and-diagnostic-tools-garbage-collection-and-memory-visualizer-gcmv

Page 29: Cascon intro

Copyright © 2016 by International Business Machines Corporation (IBM). No part of this document may be reproduced or transmitted in any form without written permission

from IBM.

U.S. Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM.

Information in these presentations (including information relating to products that have not yet been announced by IBM) has been reviewed for accuracy as of the date of initial

publication and could include unintentional technical or typographical errors. IBM shall have no responsibility to update this information. THIS DOCUMENT IS DISTRIBUTED

"AS IS" WITHOUT ANY WARRANTY, EITHER EXPRESS OR IMPLIED. IN NO EVENT SHALL IBM BE LIABLE FOR ANY DAMAGE ARISING FROM THE USE OF THIS

INFORMATION, INCLUDING BUT NOT LIMITED TO, LOSS OF DATA, BUSINESS INTERRUPTION, LOSS OF PROFIT OR LOSS OF OPPORTUNITY. IBM products and

services are warranted according to the terms and conditions of the agreements under which they are provided.

Any statements regarding IBM's future direction, intent or product plans are subject to change or withdrawal without notice.

Performance data contained herein was generally obtained in a controlled, isolated environments. Customer examples are presented as illustrations of how those customers

have used IBM products and the results they may have achieved. Actual performance, cost, savings or other results in other operating environments may vary.

References in this document to IBM products, programs, or services does not imply that IBM intends to make such products, programs or services available in all countries in

which IBM operates or does business.

Workshops, sessions and associated materials may have been prepared by independent session speakers, and do not necessarily reflect the views of IBM. All materials and

discussions are provided for informational purposes only, and are neither intended to, nor shall constitute legal or other guidance or advice to any individual participant or their

specific situation.

It is the customer’s responsibility to insure its own compliance with legal requirements and to obtain advice of competent legal counsel as to the identification and

interpretation of any relevant laws and regulatory requirements that may affect the customer’s business and any actions the customer may need to take to comply with such

laws. IBM does not provide legal advice or represent or warrant that its services or products will ensure that the customer is in compliance with any law.

Page 30: Cascon intro

Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not

tested those products in connection with this publication and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products.

Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products. IBM does not warrant the quality of any third-party products, or the

ability of any such third-party products to interoperate with IBM’s products. IBM EXPRESSLY DISCLAIMS ALL WARRANTIES, EXPRESSED OR IMPLIED, INCLUDING BUT

NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.

The provision of the information contained herein is not intended to, and does not, grant any right or license under any IBM patents, copyrights, trademarks or other intellectual

property right.

• IBM, the IBM logo, ibm.com, Aspera®, Bluemix, Blueworks Live, CICS, Clearcase, Cognos®, DOORS®, Emptoris®, Enterprise Document Management System™,

FASP®, FileNet®, Global Business Services ®, Global Technology Services ®, IBM ExperienceOne™, IBM SmartCloud®, IBM Social Business®, Information on Demand,

ILOG, Maximo®, MQIntegrator®, MQSeries®, Netcool®, OMEGAMON, OpenPower, PureAnalytics™, PureApplication®, pureCluster™, PureCoverage®, PureData®,

PureExperience®, PureFlex®, pureQuery®, pureScale®, PureSystems®, QRadar®, Rational®, Rhapsody®, Smarter Commerce®, SoDA, SPSS, Sterling Commerce®,

StoredIQ, Tealeaf®, Tivoli®, Trusteer®, Unica®, urban{code}®, Watson, WebSphere®, Worklight®, X-Force® and System z® Z/OS, are trademarks of International

Business Machines Corporation, registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current

list of IBM trademarks is available on the Web at "Copyright and trademark information" at: www.ibm.com/legal/copytrade.shtml.

• Node.js is an official trademark of Joyent. IBM SDK for Node.js is not formally related to or endorsed by the official Joyent Node.js open source or commercial project.

• Java, JavaScript and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and/or its affiliates.

• npm is a trademark of npm, Inc.