我已經通過終端運行phirehose的示例腳本,並看到了我的測試推文的實時/活動ptint_r。我已經加載了貧民窟隊列文件,並且他們以極其成功的方式執行了他們的日誌記錄。但我似乎無法找到數據的去向。它實際上在寫什麼文件?這兩個示例文件ghetto-queue-collect.php
和ghetto-queue-consume.php
使我相信它是/tmp
相對於腳本執行的目錄,但我什麼都看不到。有什麼建議麼?這些文件在哪裏?通過phirehose Twtitter userstream
下面是一些線從日誌
[03-Mar-2014 02:44:43 America/New_York] Phirehose: Opening new active status stream: /tmp/.phirehose-ghettoqueue.current
[03-Mar-2014 02:45:12 America/New_York] Phirehose: Successfully rotated active stream to queue file: /tmp/phirehose-ghettoqueue.20140303-024512.queue
-----和------
[03-Mar-2014 03:41:58 America/New_York] Processing file: /tmp/phirehose-ghettoqueue.20140303-024102.queue
[03-Mar-2014 03:41:59 America/New_York] Successfully processed 1 tweets from /tmp/phirehose-ghettoqueue.20140303-024102.queue - deleting.
- 的代碼有問題的位,我認爲 -
/**
* Subclass specific constants
*/
const QUEUE_FILE_PREFIX = 'phirehose-ghettoqueue';
const QUEUE_FILE_ACTIVE = '.phirehose-ghettoqueue.current';
public function __construct($username, $password, $queueDir = '/tmp', $rotateInterval = 10)
// Set subclass parameters
$this->queueDir = $queueDir;
// Construct stream file name, log and open
$this->streamFile = $this->queueDir . '/' . self::QUEUE_FILE_ACTIVE;
$this->log('Opening new active status stream: ' . $this->streamFile);
$this->statusStream = fopen($this->streamFile, 'a'); // Append if present (crash recovery)
我剛剛在他的github問題頁面上引用了這篇文章。我們將看看接下來會發生什麼。儘管這很令人沮喪。我所知道的任何事情都不會產生任何效果 – Qwiso