StrongLoop Node.js Weekly Review – June 30, 2014

Here’s this week’s recap of the Node.js related blogs we posted last week…

Node.js Performance Tip of the Week: Managing Garbage Collection

In this week’s post we’ll dive into the fundamentals of garbage collection (GC) in V8 and how it holds the “keys to the kingdom” in the optimization of Node applications. We will also look at some tools to triage GC and memory management issues in V8.

Read more…

Comparing Winston and Bunyan Node.js Logging

If you are writing any kind of long living application, detailed logging is paramount to spotting problems and debugging. Without logs you would have few ways of telling how is your application behaving, are there errors, what’s the performance like, is it doing anything at all or is it just falling over every other request when you aren’t looking at it. In this article we are going to talk about popular Node.js logging frameworks Bunyan and Winston.

Read more…

Coming to Node.js v0.12: An Overview of New Features

Along with the community, StrongLoop is excited for Node v0.12 to become generally available. There’s no time like the present to get familiar with the new features that are coming to v0.12. We’ve compiled the list below to help you get prepared:

  • Cluster round-robin load balancing
  • Performance optimizations
  • Running multiple instances in a single process
  • execSync: a synchronous API for child processes
  • Debugging clustered apps with Node Inspector

Read more…

Announcing Support for Google, Facebook and GitHub Authentication in LoopBack.io

We’re excited to announce that the LoopBack API framework now supports:

  • Third-party login, to enable your LoopBack apps to allow login using existing accounts on Facebook, Google, Twitter, or Github.
  • Integration with enterprise security services so that users can login with them instead of username and password-based authentication.
  • Account linking to link an account authorized through one of the above services with a LoopBack application user record.  This enables you to manage and control your own user account records while still integrating with third-party services.

What’s LoopBack? It’s an open source API framework powered by Node.js for connecting devices and apps to enterprise data and services.

Read more…

Use StrongOps to Monitor Node Apps

Ready to start monitoring event loops, manage Node clusters and chase down memory leaks? We’ve made it easy to get started with StrongOps either locally or on your favorite cloud, with a simple npm install.

Screen Shot 2014-02-03 at 3.25.40 AM

What’s next?

Node.js Performance Tip of the Week: Managing Garbage Collection

Please note that as of Aug 3, 2015, StrongOps has been EOL’d. Check out StrongLoop Arc for the same capabilities and more.

In our last weekly performance tip, we discussed in detail how the Node.js event-loop works as the orchestrator of requests, events and callbacks. We also troubleshot a blocked event-loop which could wreck havoc on application performance. In this week’s post we’ll dive into the fundamentals of garbage collection (GC) in V8 and how it holds the “keys to the kingdom” in the optimization of Node applications. We will also look at some tools to triage GC and memory management issues in V8.

Where did it all start

                 V8.png

Contrary to folklore, V8 was not designed explicitly for Node; rather was built to power a fast browser (Chrome/Chromium) or client side JavaScript (V8.NET). Eventually it got ported to the server as a high performance engine for running server side JavaScript and became the basis of Node. But, just like any server side runtime like the JVM or CLR, V8 runs on memory and needs memory management.

In some systems or languages, it is up to the application program to manage all the bookkeeping details of allocating memory from the heap and freeing it when it is no longer required. This is known as manual memory management. Manual memory management may be appropriate for small programs, but it does not scale well in general, nor does it encourage modular or object-oriented programming.

Read more

Comparing Winston and Bunyan Node.js Logging

Lets talk about logging, shall we? Arnold over here carrying a giant log feels like an appropriate intro to this article in which we are going to talk about popular Node.js logging frameworks.

If you are writing any kind of long living application, detailed logging is paramount to spotting problems and debugging. Without logs you would have few ways of telling how is your application behaving, are there errors, what’s the performance like, is it doing anything at all or is it just falling over every other request when you aren’t looking at it.

Read more

What’s Coming to Node v0.12: An Overview of New Features

Along with the community, StrongLoop is excited for Node v0.12 to become generally available.

What’s New?

There’s no time like the present to get familiar with the new features that are coming to v0.12. We’ve compiled the list below to help you get prepared:

  • Cluster round-robin load balancing
  • Performance optimizations
  • Running multiple instances in a single process
  • execSync: a synchronous API for child processes
  • Debugging clustered apps with Node Inspector

Read more

Announcing Support for Google, Facebook and GitHub Authentication in LoopBack

Introduction

These days most people have dozens of logins, and no one really wants to register for yet another website or app.  It’s easier to attract new users by allowing them to login with an existing account from a popular service such as Google or Facebook, for example.  Additionally, enterprise applications often need to work with existing authentication and identity systems such as LDAP, kerberos, and SAML.

We’re excited to announce that the LoopBack API framework now supports:

  • Third-party login, to enable your LoopBack apps to allow login using existing accounts on Facebook, Google, Twitter, or Github.
  • Integration with enterprise security services so that users can login with them instead of username and password-based authentication.
  • Account linking to link an account authorized through one of the above services with a LoopBack application user record.  This enables you to manage and control your own user account records while still integrating with third-party services.

What’s LoopBack? It’s an open source API framework powered by Node.js for connecting devices and apps to enterprise data and services.

These new capabilities are provided through the loopback-passport module that integrates LoopBack and Passport, one of the leading modules for Node authentication middleware.

LoopBack authentication and authorization

LoopBack already provides full-featured support for managing users and client applications. The LoopBack user and application models enable applications to easily:

  • Sign up a new user
  • Log in using username/email and password
  • Log out
  • Verify a user registration by email
  • Sign up a new client application
  • Authenticate a client application by ID and keys

Like other models, the user and application models can be backed by any of the databases supported by LoopBack connectors (Oracle, MySQL, PostgreSQL, MongoDB, SQL Server and others). Thus, a LoopBack application can easily serve APIs to clients on behalf of authenticated users. Read more