Built motion from commit d5e4af8c.|2.6.23
[motion2.git] / server / api / userVoiceQueueRt / userVoiceQueueRt.rpc.js
index 054634b..9b2f014 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x49cb=['randomstring','../../mysqldb','../../config/utils','../../config/logger','../../config/environment','jayson/promise','client','redis','localhost','./userVoiceQueueRt.socket','register','request','info','UserVoiceQueueRt,\x20%s,\x20%s','request\x20sent','debug','UserVoiceQueueRt,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','catch','GetVoiceQueueRtPauses','UserVoiceQueueRt','findAll','options','raw','where','sequelize','COUNT','literal','`paused`\x20=\x201,\x201,\x20null','outboundQueuePauses','then','lodash','util','moment','bluebird'];(function(_0x5c14f6,_0x2979d8){var _0x4949b3=function(_0xcc4206){while(--_0xcc4206){_0x5c14f6['push'](_0x5c14f6['shift']());}};_0x4949b3(++_0x2979d8);}(_0x49cb,0xbf));var _0xb49c=function(_0x3824fb,_0x377639){_0x3824fb=_0x3824fb-0x0;var _0x453fc5=_0x49cb[_0x3824fb];return _0x453fc5;};'use strict';var _=require(_0xb49c('0x0'));var util=require(_0xb49c('0x1'));var moment=require(_0xb49c('0x2'));var BPromise=require(_0xb49c('0x3'));var rs=require(_0xb49c('0x4'));var fs=require('fs');var Redis=require('ioredis');var db=require(_0xb49c('0x5'))['db'];var utils=require(_0xb49c('0x6'));var logger=require(_0xb49c('0x7'))('rpc');var config=require(_0xb49c('0x8'));var jayson=require(_0xb49c('0x9'));var client=jayson[_0xb49c('0xa')]['http']({'port':0x232a});config[_0xb49c('0xb')]=_['defaults'](config['redis'],{'host':_0xb49c('0xc'),'port':0x18eb});var socket=require('socket.io-emitter')(new Redis(config[_0xb49c('0xb')]));require(_0xb49c('0xd'))[_0xb49c('0xe')](socket);function respondWithRpcPromise(_0x1dbdbf,_0x2be370,_0x29835f){return new BPromise(function(_0x5b75c8,_0x216ded){return client[_0xb49c('0xf')](_0x1dbdbf,_0x29835f)['then'](function(_0x1c4f4a){logger[_0xb49c('0x10')](_0xb49c('0x11'),_0x2be370,_0xb49c('0x12'));logger[_0xb49c('0x13')](_0xb49c('0x14'),_0x2be370,'request\x20sent',JSON[_0xb49c('0x15')](_0x1c4f4a));if(_0x1c4f4a[_0xb49c('0x16')]){if(_0x1c4f4a['error'][_0xb49c('0x17')]===0x1f4){logger[_0xb49c('0x16')]('UserVoiceQueueRt,\x20%s,\x20%s',_0x2be370,_0x1c4f4a[_0xb49c('0x16')][_0xb49c('0x18')]);return _0x216ded(_0x1c4f4a[_0xb49c('0x16')][_0xb49c('0x18')]);}logger['error']('UserVoiceQueueRt,\x20%s,\x20%s',_0x2be370,_0x1c4f4a[_0xb49c('0x16')][_0xb49c('0x18')]);return _0x5b75c8(_0x1c4f4a['error'][_0xb49c('0x18')]);}else{logger[_0xb49c('0x10')]('UserVoiceQueueRt,\x20%s,\x20%s',_0x2be370,_0xb49c('0x12'));_0x5b75c8(_0x1c4f4a[_0xb49c('0x19')][_0xb49c('0x18')]);}})[_0xb49c('0x1a')](function(_0x35a46b){logger['error'](_0xb49c('0x11'),_0x2be370,_0x35a46b);_0x216ded(_0x35a46b);});});}exports[_0xb49c('0x1b')]=function(_0xdbb20a){var _0x3385a5=this;return new Promise(function(_0x31be70,_0xdcde0f){return db[_0xb49c('0x1c')][_0xb49c('0x1d')]({'raw':_0xdbb20a[_0xb49c('0x1e')]?_0xdbb20a[_0xb49c('0x1e')][_0xb49c('0x1f')]===undefined?!![]:![]:!![],'where':_0xdbb20a[_0xb49c('0x1e')]?_0xdbb20a[_0xb49c('0x1e')][_0xb49c('0x20')]||null:null,'attributes':[[db[_0xb49c('0x21')]['fn'](_0xb49c('0x22'),db[_0xb49c('0x21')]['fn']('IF',db['sequelize'][_0xb49c('0x23')](_0xb49c('0x24')))),_0xb49c('0x25')]]})[_0xb49c('0x26')](function(_0x27144d){logger[_0xb49c('0x10')](_0xb49c('0x1b'),_0xdbb20a);logger['debug'](_0xb49c('0x1b'),_0xdbb20a,JSON['stringify'](_0x27144d));_0x31be70(_0x27144d);})[_0xb49c('0x1a')](function(_0x238f83){logger[_0xb49c('0x16')](_0xb49c('0x1b'),_0x238f83[_0xb49c('0x18')],_0xdbb20a);_0xdcde0f(_0x3385a5[_0xb49c('0x16')](0x1f4,_0x238f83[_0xb49c('0x18')]));});});};
\ No newline at end of file
+var _0x5c46=['debug','UserVoiceQueueRt,\x20%s,\x20%s,\x20%s','error','code','message','result','catch','GetVoiceQueueRtPauses','UserVoiceQueueRt','findAll','options','raw','where','sequelize','literal','outboundQueuePauses','lodash','util','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','http','redis','defaults','localhost','socket.io-emitter','./userVoiceQueueRt.socket','request','then','info','UserVoiceQueueRt,\x20%s,\x20%s','request\x20sent'];(function(_0x2ffab6,_0x4fa24a){var _0x3ed205=function(_0x13a320){while(--_0x13a320){_0x2ffab6['push'](_0x2ffab6['shift']());}};_0x3ed205(++_0x4fa24a);}(_0x5c46,0x166));var _0x65c4=function(_0x122ef9,_0x451d2a){_0x122ef9=_0x122ef9-0x0;var _0x42fba0=_0x5c46[_0x122ef9];return _0x42fba0;};'use strict';var _=require(_0x65c4('0x0'));var util=require(_0x65c4('0x1'));var moment=require(_0x65c4('0x2'));var BPromise=require('bluebird');var rs=require(_0x65c4('0x3'));var fs=require('fs');var Redis=require(_0x65c4('0x4'));var db=require(_0x65c4('0x5'))['db'];var utils=require(_0x65c4('0x6'));var logger=require(_0x65c4('0x7'))(_0x65c4('0x8'));var config=require(_0x65c4('0x9'));var jayson=require(_0x65c4('0xa'));var client=jayson['client'][_0x65c4('0xb')]({'port':0x232a});config[_0x65c4('0xc')]=_[_0x65c4('0xd')](config[_0x65c4('0xc')],{'host':_0x65c4('0xe'),'port':0x18eb});var socket=require(_0x65c4('0xf'))(new Redis(config[_0x65c4('0xc')]));require(_0x65c4('0x10'))['register'](socket);function respondWithRpcPromise(_0x3e7025,_0x57f69d,_0x4b73ef){return new BPromise(function(_0x18c4ac,_0x287a83){return client[_0x65c4('0x11')](_0x3e7025,_0x4b73ef)[_0x65c4('0x12')](function(_0x43f055){logger[_0x65c4('0x13')](_0x65c4('0x14'),_0x57f69d,_0x65c4('0x15'));logger[_0x65c4('0x16')](_0x65c4('0x17'),_0x57f69d,_0x65c4('0x15'),JSON['stringify'](_0x43f055));if(_0x43f055[_0x65c4('0x18')]){if(_0x43f055['error'][_0x65c4('0x19')]===0x1f4){logger[_0x65c4('0x18')](_0x65c4('0x14'),_0x57f69d,_0x43f055[_0x65c4('0x18')][_0x65c4('0x1a')]);return _0x287a83(_0x43f055[_0x65c4('0x18')][_0x65c4('0x1a')]);}logger[_0x65c4('0x18')](_0x65c4('0x14'),_0x57f69d,_0x43f055[_0x65c4('0x18')][_0x65c4('0x1a')]);return _0x18c4ac(_0x43f055['error'][_0x65c4('0x1a')]);}else{logger['info']('UserVoiceQueueRt,\x20%s,\x20%s',_0x57f69d,_0x65c4('0x15'));_0x18c4ac(_0x43f055[_0x65c4('0x1b')]['message']);}})[_0x65c4('0x1c')](function(_0x37abe3){logger[_0x65c4('0x18')]('UserVoiceQueueRt,\x20%s,\x20%s',_0x57f69d,_0x37abe3);_0x287a83(_0x37abe3);});});}exports[_0x65c4('0x1d')]=function(_0xdc86ac){var _0x309702=this;return new Promise(function(_0x4e2723,_0x25125e){return db[_0x65c4('0x1e')][_0x65c4('0x1f')]({'raw':_0xdc86ac['options']?_0xdc86ac[_0x65c4('0x20')][_0x65c4('0x21')]===undefined?!![]:![]:!![],'where':_0xdc86ac[_0x65c4('0x20')]?_0xdc86ac['options'][_0x65c4('0x22')]||null:null,'attributes':[[db[_0x65c4('0x23')]['fn']('COUNT',db['sequelize']['fn']('IF',db['sequelize'][_0x65c4('0x24')]('`paused`\x20=\x201,\x201,\x20null'))),_0x65c4('0x25')]]})[_0x65c4('0x12')](function(_0x304e9e){logger[_0x65c4('0x13')](_0x65c4('0x1d'),_0xdc86ac);logger['debug'](_0x65c4('0x1d'),_0xdc86ac,JSON['stringify'](_0x304e9e));_0x4e2723(_0x304e9e);})[_0x65c4('0x1c')](function(_0x361007){logger[_0x65c4('0x18')](_0x65c4('0x1d'),_0x361007['message'],_0xdc86ac);_0x25125e(_0x309702[_0x65c4('0x18')](0x1f4,_0x361007[_0x65c4('0x1a')]));});});};
\ No newline at end of file