@resolveio/server-lib 8.0.15 → 8.0.17

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.
Files changed (96) hide show
  1. package/collections/app-status.collection.d.ts +2 -2
  2. package/collections/app-status.collection.js +16 -12
  3. package/collections/app-status.collection.js.map +1 -1
  4. package/collections/app-version.collection.d.ts +2 -2
  5. package/collections/app-version.collection.js +18 -14
  6. package/collections/app-version.collection.js.map +1 -1
  7. package/collections/counter.collection.d.ts +2 -2
  8. package/collections/counter.collection.js +18 -14
  9. package/collections/counter.collection.js.map +1 -1
  10. package/collections/cron-job-history.collection.d.ts +2 -2
  11. package/collections/cron-job-history.collection.js +17 -13
  12. package/collections/cron-job-history.collection.js.map +1 -1
  13. package/collections/cron-job.collection.d.ts +2 -2
  14. package/collections/cron-job.collection.js +17 -13
  15. package/collections/cron-job.collection.js.map +1 -1
  16. package/collections/email-history.collection.d.ts +2 -2
  17. package/collections/email-history.collection.js +16 -12
  18. package/collections/email-history.collection.js.map +1 -1
  19. package/collections/email-verified.collection.d.ts +2 -2
  20. package/collections/email-verified.collection.js +16 -12
  21. package/collections/email-verified.collection.js.map +1 -1
  22. package/collections/file.collection.d.ts +2 -2
  23. package/collections/file.collection.js +20 -16
  24. package/collections/file.collection.js.map +1 -1
  25. package/collections/flag.collection.d.ts +2 -2
  26. package/collections/flag.collection.js +16 -12
  27. package/collections/flag.collection.js.map +1 -1
  28. package/collections/log-method-latency.collection.d.ts +2 -2
  29. package/collections/log-method-latency.collection.js +15 -11
  30. package/collections/log-method-latency.collection.js.map +1 -1
  31. package/collections/log-subscription.collection.d.ts +2 -2
  32. package/collections/log-subscription.collection.js +15 -11
  33. package/collections/log-subscription.collection.js.map +1 -1
  34. package/collections/log.collection.d.ts +2 -2
  35. package/collections/log.collection.js +15 -11
  36. package/collections/log.collection.js.map +1 -1
  37. package/collections/logged-in-users.collection.d.ts +2 -2
  38. package/collections/logged-in-users.collection.js +16 -12
  39. package/collections/logged-in-users.collection.js.map +1 -1
  40. package/collections/method-call.collection.d.ts +1 -1
  41. package/collections/method-call.collection.js +5 -2
  42. package/collections/method-call.collection.js.map +1 -1
  43. package/collections/method-response.collection.d.ts +1 -1
  44. package/collections/method-response.collection.js +5 -2
  45. package/collections/method-response.collection.js.map +1 -1
  46. package/collections/monitor-cpu.collection.d.ts +2 -2
  47. package/collections/monitor-cpu.collection.js +16 -12
  48. package/collections/monitor-cpu.collection.js.map +1 -1
  49. package/collections/monitor-https-inbound.collection.d.ts +2 -2
  50. package/collections/monitor-https-inbound.collection.js +16 -12
  51. package/collections/monitor-https-inbound.collection.js.map +1 -1
  52. package/collections/monitor-https-outbound.collection.d.ts +2 -2
  53. package/collections/monitor-https-outbound.collection.js +16 -12
  54. package/collections/monitor-https-outbound.collection.js.map +1 -1
  55. package/collections/monitor-memory.collection.d.ts +2 -2
  56. package/collections/monitor-memory.collection.js +16 -12
  57. package/collections/monitor-memory.collection.js.map +1 -1
  58. package/collections/monitor-mongo.collection.d.ts +2 -2
  59. package/collections/monitor-mongo.collection.js +16 -12
  60. package/collections/monitor-mongo.collection.js.map +1 -1
  61. package/collections/notification.collection.d.ts +2 -2
  62. package/collections/notification.collection.js +16 -12
  63. package/collections/notification.collection.js.map +1 -1
  64. package/collections/queue-flag.collection.d.ts +2 -2
  65. package/collections/queue-flag.collection.js +16 -12
  66. package/collections/queue-flag.collection.js.map +1 -1
  67. package/collections/queue-method.collection.d.ts +2 -2
  68. package/collections/queue-method.collection.js +58 -54
  69. package/collections/queue-method.collection.js.map +1 -1
  70. package/collections/queue-response.collection.d.ts +2 -2
  71. package/collections/queue-response.collection.js +17 -13
  72. package/collections/queue-response.collection.js.map +1 -1
  73. package/collections/report-builder-library.collection.d.ts +2 -2
  74. package/collections/report-builder-library.collection.js +17 -13
  75. package/collections/report-builder-library.collection.js.map +1 -1
  76. package/collections/report-builder-report.collection.d.ts +2 -2
  77. package/collections/report-builder-report.collection.js +17 -13
  78. package/collections/report-builder-report.collection.js.map +1 -1
  79. package/collections/user-group.collection.d.ts +2 -2
  80. package/collections/user-group.collection.js +22 -18
  81. package/collections/user-group.collection.js.map +1 -1
  82. package/collections/user-guide.collection.d.ts +2 -2
  83. package/collections/user-guide.collection.js +20 -16
  84. package/collections/user-guide.collection.js.map +1 -1
  85. package/collections/user.collection.d.ts +3 -3
  86. package/collections/user.collection.js +21 -17
  87. package/collections/user.collection.js.map +1 -1
  88. package/http/auth.js.map +1 -1
  89. package/index.d.ts +1 -0
  90. package/index.js +4 -0
  91. package/index.js.map +1 -1
  92. package/package.json +1 -1
  93. package/public_api.d.ts +70 -0
  94. package/public_api.js +39 -0
  95. package/public_api.js.map +1 -0
  96. package/server-app.js.map +1 -1
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { LogMethodLatencyModel } from '../models/log-method-latency.model';
3
3
  interface ResolveIOModel extends LogMethodLatencyModel, Document {
4
4
  }
5
- export declare const LogMethodLatencies: Model<ResolveIOModel>;
6
- export declare const LogMethodLatencyVersions: Model<ResolveIOModel>;
5
+ export declare let LogMethodLatencies: Model<ResolveIOModel>;
6
+ export declare let LogMethodLatencyVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -41,16 +41,20 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
41
41
  DefaultSchema.index({ createdAt: 1 }, { expireAfterSeconds: 60 * 60 * 24 * 30 });
42
42
  DefaultSchema.index({ latency_ms: 1 });
43
43
  DefaultSchema.index({ method: 1 });
44
- exports.LogMethodLatencies = index_1.ResolveIOServer.getMainDB().model('log-method-latencies', DefaultSchema);
45
- schema._id = {
46
- type: mongoose_1.Schema.Types.Mixed
47
- };
48
- var VersionSchema = new mongoose_1.Schema(schema, {
49
- skipVersioning: true,
50
- versionKey: false,
51
- timestamps: true
52
- });
53
- exports.LogMethodLatencies['versionCollection'] = 'log-method-latencies.versions';
54
- exports.LogMethodLatencyVersions = index_1.ResolveIOServer.getMainDB().model(exports.LogMethodLatencies['versionCollection'], VersionSchema);
44
+ exports.LogMethodLatencies = null;
45
+ exports.LogMethodLatencyVersions = null;
46
+ if (index_1.ResolveIOServer.getMainDB()) {
47
+ exports.LogMethodLatencies = index_1.ResolveIOServer.getMainDB().model('log-method-latencies', DefaultSchema);
48
+ schema._id = {
49
+ type: mongoose_1.Schema.Types.Mixed
50
+ };
51
+ var VersionSchema = new mongoose_1.Schema(schema, {
52
+ skipVersioning: true,
53
+ versionKey: false,
54
+ timestamps: true
55
+ });
56
+ exports.LogMethodLatencies['versionCollection'] = 'log-method-latencies.versions';
57
+ exports.LogMethodLatencyVersions = index_1.ResolveIOServer.getMainDB().model(exports.LogMethodLatencies['versionCollection'], VersionSchema);
58
+ }
55
59
 
56
60
  //# sourceMappingURL=log-method-latency.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/log-method-latency.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,UAAU,EAAE;QACX,IAAI,EAAE,IAAI;KACV;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAC7E,aAAa,CAAC,KAAK,CAAC,EAAC,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACrC,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAC,CAAC,CAAC;AAGpB,QAAA,kBAAkB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,sBAAsB,EAAE,aAAa,CAAC,CAAC;AAElI,MAAM,CAAC,GAAG,GAAG;IACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;CACxB,CAAC;AAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACtC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,0BAAkB,CAAC,mBAAmB,CAAC,GAAG,+BAA+B,CAAC;AAE7D,QAAA,wBAAwB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,0BAAkB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"log-method-latency.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogMethodLatencyModel } from '../models/log-method-latency.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate_start: {\n\t\ttype: Date\n\t},\n\tdate_end: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tlatency_ms: {\n\t\ttype: Number\n\t},\n\tmethod: {\n\t\ttype: String\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({latency_ms: 1});\nDefaultSchema.index({method: 1});\n\ninterface ResolveIOModel extends LogMethodLatencyModel, Document {}\nexport const LogMethodLatencies: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('log-method-latencies', DefaultSchema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nLogMethodLatencies['versionCollection'] = 'log-method-latencies.versions';\n\nexport const LogMethodLatencyVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(LogMethodLatencies['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/log-method-latency.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,UAAU,EAAE;QACX,IAAI,EAAE,IAAI;KACV;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAC7E,aAAa,CAAC,KAAK,CAAC,EAAC,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACrC,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAC,CAAC,CAAC;AAItB,QAAA,kBAAkB,GAA0B,IAAI,CAAC;AACjD,QAAA,wBAAwB,GAA0B,IAAI,CAAC;AAElE,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,0BAAkB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,sBAAsB,EAAE,aAAa,CAAC,CAAC;IAE9F,MAAM,CAAC,GAAG,GAAG;QACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;QACtC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,0BAAkB,CAAC,mBAAmB,CAAC,GAAG,+BAA+B,CAAC;IAE1E,gCAAwB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,0BAAkB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CACrH","file":"log-method-latency.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogMethodLatencyModel } from '../models/log-method-latency.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate_start: {\n\t\ttype: Date\n\t},\n\tdate_end: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tlatency_ms: {\n\t\ttype: Number\n\t},\n\tmethod: {\n\t\ttype: String\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({latency_ms: 1});\nDefaultSchema.index({method: 1});\n\ninterface ResolveIOModel extends LogMethodLatencyModel, Document {}\n\nexport let LogMethodLatencies: Model<ResolveIOModel> = null;\nexport let LogMethodLatencyVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tLogMethodLatencies = ResolveIOServer.getMainDB().model('log-method-latencies', DefaultSchema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tLogMethodLatencies['versionCollection'] = 'log-method-latencies.versions';\n\n\tLogMethodLatencyVersions = ResolveIOServer.getMainDB().model(LogMethodLatencies['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { LogSubscriptionModel } from '../models/log-subscription.model';
3
3
  interface ResolveIOModel extends LogSubscriptionModel, Document {
4
4
  }
5
- export declare const LogSubscriptions: Model<ResolveIOModel>;
6
- export declare const LogSubscriptionVersions: Model<ResolveIOModel>;
5
+ export declare let LogSubscriptions: Model<ResolveIOModel>;
6
+ export declare let LogSubscriptionVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -49,16 +49,20 @@ DefaultSchema.index({ type: 1 });
49
49
  DefaultSchema.index({ collection_name: 1 });
50
50
  DefaultSchema.index({ date: 1, type: 1 });
51
51
  DefaultSchema.index({ createdAt: 1 });
52
- exports.LogSubscriptions = index_1.ResolveIOServer.getMainDB().model('log-subscriptions', DefaultSchema);
53
- schema._id = {
54
- type: mongoose_1.Schema.Types.Mixed
55
- };
56
- var VersionSchema = new mongoose_1.Schema(schema, {
57
- skipVersioning: true,
58
- versionKey: false,
59
- timestamps: true
60
- });
61
- exports.LogSubscriptions['versionCollection'] = 'log-subscriptions.versions';
62
- exports.LogSubscriptionVersions = index_1.ResolveIOServer.getMainDB().model(exports.LogSubscriptions['versionCollection'], VersionSchema);
52
+ exports.LogSubscriptions = null;
53
+ exports.LogSubscriptionVersions = null;
54
+ if (index_1.ResolveIOServer.getMainDB()) {
55
+ exports.LogSubscriptions = index_1.ResolveIOServer.getMainDB().model('log-subscriptions', DefaultSchema);
56
+ schema._id = {
57
+ type: mongoose_1.Schema.Types.Mixed
58
+ };
59
+ var VersionSchema = new mongoose_1.Schema(schema, {
60
+ skipVersioning: true,
61
+ versionKey: false,
62
+ timestamps: true
63
+ });
64
+ exports.LogSubscriptions['versionCollection'] = 'log-subscriptions.versions';
65
+ exports.LogSubscriptionVersions = index_1.ResolveIOServer.getMainDB().model(exports.LogSubscriptions['versionCollection'], VersionSchema);
66
+ }
63
67
 
64
68
  //# sourceMappingURL=log-subscription.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/log-subscription.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,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B,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,wBAAgB,CAAC,mBAAmB,CAAC,GAAG,4BAA4B,CAAC;AAExD,QAAA,uBAAuB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,wBAAgB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"log-subscription.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogSubscriptionModel } from '../models/log-subscription.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\ttype: {\n\t\ttype: String\n\t},\n\tsubscription: {\n\t\ttype: String\n\t},\n\tcollection_name: {\n\t\ttype: String\n\t},\n\tsubData: {\n\t\ttype: Array\t\n\t},\n\t'subData.$': {\n\t\ttype: Object,\n\t\tblackbox: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({type: 1});\nDefaultSchema.index({collection_name: 1});\nDefaultSchema.index({date: 1, type: 1});\nDefaultSchema.index({createdAt: 1});\n\ninterface ResolveIOModel extends LogSubscriptionModel, Document {}\nexport const LogSubscriptions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('log-subscriptions', DefaultSchema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nLogSubscriptions['versionCollection'] = 'log-subscriptions.versions';\n\nexport const LogSubscriptionVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(LogSubscriptions['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/log-subscription.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,IAAI,EAAE;QACL,IAAI,EAAE,MAAM;KACZ;IACD,YAAY,EAAE;QACb,IAAI,EAAE,MAAM;KACZ;IACD,eAAe,EAAE;QAChB,IAAI,EAAE,MAAM;KACZ;IACD,OAAO,EAAE;QACR,IAAI,EAAE,KAAK;KACX;IACD,WAAW,EAAE;QACZ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AACxE,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,CAAC,CAAC;AAC/B,aAAa,CAAC,KAAK,CAAC,EAAC,eAAe,EAAE,CAAC,EAAC,CAAC,CAAC;AAC1C,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAC,CAAC,CAAC;AACxC,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,CAAC,CAAC;AAIzB,QAAA,gBAAgB,GAA0B,IAAI,CAAC;AAC/C,QAAA,uBAAuB,GAA0B,IAAI,CAAC;AAEjE,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,wBAAgB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,mBAAmB,EAAE,aAAa,CAAC,CAAC;IAEzF,MAAM,CAAC,GAAG,GAAG;QACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;QACtC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,wBAAgB,CAAC,mBAAmB,CAAC,GAAG,4BAA4B,CAAC;IAErE,+BAAuB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,wBAAgB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CAClH","file":"log-subscription.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogSubscriptionModel } from '../models/log-subscription.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\ttype: {\n\t\ttype: String\n\t},\n\tsubscription: {\n\t\ttype: String\n\t},\n\tcollection_name: {\n\t\ttype: String\n\t},\n\tsubData: {\n\t\ttype: Array\t\n\t},\n\t'subData.$': {\n\t\ttype: Object,\n\t\tblackbox: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({type: 1});\nDefaultSchema.index({collection_name: 1});\nDefaultSchema.index({date: 1, type: 1});\nDefaultSchema.index({createdAt: 1});\n\ninterface ResolveIOModel extends LogSubscriptionModel, Document {}\n\nexport let LogSubscriptions: Model<ResolveIOModel> = null;\nexport let LogSubscriptionVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tLogSubscriptions = ResolveIOServer.getMainDB().model('log-subscriptions', DefaultSchema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tLogSubscriptions['versionCollection'] = 'log-subscriptions.versions';\n\n\tLogSubscriptionVersions = ResolveIOServer.getMainDB().model(LogSubscriptions['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { LogModel } from '../models/log.model';
3
3
  interface ResolveIOModel extends LogModel, Document {
4
4
  }
5
- export declare const Logs: Model<ResolveIOModel>;
6
- export declare const LogVersions: Model<ResolveIOModel>;
5
+ export declare let Logs: Model<ResolveIOModel>;
6
+ export declare let LogVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -65,16 +65,20 @@ DefaultSchema.index({ type: 1 });
65
65
  DefaultSchema.index({ type: 1, date: 1 });
66
66
  DefaultSchema.index({ user: 1, date: 1 });
67
67
  DefaultSchema.index({ user: 1, type: 1, date: 1 });
68
- exports.Logs = index_1.ResolveIOServer.getMainDB().model('logs', DefaultSchema);
69
- schema._id = {
70
- type: mongoose_1.Schema.Types.Mixed
71
- };
72
- var VersionSchema = new mongoose_1.Schema(schema, {
73
- skipVersioning: true,
74
- versionKey: false,
75
- timestamps: true
76
- });
77
- exports.Logs['versionCollection'] = 'logs.versions';
78
- exports.LogVersions = index_1.ResolveIOServer.getMainDB().model(exports.Logs['versionCollection'], VersionSchema);
68
+ exports.Logs = null;
69
+ exports.LogVersions = null;
70
+ if (index_1.ResolveIOServer.getMainDB()) {
71
+ exports.Logs = index_1.ResolveIOServer.getMainDB().model('logs', DefaultSchema);
72
+ schema._id = {
73
+ type: mongoose_1.Schema.Types.Mixed
74
+ };
75
+ var VersionSchema = new mongoose_1.Schema(schema, {
76
+ skipVersioning: true,
77
+ versionKey: false,
78
+ timestamps: true
79
+ });
80
+ exports.Logs['versionCollection'] = 'logs.versions';
81
+ exports.LogVersions = index_1.ResolveIOServer.getMainDB().model(exports.Logs['versionCollection'], VersionSchema);
82
+ }
79
83
 
80
84
  //# sourceMappingURL=log.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/log.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,IAAI,EAAE;QACL,IAAI,EAAE,MAAM;KACZ;IACD,KAAK,EAAE;QACN,IAAI,EAAE,MAAM;KACZ;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE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MAAM,EAAE;IACtC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,YAAI,CAAC,mBAAmB,CAAC,GAAG,eAAe,CAAC;AAE/B,QAAA,WAAW,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,YAAI,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"log.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogModel } from '../models/log.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\ttype: {\n\t\ttype: String\n\t},\n\ttitle: {\n\t\ttype: String\n\t},\n\tmessage: {\n\t\ttype: String\n\t},\n\tpayload: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tuser: {\n\t\ttype: String\n\t},\n\tmessageId: {\n\t\ttype: String\n\t},\n\troute: {\n\t\ttype: String\n\t},\n\tdata_0: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\tdata_1: {\n\t\ttype: String,\n\t\toptional: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({type: 1});\nDefaultSchema.index({type: 1, date: 1});\nDefaultSchema.index({user: 1, date: 1});\nDefaultSchema.index({user: 1, type: 1, date: 1});\n\ninterface ResolveIOModel extends LogModel, Document {}\nexport const Logs: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('logs', DefaultSchema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nLogs['versionCollection'] = 'logs.versions';\n\nexport const LogVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(Logs['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/log.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,IAAI,EAAE;QACL,IAAI,EAAE,MAAM;KACZ;IACD,KAAK,EAAE;QACN,IAAI,EAAE,MAAM;KACZ;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,MAAM;KACZ;IACD,SAAS,EAAE;QACV,IAAI,EAAE,MAAM;KACZ;IACD,KAAK,EAAE;QACN,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAA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.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LogModel } from '../models/log.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\ttype: {\n\t\ttype: String\n\t},\n\ttitle: {\n\t\ttype: String\n\t},\n\tmessage: {\n\t\ttype: String\n\t},\n\tpayload: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tuser: {\n\t\ttype: String\n\t},\n\tmessageId: {\n\t\ttype: String\n\t},\n\troute: {\n\t\ttype: String\n\t},\n\tdata_0: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\tdata_1: {\n\t\ttype: String,\n\t\toptional: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\nDefaultSchema.index({type: 1});\nDefaultSchema.index({type: 1, date: 1});\nDefaultSchema.index({user: 1, date: 1});\nDefaultSchema.index({user: 1, type: 1, date: 1});\n\ninterface ResolveIOModel extends LogModel, Document {}\n\nexport let Logs: Model<ResolveIOModel> = null;\nexport let LogVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tLogs = ResolveIOServer.getMainDB().model('logs', DefaultSchema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tLogs['versionCollection'] = 'logs.versions';\n\n\tLogVersions = ResolveIOServer.getMainDB().model(Logs['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { LoggedInUserModel } from '../models/logged-in-users.model';
3
3
  interface ResolveIOModel extends LoggedInUserModel, Document {
4
4
  }
5
- export declare const LoggedInUsers: Model<ResolveIOModel>;
6
- export declare const LoggedInUserVersions: Model<ResolveIOModel>;
5
+ export declare let LoggedInUsers: Model<ResolveIOModel>;
6
+ export declare let LoggedInUserVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -57,17 +57,21 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
57
57
  timestamps: true
58
58
  });
59
59
  DefaultSchema.index({ id_ws: 1 });
60
- exports.LoggedInUsers = index_1.ResolveIOServer.getMainDB().model('logged-in-users', DefaultSchema);
61
- var vSchema = __assign({}, schema);
62
- vSchema._id = {
63
- type: mongoose_1.Schema.Types.Mixed
64
- };
65
- var VersionSchema = new mongoose_1.Schema(vSchema, {
66
- skipVersioning: true,
67
- versionKey: false,
68
- timestamps: true
69
- });
70
- exports.LoggedInUsers['versionCollection'] = 'logged-in-users.versions';
71
- exports.LoggedInUserVersions = index_1.ResolveIOServer.getMainDB().model(exports.LoggedInUsers['versionCollection'], VersionSchema);
60
+ exports.LoggedInUsers = null;
61
+ exports.LoggedInUserVersions = null;
62
+ if (index_1.ResolveIOServer.getMainDB()) {
63
+ exports.LoggedInUsers = index_1.ResolveIOServer.getMainDB().model('logged-in-users', DefaultSchema);
64
+ var vSchema = __assign({}, schema);
65
+ vSchema._id = {
66
+ type: mongoose_1.Schema.Types.Mixed
67
+ };
68
+ var VersionSchema = new mongoose_1.Schema(vSchema, {
69
+ skipVersioning: true,
70
+ versionKey: false,
71
+ timestamps: true
72
+ });
73
+ exports.LoggedInUsers['versionCollection'] = 'logged-in-users.versions';
74
+ exports.LoggedInUserVersions = index_1.ResolveIOServer.getMainDB().model(exports.LoggedInUsers['versionCollection'], VersionSchema);
75
+ }
72
76
 
73
77
  //# sourceMappingURL=logged-in-users.collection.js.map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G,IAAI,iBAAM,CAAC,OAAO,EAAE;IACvC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,qBAAa,CAAC,mBAAmB,CAAC,GAAG,0BAA0B,CAAC;AAEnD,QAAA,oBAAoB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,qBAAa,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"logged-in-users.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LoggedInUserModel } from '../models/logged-in-users.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tuser: {\n\t\ttype: String\n\t},\n\tid_ws: {\n\t\ttype: String\n\t},\n\tapp_version: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tlatency: {\n\t\ttype: Number,\n\t\toptional: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_ws: 1});\n\ninterface ResolveIOModel extends LoggedInUserModel, Document {}\nexport const LoggedInUsers: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('logged-in-users', DefaultSchema);\n\nlet vSchema = { ...schema };\nvSchema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(vSchema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nLoggedInUsers['versionCollection'] = 'logged-in-users.versions';\n\nexport const LoggedInUserVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(LoggedInUsers['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/logged-in-users.collection.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,qCAAmD;AACnD,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,MAAM;KACZ;IACD,KAAK,EAAE;QACN,IAAI,EAAE,MAAM;KACZ;IACD,WAAW,EAAE;QACZ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,KAAK,EAAE,CAAC,EAAC,CAAC,CAAC;AAIrB,QAAA,aAAa,GAA0B,IAAI,CAAC;AAC5C,QAAA,oBAAoB,GAA0B,IAAI,CAAC;AAE9D,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,qBAAa,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,iBAAiB,EAAE,aAAa,CAAC,CAAC;IAEpF,IAAI,OAAO,gBAAQ,MAAM,CAAE,CAAC;IAC5B,OAAO,CAAC,GAAG,GAAG;QACb,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,OAAO,EAAE;QACvC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,qBAAa,CAAC,mBAAmB,CAAC,GAAG,0BAA0B,CAAC;IAEhE,4BAAoB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,qBAAa,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CAC5G","file":"logged-in-users.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport { ResolveIOServer } from '../index';\nimport { LoggedInUserModel } from '../models/logged-in-users.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tuser: {\n\t\ttype: String\n\t},\n\tid_ws: {\n\t\ttype: String\n\t},\n\tapp_version: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tlatency: {\n\t\ttype: Number,\n\t\toptional: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_ws: 1});\n\ninterface ResolveIOModel extends LoggedInUserModel, Document {}\n\nexport let LoggedInUsers: Model<ResolveIOModel> = null;\nexport let LoggedInUserVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tLoggedInUsers = ResolveIOServer.getMainDB().model('logged-in-users', DefaultSchema);\n\n\tlet vSchema = { ...schema };\n\tvSchema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(vSchema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tLoggedInUsers['versionCollection'] = 'logged-in-users.versions';\n\n\tLoggedInUserVersions = ResolveIOServer.getMainDB().model(LoggedInUsers['versionCollection'], VersionSchema);\n}"]}
@@ -2,5 +2,5 @@ import { Model, Document } from 'mongoose';
2
2
  import { MethodCallModel } from '../models/method-call.model';
3
3
  interface ResolveIOModel extends MethodCallModel, Document {
4
4
  }
5
- export declare const MethodCalls: Model<ResolveIOModel>;
5
+ export declare let MethodCalls: Model<ResolveIOModel>;
6
6
  export {};
@@ -40,7 +40,10 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
40
40
  });
41
41
  DefaultSchema.index({ id_user: 1, message_id: 1 });
42
42
  DefaultSchema.index({ createdAt: 1 }, { expireAfterSeconds: 86400 });
43
- exports.MethodCalls = index_1.ResolveIOServer.getMainDB().model('method-calls', DefaultSchema);
44
- exports.MethodCalls['simplschema'] = new simpl_schema_1.default(schema);
43
+ exports.MethodCalls = null;
44
+ if (index_1.ResolveIOServer.getMainDB()) {
45
+ exports.MethodCalls = index_1.ResolveIOServer.getMainDB().model('method-calls', DefaultSchema);
46
+ exports.MethodCalls['simplschema'] = new simpl_schema_1.default(schema);
47
+ }
45
48
 
46
49
  //# sourceMappingURL=method-call.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/method-call.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACjD,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,KAAK,EAAC,CAAC,CAAC;AAGpD,QAAA,WAAW,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,cAAc,EAAE,aAAa,CAAC,CAAC;AAEnH,mBAAW,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC","file":"method-call.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MethodCallModel } from '../models/method-call.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tmessage_id: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_user: 1, message_id: 1});\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 86400});\n\ninterface ResolveIOModel extends MethodCallModel, Document {}\nexport const MethodCalls: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('method-calls', DefaultSchema);\n\nMethodCalls['simplschema'] = new SimpleSchema(schema);"]}
1
+ {"version":3,"sources":["../../src/collections/method-call.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACjD,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,KAAK,EAAC,CAAC,CAAC;AAItD,QAAA,WAAW,GAA0B,IAAI,CAAC;AAErD,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,mBAAW,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,cAAc,EAAE,aAAa,CAAC,CAAC;IAE/E,mBAAW,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;CACtD","file":"method-call.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MethodCallModel } from '../models/method-call.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tmessage_id: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_user: 1, message_id: 1});\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 86400});\n\ninterface ResolveIOModel extends MethodCallModel, Document {}\n\nexport let MethodCalls: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tMethodCalls = ResolveIOServer.getMainDB().model('method-calls', DefaultSchema);\n\n\tMethodCalls['simplschema'] = new SimpleSchema(schema);\n}"]}
@@ -2,5 +2,5 @@ import { Model, Document } from 'mongoose';
2
2
  import { MethodResponseModel } from '../models/method-response.model';
3
3
  interface ResolveIOModel extends MethodResponseModel, Document {
4
4
  }
5
- export declare const MethodResponses: Model<ResolveIOModel>;
5
+ export declare let MethodResponses: Model<ResolveIOModel>;
6
6
  export {};
@@ -44,7 +44,10 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
44
44
  });
45
45
  DefaultSchema.index({ id_user: 1, message_id: 1 });
46
46
  DefaultSchema.index({ createdAt: 1 }, { expireAfterSeconds: 86400 });
47
- exports.MethodResponses = index_1.ResolveIOServer.getMainDB().model('method-responses', DefaultSchema);
48
- exports.MethodResponses['simplschema'] = new simpl_schema_1.default(schema);
47
+ exports.MethodResponses = null;
48
+ if (index_1.ResolveIOServer.getMainDB()) {
49
+ exports.MethodResponses = index_1.ResolveIOServer.getMainDB().model('method-responses', DefaultSchema);
50
+ exports.MethodResponses['simplschema'] = new simpl_schema_1.default(schema);
51
+ }
49
52
 
50
53
  //# sourceMappingURL=method-response.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/method-response.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACjD,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,KAAK,EAAC,CAAC,CAAC;AAGpD,QAAA,eAAe,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,kBAAkB,EAAE,aAAa,CAAC,CAAC;AAE3H,uBAAe,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC","file":"method-response.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MethodResponseModel } from '../models/method-response.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tmessage_id: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tresponse: {\n\t\ttype: Object,\n\t\tblackbox: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_user: 1, message_id: 1});\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 86400});\n\ninterface ResolveIOModel extends MethodResponseModel, Document {}\nexport const MethodResponses: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('method-responses', DefaultSchema);\n\nMethodResponses['simplschema'] = new SimpleSchema(schema);"]}
1
+ {"version":3,"sources":["../../src/collections/method-response.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,OAAO,EAAE;QACR,IAAI,EAAE,MAAM;KACZ;IACD,UAAU,EAAE;QACX,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAC,CAAC,CAAC;AACjD,aAAa,CAAC,KAAK,CAAC,EAAC,SAAS,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,KAAK,EAAC,CAAC,CAAC;AAItD,QAAA,eAAe,GAA0B,IAAI,CAAC;AAEzD,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,uBAAe,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,kBAAkB,EAAE,aAAa,CAAC,CAAC;IAEvF,uBAAe,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;CAC1D","file":"method-response.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MethodResponseModel } from '../models/method-response.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tid_user: {\n\t\ttype: String\n\t},\n\tmessage_id: {\n\t\ttype: String\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\tresponse: {\n\t\ttype: Object,\n\t\tblackbox: true\n\t},\n\tdate: {\n\t\ttype: Date\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({id_user: 1, message_id: 1});\nDefaultSchema.index({createdAt: 1}, {expireAfterSeconds: 86400});\n\ninterface ResolveIOModel extends MethodResponseModel, Document {}\n\nexport let MethodResponses: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tMethodResponses = ResolveIOServer.getMainDB().model('method-responses', DefaultSchema);\n\n\tMethodResponses['simplschema'] = new SimpleSchema(schema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { MonitorCPUModel } from '../models/monitor-cpu.model';
3
3
  interface ResolveIOModel extends MonitorCPUModel, Document {
4
4
  }
5
- export declare const MonitorCPUs: Model<ResolveIOModel>;
6
- export declare const MonitorCPUVersions: Model<ResolveIOModel>;
5
+ export declare let MonitorCPUs: Model<ResolveIOModel>;
6
+ export declare let MonitorCPUVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -44,17 +44,21 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
44
44
  DefaultSchema.index({ client: 1, instance: 1, date: 1 });
45
45
  DefaultSchema.index({ client: 1, date: 1 });
46
46
  DefaultSchema.index({ date: 1 }, { expireAfterSeconds: 60 * 60 * 24 * 30 });
47
- exports.MonitorCPUs = index_1.ResolveIOServer.getMainDB().model('monitor-cpus', DefaultSchema);
48
- exports.MonitorCPUs['simplschema'] = new simpl_schema_1.default(schema);
49
- schema._id = {
50
- type: mongoose_1.Schema.Types.Mixed
51
- };
52
- var VersionSchema = new mongoose_1.Schema(schema, {
53
- skipVersioning: true,
54
- versionKey: false,
55
- timestamps: true
56
- });
57
- exports.MonitorCPUs['versionCollection'] = 'monitor-cpus.versions';
58
- exports.MonitorCPUVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorCPUs['versionCollection'], VersionSchema);
47
+ exports.MonitorCPUs = null;
48
+ exports.MonitorCPUVersions = null;
49
+ if (index_1.ResolveIOServer.getMainDB()) {
50
+ exports.MonitorCPUs = index_1.ResolveIOServer.getMainDB().model('monitor-cpus', DefaultSchema);
51
+ exports.MonitorCPUs['simplschema'] = new simpl_schema_1.default(schema);
52
+ schema._id = {
53
+ type: mongoose_1.Schema.Types.Mixed
54
+ };
55
+ var VersionSchema = new mongoose_1.Schema(schema, {
56
+ skipVersioning: true,
57
+ versionKey: false,
58
+ timestamps: true
59
+ });
60
+ exports.MonitorCPUs['versionCollection'] = 'monitor-cpus.versions';
61
+ exports.MonitorCPUVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorCPUs['versionCollection'], VersionSchema);
62
+ }
59
63
 
60
64
  //# sourceMappingURL=monitor-cpu.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/monitor-cpu.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAA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AAK;CACxB,CAAC;AAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACtC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,mBAAW,CAAC,mBAAmB,CAAC,GAAG,uBAAuB,CAAC;AAE9C,QAAA,kBAAkB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,mBAAW,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"monitor-cpu.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorCPUModel } from '../models/monitor-cpu.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tapp: {\n\t\ttype: Number\n\t},\n\tsystem: {\n\t\ttype: Number\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1});\nDefaultSchema.index({client: 1, date: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorCPUModel, Document {}\nexport const MonitorCPUs: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('monitor-cpus', DefaultSchema);\n\nMonitorCPUs['simplschema'] = new SimpleSchema(schema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nMonitorCPUs['versionCollection'] = 'monitor-cpus.versions';\n\nexport const MonitorCPUVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(MonitorCPUs['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/monitor-cpu.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;CACD,CAAC;AAEF,IAAM,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACxC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAC,CAAC,CAAC;AACvD,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAC,CAAC,CAAC;AAC1C,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAI7D,QAAA,WAAW,GAA0B,IAAI,CAAC;AAC1C,QAAA,kBAAkB,GAA0B,IAAI,CAAC;AAE5D,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,mBAAW,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,cAAc,EAAE,aAAa,CAAC,CAAC;IAE/E,mBAAW,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;IAEtD,MAAM,CAAC,GAAG,GAAG;QACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;QACtC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,mBAAW,CAAC,mBAAmB,CAAC,GAAG,uBAAuB,CAAC;IAE3D,0BAAkB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,mBAAW,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CACxG","file":"monitor-cpu.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorCPUModel } from '../models/monitor-cpu.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tapp: {\n\t\ttype: Number\n\t},\n\tsystem: {\n\t\ttype: Number\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1});\nDefaultSchema.index({client: 1, date: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorCPUModel, Document {}\n\nexport let MonitorCPUs: Model<ResolveIOModel> = null;\nexport let MonitorCPUVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tMonitorCPUs = ResolveIOServer.getMainDB().model('monitor-cpus', DefaultSchema);\n\n\tMonitorCPUs['simplschema'] = new SimpleSchema(schema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tMonitorCPUs['versionCollection'] = 'monitor-cpus.versions';\n\n\tMonitorCPUVersions = ResolveIOServer.getMainDB().model(MonitorCPUs['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { MonitorHTTPSInboundModel } from '../models/monitor-https-inbound.model';
3
3
  interface ResolveIOModel extends MonitorHTTPSInboundModel, Document {
4
4
  }
5
- export declare const MonitorHTTPSInbounds: Model<ResolveIOModel>;
6
- export declare const MonitorHTTPInboundVersions: Model<ResolveIOModel>;
5
+ export declare let MonitorHTTPSInbounds: Model<ResolveIOModel>;
6
+ export declare let MonitorHTTPInboundVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -54,17 +54,21 @@ DefaultSchema.index({ client: 1, instance: 1, date: 1, method: 1, url: 1 });
54
54
  DefaultSchema.index({ client: 1, date: 1, duration: 1 });
55
55
  DefaultSchema.index({ client: 1, date: 1, method: 1, url: 1 });
56
56
  DefaultSchema.index({ date: 1 }, { expireAfterSeconds: 60 * 60 * 24 * 30 });
57
- exports.MonitorHTTPSInbounds = index_1.ResolveIOServer.getMainDB().model('monitor-https-inbounds', DefaultSchema);
58
- exports.MonitorHTTPSInbounds['simplschema'] = new simpl_schema_1.default(schema);
59
- schema._id = {
60
- type: mongoose_1.Schema.Types.Mixed
61
- };
62
- var VersionSchema = new mongoose_1.Schema(schema, {
63
- skipVersioning: true,
64
- versionKey: false,
65
- timestamps: true
66
- });
67
- exports.MonitorHTTPSInbounds['versionCollection'] = 'monitor-https-inbounds.versions';
68
- exports.MonitorHTTPInboundVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorHTTPSInbounds['versionCollection'], VersionSchema);
57
+ exports.MonitorHTTPSInbounds = null;
58
+ exports.MonitorHTTPInboundVersions = null;
59
+ if (index_1.ResolveIOServer.getMainDB()) {
60
+ exports.MonitorHTTPSInbounds = index_1.ResolveIOServer.getMainDB().model('monitor-https-inbounds', DefaultSchema);
61
+ exports.MonitorHTTPSInbounds['simplschema'] = new simpl_schema_1.default(schema);
62
+ schema._id = {
63
+ type: mongoose_1.Schema.Types.Mixed
64
+ };
65
+ var VersionSchema = new mongoose_1.Schema(schema, {
66
+ skipVersioning: true,
67
+ versionKey: false,
68
+ timestamps: true
69
+ });
70
+ exports.MonitorHTTPSInbounds['versionCollection'] = 'monitor-https-inbounds.versions';
71
+ exports.MonitorHTTPInboundVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorHTTPSInbounds['versionCollection'], VersionSchema);
72
+ }
69
73
 
70
74
  //# sourceMappingURL=monitor-https-inbound.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/monitor-https-inbound.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM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AAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAG3D,QAAA,oBAAoB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,wBAAwB,EAAE,aAAa,CAAC,CAAC;AAEtI,4BAAoB,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;AAE/D,MAAM,CAAC,GAAG,GAAG;IACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;CACxB,CAAC;AAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACtC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,4BAAoB,CAAC,mBAAmB,CAAC,GAAG,iCAAiC,CAAC;AAEjE,QAAA,0BAA0B,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,4BAAoB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"monitor-https-inbound.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorHTTPSInboundModel } from '../models/monitor-https-inbound.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\turl: {\n\t\ttype: String\n\t},\n\tduration: {\n\t\ttype: Number\n\t},\n\tcontentType: {\n\t\ttype: String\n\t},\n\trequestHeader: {\n\t\ttype: String\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1, method: 1, url: 1});\nDefaultSchema.index({client: 1, date: 1, duration: 1});\nDefaultSchema.index({client: 1, date: 1, method: 1, url: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorHTTPSInboundModel, Document {}\nexport const MonitorHTTPSInbounds: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('monitor-https-inbounds', DefaultSchema);\n\nMonitorHTTPSInbounds['simplschema'] = new SimpleSchema(schema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nMonitorHTTPSInbounds['versionCollection'] = 'monitor-https-inbounds.versions';\n\nexport const MonitorHTTPInboundVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(MonitorHTTPSInbounds['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/monitor-https-inbound.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,QAAQ,EAAE;QACT,IAAI,EAAE,MAAM;KACZ;IACD,MAAM,EAAE;QACP,IAAI,EAAE,MAAM;KACZ;IACD,IAAI,EAAE;QACL,IAAI,EAAE,IAAI;KACV;IACD,MAAM,EAAE;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AC,MAAM,CAAC,CAAC;IAE/D,MAAM,CAAC,GAAG,GAAG;QACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;QACtC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,4BAAoB,CAAC,mBAAmB,CAAC,GAAG,iCAAiC,CAAC;IAE9E,kCAA0B,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,4BAAoB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CACzH","file":"monitor-https-inbound.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorHTTPSInboundModel } from '../models/monitor-https-inbound.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\turl: {\n\t\ttype: String\n\t},\n\tduration: {\n\t\ttype: Number\n\t},\n\tcontentType: {\n\t\ttype: String\n\t},\n\trequestHeader: {\n\t\ttype: String\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1, method: 1, url: 1});\nDefaultSchema.index({client: 1, date: 1, duration: 1});\nDefaultSchema.index({client: 1, date: 1, method: 1, url: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorHTTPSInboundModel, Document {}\n\nexport let MonitorHTTPSInbounds: Model<ResolveIOModel> = null;\nexport let MonitorHTTPInboundVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tMonitorHTTPSInbounds = ResolveIOServer.getMainDB().model('monitor-https-inbounds', DefaultSchema);\n\n\tMonitorHTTPSInbounds['simplschema'] = new SimpleSchema(schema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tMonitorHTTPSInbounds['versionCollection'] = 'monitor-https-inbounds.versions';\n\n\tMonitorHTTPInboundVersions = ResolveIOServer.getMainDB().model(MonitorHTTPSInbounds['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { MonitorHTTPSOutboundModel } from '../models/monitor-https-outbound.model';
3
3
  interface ResolveIOModel extends MonitorHTTPSOutboundModel, Document {
4
4
  }
5
- export declare const MonitorHTTPSOutbounds: Model<ResolveIOModel>;
6
- export declare const MonitorHTTPSOutboundVersions: Model<ResolveIOModel>;
5
+ export declare let MonitorHTTPSOutbounds: Model<ResolveIOModel>;
6
+ export declare let MonitorHTTPSOutboundVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -60,17 +60,21 @@ DefaultSchema.index({ client: 1, date: 1, method: 1, url: 1, status: 1 });
60
60
  DefaultSchema.index({ client: 1, date: 1, status: 1 });
61
61
  DefaultSchema.index({ client: 1, status: 1 });
62
62
  DefaultSchema.index({ date: 1 }, { expireAfterSeconds: 60 * 60 * 24 * 30 });
63
- exports.MonitorHTTPSOutbounds = index_1.ResolveIOServer.getMainDB().model('monitor-https-outbounds', DefaultSchema);
64
- exports.MonitorHTTPSOutbounds['simplschema'] = new simpl_schema_1.default(schema);
65
- schema._id = {
66
- type: mongoose_1.Schema.Types.Mixed
67
- };
68
- var VersionSchema = new mongoose_1.Schema(schema, {
69
- skipVersioning: true,
70
- versionKey: false,
71
- timestamps: true
72
- });
73
- exports.MonitorHTTPSOutbounds['versionCollection'] = 'monitor-https-outbounds.versions';
74
- exports.MonitorHTTPSOutboundVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorHTTPSOutbounds['versionCollection'], VersionSchema);
63
+ exports.MonitorHTTPSOutbounds = null;
64
+ exports.MonitorHTTPSOutboundVersions = null;
65
+ if (index_1.ResolveIOServer.getMainDB()) {
66
+ exports.MonitorHTTPSOutbounds = index_1.ResolveIOServer.getMainDB().model('monitor-https-outbounds', DefaultSchema);
67
+ exports.MonitorHTTPSOutbounds['simplschema'] = new simpl_schema_1.default(schema);
68
+ schema._id = {
69
+ type: mongoose_1.Schema.Types.Mixed
70
+ };
71
+ var VersionSchema = new mongoose_1.Schema(schema, {
72
+ skipVersioning: true,
73
+ versionKey: false,
74
+ timestamps: true
75
+ });
76
+ exports.MonitorHTTPSOutbounds['versionCollection'] = 'monitor-https-outbounds.versions';
77
+ exports.MonitorHTTPSOutboundVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorHTTPSOutbounds['versionCollection'], VersionSchema);
78
+ }
75
79
 
76
80
  //# sourceMappingURL=monitor-https-outbound.collection.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/collections/monitor-https-outbound.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACd;IACD,SAAS,EAAE;QACV,IAAI,EAAE,IAAI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rD,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAC,CAAC,CAAC;AAC5C,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAG3D,QAAA,qBAAqB,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,yBAAyB,EAAE,aAAa,CAAC,CAAC;AAExI,6BAAqB,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;AAEhE,MAAM,CAAC,GAAG,GAAG;IACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;CACxB,CAAC;AAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;IACtC,cAAc,EAAE,IAAI;IACpB,UAAU,EAAE,KAAK;IACjB,UAAU,EAAE,IAAI;CAChB,CAAC,CAAC;AAEH,6BAAqB,CAAC,mBAAmB,CAAC,GAAG,kCAAkC,CAAC;AAEnE,QAAA,4BAA4B,GAA0B,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,6BAAqB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC","file":"monitor-https-outbound.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorHTTPSOutboundModel } from '../models/monitor-https-outbound.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\turl: {\n\t\ttype: String\n\t},\n\tduration: {\n\t\ttype: Number\n\t},\n\tstatus: {\n\t\ttype: String\n\t},\n\tcontentType: {\n\t\ttype: String\n\t},\n\trequestHeaders: {\n\t\ttype: Object,\n\t\tblackbox: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1, method: 1, url: 1, status: 1});\nDefaultSchema.index({client: 1, date: 1, duration: 1});\nDefaultSchema.index({client: 1, date: 1, method: 1, url: 1, status: 1});\nDefaultSchema.index({client: 1, date: 1, status: 1});\nDefaultSchema.index({client: 1, status: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorHTTPSOutboundModel, Document {}\nexport const MonitorHTTPSOutbounds: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model('monitor-https-outbounds', DefaultSchema);\n\nMonitorHTTPSOutbounds['simplschema'] = new SimpleSchema(schema);\n\nschema._id = {\n\ttype: Schema.Types.Mixed\n};\n\nlet VersionSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nMonitorHTTPSOutbounds['versionCollection'] = 'monitor-https-outbounds.versions';\n\nexport const MonitorHTTPSOutboundVersions: Model<ResolveIOModel> = ResolveIOServer.getMainDB().model(MonitorHTTPSOutbounds['versionCollection'], VersionSchema);"]}
1
+ {"version":3,"sources":["../../src/collections/monitor-https-outbound.collection.ts"],"names":[],"mappings":";;AAAA,qCAAmD;AACnD,6CAAwC;AACxC,kCAA2C;AAG3C,IAAI,MAAM,GAAQ;IACjB,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACd;IACD,GAAG,EAAE;QACJ,IAAI,EAAE,MAAM;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C,CAAC,CAAC;AACxE,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAC,CAAC,CAAC;AACrD,aAAa,CAAC,KAAK,CAAC,EAAC,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAC,CAAC,CAAC;AAC5C,aAAa,CAAC,KAAK,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,EAAE,EAAC,kBAAkB,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAC,CAAC,CAAC;AAI7D,QAAA,qBAAqB,GAA0B,IAAI,CAAC;AACpD,QAAA,4BAA4B,GAA0B,IAAI,CAAC;AAEtE,IAAI,uBAAe,CAAC,SAAS,EAAE,EAAE;IAChC,6BAAqB,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,yBAAyB,EAAE,aAAa,CAAC,CAAC;IAEpG,6BAAqB,CAAC,aAAa,CAAC,GAAG,IAAI,sBAAY,CAAC,MAAM,CAAC,CAAC;IAEhE,MAAM,CAAC,GAAG,GAAG;QACZ,IAAI,EAAE,iBAAM,CAAC,KAAK,CAAC,KAAK;KACxB,CAAC;IAEF,IAAI,aAAa,GAAG,IAAI,iBAAM,CAAC,MAAM,EAAE;QACtC,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE,KAAK;QACjB,UAAU,EAAE,IAAI;KAChB,CAAC,CAAC;IAEH,6BAAqB,CAAC,mBAAmB,CAAC,GAAG,kCAAkC,CAAC;IAEhF,oCAA4B,GAAG,uBAAe,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,6BAAqB,CAAC,mBAAmB,CAAC,EAAE,aAAa,CAAC,CAAC;CAC5H","file":"monitor-https-outbound.collection.js","sourcesContent":["import { Schema, Model, Document } from 'mongoose';\nimport SimpleSchema from 'simpl-schema';\nimport { ResolveIOServer } from '../index';\nimport { MonitorHTTPSOutboundModel } from '../models/monitor-https-outbound.model';\n\nlet schema: any = {\n\t_id: {\n\t\ttype: String,\n\t\toptional: true\n\t},\n\t__v: {\n\t\ttype: Number,\n\t\toptional: true\n\t},\n\tupdatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tcreatedAt: {\n\t\ttype: Date,\n\t\toptional: true\n\t},\n\tinstance: {\n\t\ttype: String\n\t},\n\tclient: {\n\t\ttype: String\n\t},\n\tdate: {\n\t\ttype: Date\n\t},\n\tmethod: {\n\t\ttype: String\n\t},\n\turl: {\n\t\ttype: String\n\t},\n\tduration: {\n\t\ttype: Number\n\t},\n\tstatus: {\n\t\ttype: String\n\t},\n\tcontentType: {\n\t\ttype: String\n\t},\n\trequestHeaders: {\n\t\ttype: Object,\n\t\tblackbox: true\n\t}\n};\n\nconst DefaultSchema = new Schema(schema, {\n\tskipVersioning: true,\n\tversionKey: false,\n\ttimestamps: true\n});\n\nDefaultSchema.index({client: 1, instance: 1, date: 1, method: 1, url: 1, status: 1});\nDefaultSchema.index({client: 1, date: 1, duration: 1});\nDefaultSchema.index({client: 1, date: 1, method: 1, url: 1, status: 1});\nDefaultSchema.index({client: 1, date: 1, status: 1});\nDefaultSchema.index({client: 1, status: 1});\nDefaultSchema.index({date: 1}, {expireAfterSeconds: 60 * 60 * 24 * 30});\n\ninterface ResolveIOModel extends MonitorHTTPSOutboundModel, Document {}\n\nexport let MonitorHTTPSOutbounds: Model<ResolveIOModel> = null;\nexport let MonitorHTTPSOutboundVersions: Model<ResolveIOModel> = null;\n\nif (ResolveIOServer.getMainDB()) {\n\tMonitorHTTPSOutbounds = ResolveIOServer.getMainDB().model('monitor-https-outbounds', DefaultSchema);\n\n\tMonitorHTTPSOutbounds['simplschema'] = new SimpleSchema(schema);\n\n\tschema._id = {\n\t\ttype: Schema.Types.Mixed\n\t};\n\n\tlet VersionSchema = new Schema(schema, {\n\t\tskipVersioning: true,\n\t\tversionKey: false,\n\t\ttimestamps: true\n\t});\n\n\tMonitorHTTPSOutbounds['versionCollection'] = 'monitor-https-outbounds.versions';\n\n\tMonitorHTTPSOutboundVersions = ResolveIOServer.getMainDB().model(MonitorHTTPSOutbounds['versionCollection'], VersionSchema);\n}"]}
@@ -2,6 +2,6 @@ import { Model, Document } from 'mongoose';
2
2
  import { MonitorMemoryModel } from '../models/monitor-memory.model';
3
3
  interface ResolveIOModel extends MonitorMemoryModel, Document {
4
4
  }
5
- export declare const MonitorMemorys: Model<ResolveIOModel>;
6
- export declare const MonitorMemoryVersions: Model<ResolveIOModel>;
5
+ export declare let MonitorMemorys: Model<ResolveIOModel>;
6
+ export declare let MonitorMemoryVersions: Model<ResolveIOModel>;
7
7
  export {};
@@ -56,17 +56,21 @@ var DefaultSchema = new mongoose_1.Schema(schema, {
56
56
  DefaultSchema.index({ client: 1, instance: 1, date: 1 });
57
57
  DefaultSchema.index({ client: 1, date: 1 });
58
58
  DefaultSchema.index({ date: 1 }, { expireAfterSeconds: 60 * 60 * 24 * 30 });
59
- exports.MonitorMemorys = index_1.ResolveIOServer.getMainDB().model('monitor-memorys', DefaultSchema);
60
- exports.MonitorMemorys['simplschema'] = new simpl_schema_1.default(schema);
61
- schema._id = {
62
- type: mongoose_1.Schema.Types.Mixed
63
- };
64
- var VersionSchema = new mongoose_1.Schema(schema, {
65
- skipVersioning: true,
66
- versionKey: false,
67
- timestamps: true
68
- });
69
- exports.MonitorMemorys['versionCollection'] = 'monitor-memorys.versions';
70
- exports.MonitorMemoryVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorMemorys['versionCollection'], VersionSchema);
59
+ exports.MonitorMemorys = null;
60
+ exports.MonitorMemoryVersions = null;
61
+ if (index_1.ResolveIOServer.getMainDB()) {
62
+ exports.MonitorMemorys = index_1.ResolveIOServer.getMainDB().model('monitor-memorys', DefaultSchema);
63
+ exports.MonitorMemorys['simplschema'] = new simpl_schema_1.default(schema);
64
+ schema._id = {
65
+ type: mongoose_1.Schema.Types.Mixed
66
+ };
67
+ var VersionSchema = new mongoose_1.Schema(schema, {
68
+ skipVersioning: true,
69
+ versionKey: false,
70
+ timestamps: true
71
+ });
72
+ exports.MonitorMemorys['versionCollection'] = 'monitor-memorys.versions';
73
+ exports.MonitorMemoryVersions = index_1.ResolveIOServer.getMainDB().model(exports.MonitorMemorys['versionCollection'], VersionSchema);
74
+ }
71
75
 
72
76
  //# sourceMappingURL=monitor-memory.collection.js.map