commit
1004131333
1
NEWS.md
1
NEWS.md
@ -3,6 +3,7 @@
|
||||
|
||||
Announcements:
|
||||
* limited batch queries to 12 hours
|
||||
* Multiple queries jobs pushed as first job between queries.
|
||||
|
||||
|
||||
1.37.1 - 2016-10-05
|
||||
|
@ -82,7 +82,7 @@ JobRunner.prototype._run = function (job, query, profiler, callback) {
|
||||
return callback(null, job);
|
||||
}
|
||||
|
||||
self.jobQueue.enqueue(job.data.job_id, job.data.host, function (err) {
|
||||
self.jobQueue.enqueueFirst(job.data.job_id, job.data.host, function (err) {
|
||||
if (err) {
|
||||
return callback(err);
|
||||
}
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
var PSQL = require('cartodb-psql');
|
||||
var BATCH_QUERY_TIMEOUT = global.settings.batch_query_timeout || 12 * 3600 * 1000; // 12 hours in millisecond
|
||||
var debug = require('./util/debug')('query-runner');
|
||||
|
||||
function QueryRunner(userDatabaseMetadataService) {
|
||||
this.userDatabaseMetadataService = userDatabaseMetadataService;
|
||||
@ -25,6 +26,7 @@ QueryRunner.prototype.run = function (job_id, sql, user, callback) {
|
||||
// mark query to allow to users cancel their queries
|
||||
sql = '/* ' + job_id + ' */ ' + sql;
|
||||
|
||||
debug('Running query %s', sql);
|
||||
pg.eventedQuery(sql, function (err, query) {
|
||||
if (err) {
|
||||
return callback(err);
|
||||
|
Loading…
Reference in New Issue
Block a user