コード例 #1
0
    protected function publish()
    {
        $publisher = MMSynchContentPublisher::getInstance();
        $publisher->publish( $this->content );

        MMSynchMonitor::inc(MMSynchMonitor::SUCCESS . ' . ' . $this->content->getRawContentObject()->contentClassIdentifier());
    }
コード例 #2
0
ファイル: db.php プロジェクト: sushilbshinde/ezpublish-study
    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;
    }
コード例 #3
0
    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);
    }
コード例 #4
0
 public function __construct ($message = "", $code = 0, $previous = null)
 {
     parent::__construct($message, $code, $previous);
     MMSynchMonitor::inc(MMSynchMonitor::EXCEPTION);
 }