14. CacheStandalone.js を編集する
var DocumentStore = require('ewd-document-store');
var interface = require('cache');
var db = new interface.cache();
console.log('db: ' * JSON.stringify(db));
//次のパラメータをあなたのCachéシステムに合わせて変更してください
var ok = db.open({
path: '/opt/cache/mgr',
username: '_SYSTEM',
password: 'SYS',
namespace: 'USER'
});
console.log('ok: ' + JSON.stringify(ok));
var documentStore = new DocumentStore(db);
console.log(db.version());
var rob = new documentStore.DocumentNode('rob');
2016/9/11 EWD 3 トレーニング・コース #20 14
15. CacheStandalone.js を編集する
var DocumentStore = require('ewd-qoper8-cache/node_modules/ewd-document-store');
var interface = require('cache');
var db = new interface.cache();
console.log('db: ' * JSON.stringify(db));
//次のパラメータをあなたのCachéシステムに合わせて変更してください
var ok = db.open({
path: 'c:InterSystemsCache2015-2mgr',
username: '_SYSTEM',
password: 'SYS',
namespace: 'USER'
});
console.log('ok: ' + JSON.stringify(ok));
var documentStore = new DocumentStore(db);
console.log(db.version());
var rob = new documentStore.DocumentNode('rob');
2016/9/11 EWD 3 トレーニング・コース #20 15
16. c:ewd3docStoreTest.js として保存
var DocumentStore = require('ewd-qoper8-cache/node_modules/ewd-document-store');
var interface = require('cache');
var db = new interface.cache();
console.log('db: ' * JSON.stringify(db));
//次のパラメータをあなたのCachéシステムに合わせて変更してください
var ok = db.open({
path: 'c:InterSystemsCache2015-2mgr',
username: '_SYSTEM',
password: 'SYS',
namespace: 'USER'
});
console.log('ok: ' + JSON.stringify(ok));
var documentStore = new DocumentStore(db);
console.log(db.version());
var rob = new documentStore.DocumentNode('rob');
2016/9/11 EWD 3 トレーニング・コース #20 16