Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cagey

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cagey - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

2

lib/index.js

@@ -13,3 +13,3 @@ 'use strict';

async shutdown() {
this.log.info('Shutting down...');
this.log.info('Shutting down Cagey instance...');

@@ -16,0 +16,0 @@ await this.emitAsync('beforeShutdown');

{
"name": "cagey",
"version": "0.0.3",
"version": "0.0.4",
"description": "Cagey game framework",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

# Cagey core
[![Greenkeeper badge](https://badges.greenkeeper.io/cagey-framework/cagey.svg)](https://greenkeeper.io/)
**WORK IN PROGRESS**

@@ -28,4 +30,4 @@

as possible to reflect *business logic*, not framework patterns, or the database we chose, or the network technology,
etc. If we ever want to switch frameworks, databases, loggers, KPI services, etc. this should be as painless as
possible. The fundamental nature of our business logic should not be contaminated by these choices.
etc. If we ever want to switch frameworks, databases, KPI services, etc. this should be as painless as possible. The
fundamental nature of our business logic should not be contaminated by these choices.

@@ -74,3 +76,3 @@ Cagey attempts to solve this by keeping concerns separated as follows:

Creates and returns an instance of the `Cagey` class. You must pass a `Bunyan` logger instance in an object.
Creates and returns an instance of the `Cagey` class. You must pass a `cagey-logger` instance in an object.

@@ -81,4 +83,4 @@ **async cagey.shutdown()**

- `"beforeShutdown" ()` on the cagey.
- `"shutdown" ()` on the cagey.
- `"beforeShutdown" ()` on the cagey instance.
- `"shutdown" ()` on the cagey instance.

@@ -97,5 +99,6 @@ The events being emitted can be used to stop certain subsystems, and close connections.

- Client/server messaging: [cagey-client-messenger](https://github.com/cagey-framework/cagey-client-messenger)
- Cagey distributed cluster messaging: [cagey-peer-network](https://github.com/cagey-framework/cagey-peer-network)
- User sessions: [cagey-sessions](https://github.com/cagey-framework/cagey-sessions)
- Logger: [cagey-logger](https://www.npmjs.com/package/cagey-logger)
- Client/server messaging: [cagey-client-messenger](https://www.npmjs.com/package/cagey-client-messenger)
- Cagey distributed cluster messaging: [cagey-peer-network](https://www.npmjs.com/package/cagey-peer-network)
- User sessions: [cagey-sessions](https://www.npmjs.com/package/cagey-sessions)

@@ -113,10 +116,12 @@ ## Plugin development

and reduces dependency chaos. For example:
- Bunyan logger: [bunyan](https://www.npmjs.com/package/bunyan)
- *always* accept an external bunyan logger object in setup.
- Logging: [cagey-logger](https://www.npmjs.com/package/cagey-logger)
- *always* accept an external cagey-logger object in setup.
- *always* prefix log entries with `[subsystem-name] `.
- prefer to avoid `debug` and `info` levels; leave those to user land (ie: prefer `trace` for non-errors).
- usually stick to the `debug` level; leave higher levels to user land.
- do not log errors that you do not catch and handle; leave that to user land.
- EventEmitter: [eventemitter2](https://www.npmjs.com/package/eventemitter2)
- *always* emit using `emitAsync` so listeners can safely do I/O if they need to.
- Deep copy: [deep-copy](https://www.npmjs.com/package/deep-copy)
- Parsing duration strings into milliseconds: [parse-duration](https://www.npmjs.com/package/parse-duration)
- Configure duration using string notation, parseable with [parse-duration](https://www.npmjs.com/package/parse-duration)
- Configure bytes using string notation, parseable with [bytes](https://www.npmjs.com/package/bytes)
- A well written plugin has:

@@ -128,2 +133,3 @@ - Documentation

- A license that is identical to or compatible with Cagey
- TravisCI and Greenkeeper

@@ -146,6 +152,6 @@ ### Typical API

class MyPlugin extends EventEmitter {
constructor({ log }, options) {
super();
constructor({ log }, options) {
super();
this.log = log;
this.log = log;
}

@@ -152,0 +158,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc