Clone this wiki locally
Where are #node.js irc logs?
What is the "official" spelling/capitalization/pronunciation?
- When referring to the software or the project in general, it's Node.js or simply Node. It is a proper noun, so capitalize it. The
.jsappears with the first use, to disambiguate from other things called "Node", and
Node(without the .js) afterwards. One way to think of this is that
Node.jsis the full name, and
Nodeis the more familiar first name.
- When referring specifically to the binary executable, it's always
node, lower-case to match the binary's name itself.
- When referring to the libs that are included with the binary, as opposed to the libs published by Node users in The npm Registry, it's
node core. (See node core vs userland.)
- "npm" is always lowercase, even when it appears at the start of a sentence, unless used in a context where all-caps are used (such as the title of a man page.)
- "npm" is pronounced "en pee em", spelled out.
What is the difference between Node "core" and "userland" modules
What is the versioning scheme?
What is an easy way to manage Node.js versions / installations?
What is the memory limit on a node process?
Currently, by default v8 has a memory limit of 512MB on 32-bit systems, and 1.4GB on 64-bit systems. The limit can be raised by setting
--max_old_space_size to a maximum of ~1024 (~1 GB) (32-bit) and ~4096 (~4GB) (64-bit), but it is recommended that you split your single process into several workers if you are hitting memory limits.
What are Leap Seconds? What impact do they have on applications?
Leap seconds are seconds added or removed from UTC (Coordinated Universal Time) to keep it in sync with the Earth's rotation. If leap seconds were not added or removed, then UTC would drift from TAI. You can read much more about leap seconds on Wikipedia.
Because they are based on astronomical observations, leap seconds are scheduled and not predicted, or predictable. One has been scheduled for June 30th, 2015. What this means practically is that 23:59:59 will be followed by 23:59:60 before going on to 00:00:00. Leap seconds can be added (positive) or removed (negative). A negative leap second would mean that 23:59:58 would be followed by 00:00:00.
There have been problems caused by software not managing this second properly. Note also that depending on the specific implementation and time sychronization mechanisms used, a particular system may not actually "see" the leap second, but it will occur as a regular one second time correction at a later time. All of the timing functions used by Node are monotonic on their various platforms.
Applications should be aware that time-of-day, such as returned by
Date(), is not monotonic and should not be used for timing-sensitive intervals. This is true not just because of leap seconds, but also because of daylight savings time (summer time), and corrections due to clock drift.
For example, the following example code ( counting the number of seconds since Midnight, Jan 1st, 1970 GMT) does not include leap seconds.
var d0 = new Date(0); var d1 = new Date(); // right now. console.log('Unix time started',new Number((d1-d0)/1000).toLocaleString(),'seconds ago');