Socket
Book a DemoInstallSign in
Socket

dynostore

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dynostore

Dynamo db wrapper for the jepso-ci schema

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

dynostore

Dynamo db wrapper for the jepso-ci schema

Sample Usage

var u = 'api';
var r = 'foo';
var t = 'master';
createBuild(u, r, t, ['BrowserA', 'BrowserB'])
  .then(function (buildID) {
    console.log('buildID=' + buildID);
    function logStatus(v) {
      return getRepo(u, r)
        .then(log)
        .then(function () {
          return getBuild(u, r, buildID);
        })
        .then(log)
        .then(function () {
          return v;
        });
    }
    return logStatus()
      .then(function () {
        console.log("updateBuild(u, r, buildID, 'BrowserA', 'started', false)");
        return updateBuild(u, r, buildID, 'BrowserA', 'started', false);
      })
      .then(logStatus)
      .then(function () {
        console.log("updateBuild(u, r, buildID, 'BrowserB', 'started', false)");
        return updateBuild(u, r, buildID, 'BrowserB', 'started', false);
      })
      .then(logStatus)
      .then(function () {
        console.log("updateBuild(u, r, buildID, 'BrowserA', 'finished', true)");
        return updateBuild(u, r, buildID, 'BrowserA', 'finished', true);
      })
      .then(logStatus)
      .then(function () {
        console.log("updateBuild(u, r, buildID, 'BrowserB', 'finished', true)");
        return updateBuild(u, r, buildID, 'BrowserB', 'finished', true);
      })
      .then(logStatus)
  }).done()
function log(v) {
  console.log(v);
  return v;
}

Sample Output:

buildID=1
{ user: 'api',
  repo: 'foo',
  currentBuildInProgress: '1',
  latestBuild: null }
{ tag: 'master',
  repoID: 'api/foo',
  'BrowserA-pending': true,
  buildID: 1,
  pending: 2,
  BrowserA: 'queued',
  'BrowserB-pending': true,
  BrowserB: 'queued' }
updateBuild(u, r, buildID, 'BrowserA', 'started', false)
{ user: 'api',
  repo: 'foo',
  currentBuildInProgress: '1',
  latestBuild: null }
{ tag: 'master',
  repoID: 'api/foo',
  'BrowserA-pending': true,
  buildID: 1,
  pending: 2,
  BrowserA: 'started',
  'BrowserB-pending': true,
  BrowserB: 'queued' }
updateBuild(u, r, buildID, 'BrowserB', 'started', false)
{ user: 'api',
  repo: 'foo',
  currentBuildInProgress: '1',
  latestBuild: null }
{ tag: 'master',
  repoID: 'api/foo',
  'BrowserA-pending': true,
  buildID: 1,
  pending: 2,
  BrowserA: 'started',
  'BrowserB-pending': true,
  BrowserB: 'started' }
updateBuild(u, r, buildID, 'BrowserA', 'finished', true)
{ user: 'api',
  repo: 'foo',
  currentBuildInProgress: '1',
  latestBuild: null }
{ tag: 'master',
  repoID: 'api/foo',
  'BrowserA-pending': false,
  buildID: 1,
  pending: 1,
  BrowserA: 'finished',
  'BrowserB-pending': true,
  BrowserB: 'started' }
updateBuild(u, r, buildID, 'BrowserB', 'finished', true)
{ user: 'api',
  repo: 'foo',
  currentBuildInProgress: null,
  latestBuild: '1' }
{ tag: 'master',
  repoID: 'api/foo',
  'BrowserA-pending': false,
  buildID: 1,
  pending: 0,
  BrowserA: 'finished',
  'BrowserB-pending': false,
  BrowserB: 'finished' }

FAQs

Package last updated on 31 Dec 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts