protected function publish() { $publisher = MMSynchContentPublisher::getInstance(); $publisher->publish( $this->content ); MMSynchMonitor::inc(MMSynchMonitor::SUCCESS . ' . ' . $this->content->getRawContentObject()->contentClassIdentifier()); }
public function query( $sql, $server = false ) { MMSynchMonitor::inc(MMSynchMonitor::QUERY); $result = $this->connector->query($sql, $server); if ($this->connector->ErrorMessage) { throw new MMSynchException('Database error : ' . $this->connector->ErrorMessage); } return $result; }
public static function exception($object, $exception, $section = false) { if (self::ERROR <= self::$level) { $msg = sprintf('[Exception] %s on line %s in %s', $exception->getMessage(), $exception->getLine(), $exception->getFile()); eZLog::write(self::parse($object, $msg, $section) . '\n' . $exception->getTraceAsString(), self::$logname); if (self::$cli) { self::$cli->error(self::parse($object, $msg, $section)); } MMSynchMonitor::inc(MMSynchMonitor::EXCEPTION); } self::startSection($section); }
public function __construct ($message = "", $code = 0, $previous = null) { parent::__construct($message, $code, $previous); MMSynchMonitor::inc(MMSynchMonitor::EXCEPTION); }