@@ -159,6 +159,10 @@ func main() {
159
159
continue
160
160
}
161
161
162
+ if com .AmqpDebug {
163
+ log .Printf ("Running BACKUP on '%s/%s'" , req .DBOwner , req .DBName )
164
+ }
165
+
162
166
// Return a success message to the caller
163
167
resp := com.LiveDBErrorResponse {Node : com .Conf .Live .Nodename , Error : "" } // Use an empty error message to indicate success
164
168
err = com .MQResponse ("BACKUP" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -180,6 +184,10 @@ func main() {
180
184
continue
181
185
}
182
186
187
+ if com .AmqpDebug {
188
+ log .Printf ("Running COLUMNS on '%s/%s': '%s'" , req .DBOwner , req .DBName , req .Data )
189
+ }
190
+
183
191
// Return the columns list to the caller
184
192
resp := com.LiveDBColumnsResponse {Node : com .Conf .Live .Nodename , Columns : columns , Error : "" , ErrCode : com .AMQPNoError }
185
193
err = com .MQResponse ("COLUMNS" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -200,6 +208,10 @@ func main() {
200
208
continue
201
209
}
202
210
211
+ if com .AmqpDebug {
212
+ log .Printf ("Running DELETE on '%s/%s'" , req .DBOwner , req .DBName )
213
+ }
214
+
203
215
// Return a success message (empty string in this case) to the caller
204
216
resp := com.LiveDBErrorResponse {Node : com .Conf .Live .Nodename , Error : "" }
205
217
err = com .MQResponse ("DELETE" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -221,6 +233,10 @@ func main() {
221
233
continue
222
234
}
223
235
236
+ if com .AmqpDebug {
237
+ log .Printf ("Running EXECUTE on '%s/%s': '%s'" , req .DBOwner , req .DBName , req .Data )
238
+ }
239
+
224
240
// Return a success message to the caller
225
241
resp := com.LiveDBExecuteResponse {Node : com .Conf .Live .Nodename , RowsChanged : rowsChanged , Error : "" }
226
242
err = com .MQResponse ("EXECUTE" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -241,6 +257,10 @@ func main() {
241
257
continue
242
258
}
243
259
260
+ if com .AmqpDebug {
261
+ log .Printf ("Running INDEXES on '%s/%s'" , req .DBOwner , req .DBName )
262
+ }
263
+
244
264
// Return the indexes list to the caller
245
265
resp := com.LiveDBIndexesResponse {Node : com .Conf .Live .Nodename , Indexes : indexes , Error : "" }
246
266
err = com .MQResponse ("INDEXES" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -261,6 +281,10 @@ func main() {
261
281
continue
262
282
}
263
283
284
+ if com .AmqpDebug {
285
+ log .Printf ("Running QUERY on '%s/%s': '%s'" , req .DBOwner , req .DBName , req .Data )
286
+ }
287
+
264
288
// Return the query response to the caller
265
289
resp := com.LiveDBQueryResponse {Node : com .Conf .Live .Nodename , Results : rows , Error : "" }
266
290
err = com .MQResponse ("QUERY" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -294,6 +318,10 @@ func main() {
294
318
continue
295
319
}
296
320
321
+ if com .AmqpDebug {
322
+ log .Printf ("Running ROWDATA on '%s/%s'" , req .DBOwner , req .DBName )
323
+ }
324
+
297
325
// Return the row data to the caller
298
326
err = com .MQResponse ("ROWDATA" , msg , ch , com .Conf .Live .Nodename , resp )
299
327
if err != nil {
@@ -313,6 +341,10 @@ func main() {
313
341
continue
314
342
}
315
343
344
+ if com .AmqpDebug {
345
+ log .Printf ("Running TABLES on '%s/%s'" , req .DBOwner , req .DBName )
346
+ }
347
+
316
348
// Return the tables list to the caller
317
349
resp := com.LiveDBTablesResponse {Node : com .Conf .Live .Nodename , Tables : tables , Error : "" }
318
350
err = com .MQResponse ("TABLES" , msg , ch , com .Conf .Live .Nodename , resp )
@@ -333,6 +365,10 @@ func main() {
333
365
continue
334
366
}
335
367
368
+ if com .AmqpDebug {
369
+ log .Printf ("Running VIEWS on '%s/%s'" , req .DBOwner , req .DBName )
370
+ }
371
+
336
372
// Return the views list to the caller
337
373
resp := com.LiveDBViewsResponse {Node : com .Conf .Live .Nodename , Views : views , Error : "" }
338
374
err = com .MQResponse ("VIEWS" , msg , ch , com .Conf .Live .Nodename , resp )
0 commit comments