Compare commits
3 Commits
47321834ac
...
f912e81ee6
Author | SHA1 | Date | |
---|---|---|---|
f912e81ee6 | |||
4fe5dc6ad0 | |||
556b95c7c1 |
@ -128,10 +128,10 @@ class Receive extends Base
|
|||||||
// If packet is greater than a size, lets queue it
|
// If packet is greater than a size, lets queue it
|
||||||
if ($this->queue || ($this->receiving->size > config('fido.queue_size',0))) {
|
if ($this->queue || ($this->receiving->size > config('fido.queue_size',0))) {
|
||||||
Log::info(sprintf('%s:- Packet [%s] will be sent to the queue for processing because its [%d] size, or queue forced',self::LOGKEY,$this->receiving->full_name,$this->receiving->size));
|
Log::info(sprintf('%s:- Packet [%s] will be sent to the queue for processing because its [%d] size, or queue forced',self::LOGKEY,$this->receiving->full_name,$this->receiving->size));
|
||||||
PacketProcess::dispatch($this->receiving,$this->ao,$rcvd_time);
|
PacketProcess::dispatch($this->receiving,$this->ao->withoutRelations(),$rcvd_time);
|
||||||
|
|
||||||
} else
|
} else
|
||||||
PacketProcess::dispatchSync($this->receiving,$this->ao,$rcvd_time);
|
PacketProcess::dispatchSync($this->receiving,$this->ao->withoutRelations(),$rcvd_time);
|
||||||
|
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
Log::error(sprintf('%s:! Got error dispatching packet [%s] (%d:%s-%s).',self::LOGKEY,$this->receiving->full_name,$e->getLine(),$e->getFile(),$e->getMessage()));
|
Log::error(sprintf('%s:! Got error dispatching packet [%s] (%d:%s-%s).',self::LOGKEY,$this->receiving->full_name,$e->getLine(),$e->getFile(),$e->getMessage()));
|
||||||
|
@ -92,7 +92,7 @@ class Node
|
|||||||
|
|
||||||
// Return how long our session has been connected
|
// Return how long our session has been connected
|
||||||
case 'session_time':
|
case 'session_time':
|
||||||
return sprintf("%d",Carbon::now()->diffInSeconds($this->start_time));
|
return sprintf("%d",$this->start_time->diffInSeconds(Carbon::now()));
|
||||||
|
|
||||||
case 'system':
|
case 'system':
|
||||||
case 'sysop':
|
case 'sysop':
|
||||||
|
@ -111,9 +111,9 @@ class PacketProcess implements ShouldQueue
|
|||||||
try {
|
try {
|
||||||
// Dispatch job.
|
// Dispatch job.
|
||||||
if ($queue)
|
if ($queue)
|
||||||
MessageProcess::dispatch($msg,$f->pktName(),$this->ao,$pkt->fftn_o,$this->rcvd_time);
|
MessageProcess::dispatch($msg,$f->pktName(),$this->ao->withoutRelations(),$pkt->fftn_o->withoutRelations(),$this->rcvd_time);
|
||||||
else
|
else
|
||||||
MessageProcess::dispatchSync($msg,$f->pktName(),$this->ao,$pkt->fftn_o,$this->rcvd_time);
|
MessageProcess::dispatchSync($msg,$f->pktName(),$this->ao->withoutRelations(),$pkt->fftn_o->withoutRelations(),$this->rcvd_time);
|
||||||
|
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
Log::error(sprintf('%s:! Got error dispatching message [%s] (%d:%s-%s).',self::LOGKEY,$msg->msgid,$e->getLine(),$e->getFile(),$e->getMessage()));
|
Log::error(sprintf('%s:! Got error dispatching message [%s] (%d:%s-%s).',self::LOGKEY,$msg->msgid,$e->getLine(),$e->getFile(),$e->getMessage()));
|
||||||
@ -132,7 +132,7 @@ class PacketProcess implements ShouldQueue
|
|||||||
} else {
|
} else {
|
||||||
// If we want to keep the packet, we could do that logic here
|
// If we want to keep the packet, we could do that logic here
|
||||||
if (config('fido.packet_keep')) {
|
if (config('fido.packet_keep')) {
|
||||||
$dir = sprintf('%s/%s',config('fido.dir'),Carbon::now()->format('Ymd'));
|
$dir = sprintf('%s/%s/%s/%s',config('fido.dir'),($x=Carbon::now())->format('Y'),$x->format('m'),$x->format('d'));
|
||||||
Log::debug(sprintf('%s:- Moving processed packet [%s] to [%s]',self::LOGKEY,$this->file->rel_name,$dir));
|
Log::debug(sprintf('%s:- Moving processed packet [%s] to [%s]',self::LOGKEY,$this->file->rel_name,$dir));
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
Loading…
Reference in New Issue
Block a user