]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
dbqueuemanager should ignore on no-result-exceptions
authorMikael Nordfeldth <mmn@hethane.se>
Tue, 16 Aug 2016 18:27:41 +0000 (20:27 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Tue, 16 Aug 2016 18:27:41 +0000 (20:27 +0200)
lib/dbqueuemanager.php

index 4440a4d93060f826c0a6f8559e2bda4edc3d2f4a..6a2952c28f7313ce505d643112b366a4da12d5ff 100644 (file)
@@ -95,11 +95,14 @@ class DBQueueManager extends QueueManager
         } catch (NoQueueHandlerException $e) {
             $this->noHandlerFound($qi, $rep);
             return true;
+        } catch (NoResultException $e) {
+            $this->_log(LOG_ERR, "[{$qi->transport}:$rep] ".get_class($e).' thrown ('._ve($e->getMessage()).'), ignoring queue_item '._ve($qi->getID()));
+            $result = true;
         } catch (AlreadyFulfilledException $e) {
-            $this->_log(LOG_ERR, "[{$qi->transport}:$rep] AlreadyFulfilledException thrown: {$e->getMessage()}");
+            $this->_log(LOG_ERR, "[{$qi->transport}:$rep] ".get_class($e).' thrown ('._ve($e->getMessage()).'), ignoring queue_item '._ve($qi->getID()));
             $result = true;
         } catch (Exception $e) {
-            $this->_log(LOG_ERR, "[{$qi->transport}:$rep] Exception thrown: {$e->getMessage()}");
+            $this->_log(LOG_ERR, "[{$qi->transport}:$rep] Exception (".get_class($e).') thrown: '._ve($e->getMessage()));
             $result = false;
         }