whatap 0.4.57 → 0.4.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -194,7 +194,7 @@ var ConfigDefault = {
194
194
  // reqlog add
195
195
  "reqlog_rotation_enabled": true,
196
196
  "reqlog_keep_days": 7,
197
- "reqlog_enabled": false,
197
+ "reqlog_enabled": bool('reqlog_enabled', false),
198
198
  "reqlog_seperator" : str('reqlog_seperator', '|'),
199
199
 
200
200
  "reqlog_x_etime" : bool('reqlog_x_etime', true),
package/lib/core/agent.js CHANGED
@@ -123,8 +123,8 @@ NodeAgent.prototype.init = function(cb) {
123
123
  e, true);
124
124
  return;
125
125
  }
126
- Logger.print('WHATAP-101', 'Finish initialize configuration...', false);
127
- if(self._conf['reqlog_enabled'] === true ) {
126
+ Logger.print('WHATAP-101', 'Finish initialize configuration... ' + Boolean(self._conf['reqlog_enabled']) , false);
127
+ if(Boolean(self._conf['reqlog_enabled']) == true ) {
128
128
  Logger.print("WHATAP-REQLOG" , "ReqLog Init Start !!!! " , false);
129
129
  RequestLog.initializer.process();
130
130
  }
@@ -402,7 +402,7 @@ HttpObserver.prototype.__endTransaction = function(error, ctx, req, res) {
402
402
 
403
403
  profile.oid = SecurityMaster.OID;
404
404
  profile.service = wtx;
405
- if(conf.reqlog_enabled === true) {
405
+ if(Boolean(conf.reqlog_enabled) == true) {
406
406
  ctx.endTime = wtx.endTime;
407
407
  ctx.elapsed = wtx.elapsed;
408
408
  RequestLog.setRecord(ctx);
@@ -28,7 +28,14 @@ function LockCompetition(key){
28
28
  root = cwd;
29
29
  }
30
30
  let gubun = hahsUtil.hash(IPUtil.getIp());
31
- this.rootFolder = path.join(root,'SSwhatapSS').replace('SSwhatapSS','\.'+key + '/' + gubun);
31
+ this.rootFolder = path.join(root,'SSwhatapSS').replace('SSwhatapSS',path.sep + '.'+key);
32
+ if(fs.existsSync(this.rootFolder) == false) {
33
+ fs.mkdirSync(this.rootFolder);
34
+ }
35
+ this.rootFolder += path.sep + gubun;
36
+ if(fs.existsSync(this.rootFolder) == false) {
37
+ fs.mkdirSync(this.rootFolder);
38
+ }
32
39
  this.LOCK_FILE = path.join(this.rootFolder,this.MAIN_KEY+'.lock');
33
40
  this.initComplete = false;
34
41
  }
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "whatap",
3
3
  "homepage": "http://www.whatap.io",
4
- "version": "0.4.57",
5
- "releaseDate": "20220808",
4
+ "version": "0.4.60",
5
+ "releaseDate": "20220824",
6
6
  "description": "Monitoring and Profiling Service",
7
7
  "main": "index.js",
8
8
  "scripts": {},