@hitchy/plugin-odem-socket.io 0.2.0 → 0.2.1
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.
|
@@ -78,7 +78,7 @@ module.exports = function() {
|
|
|
78
78
|
io.on( "connection", socket => {
|
|
79
79
|
socket
|
|
80
80
|
.on( `${prefix}:list`, async( sessionId, queryOptions, loadRecords, response ) => {
|
|
81
|
-
|
|
81
|
+
logDebug( "request for listing %s instances w/ queryOptions %j and loadRecords %j", modelName, queryOptions, Boolean( loadRecords ) );
|
|
82
82
|
|
|
83
83
|
try {
|
|
84
84
|
const meta = {};
|
|
@@ -98,7 +98,7 @@ module.exports = function() {
|
|
|
98
98
|
}
|
|
99
99
|
} )
|
|
100
100
|
.on( `${prefix}:find`, async( sessionId, query, queryOptions, loadRecords, response ) => {
|
|
101
|
-
|
|
101
|
+
logDebug( "request for finding %s instances matching %j w/ queryOptions %j and uuidsOnly %j", modelName, query, queryOptions, Boolean( loadRecords ) );
|
|
102
102
|
|
|
103
103
|
try {
|
|
104
104
|
const meta = {};
|
|
@@ -118,7 +118,7 @@ module.exports = function() {
|
|
|
118
118
|
}
|
|
119
119
|
} )
|
|
120
120
|
.on( `${prefix}:create`, async( sessionId, properties, response ) => {
|
|
121
|
-
|
|
121
|
+
logDebug( "request for creating %s instance with %j", modelName, properties );
|
|
122
122
|
|
|
123
123
|
try {
|
|
124
124
|
const schema = model.schema;
|
|
@@ -146,7 +146,7 @@ module.exports = function() {
|
|
|
146
146
|
}
|
|
147
147
|
} )
|
|
148
148
|
.on( `${prefix}:read`, async( sessionId, uuid, response ) => {
|
|
149
|
-
|
|
149
|
+
logDebug( "request for reading %s instance %s", modelName, uuid );
|
|
150
150
|
|
|
151
151
|
try {
|
|
152
152
|
const instance = new model( uuid ); // eslint-disable-line new-cap
|
|
@@ -165,7 +165,7 @@ module.exports = function() {
|
|
|
165
165
|
}
|
|
166
166
|
} )
|
|
167
167
|
.on( `${prefix}:update`, async( sessionId, uuid, properties, response ) => {
|
|
168
|
-
|
|
168
|
+
logDebug( "request for updating %s instance %s with %j", modelName, uuid, properties );
|
|
169
169
|
|
|
170
170
|
try {
|
|
171
171
|
const instance = new model( uuid ); // eslint-disable-line new-cap
|
|
@@ -192,7 +192,7 @@ module.exports = function() {
|
|
|
192
192
|
}
|
|
193
193
|
} )
|
|
194
194
|
.on( `${prefix}:delete`, async( sessionId, uuid, response ) => {
|
|
195
|
-
|
|
195
|
+
logDebug( "request for deleting %s instance %s", modelName, uuid );
|
|
196
196
|
|
|
197
197
|
try {
|
|
198
198
|
const instance = new model( uuid ); // eslint-disable-line new-cap
|