CC-5709: Airtime Analyzer

* Renamed a function in MediaController for clarity
* Updated airtime_analyzer README
This commit is contained in:
Albert Santoni 2014-03-13 12:12:12 -04:00
parent e6cbbdff33
commit f4ea417b83
2 changed files with 3 additions and 4 deletions

View File

@ -66,7 +66,7 @@ class Rest_MediaController extends Zend_Rest_Controller
return; return;
} }
$this->processUpload(); $this->processUploadedFile();
//TODO: Strip or sanitize the JSON output //TODO: Strip or sanitize the JSON output
$file = new CcFiles(); $file = new CcFiles();
@ -179,7 +179,7 @@ class Rest_MediaController extends Zend_Rest_Controller
$resp->appendBody("ERROR: Media not found."); $resp->appendBody("ERROR: Media not found.");
} }
private function processUpload() private function processUploadedFile()
{ {
$upload_dir = ini_get("upload_tmp_dir") . DIRECTORY_SEPARATOR . "plupload"; $upload_dir = ini_get("upload_tmp_dir") . DIRECTORY_SEPARATOR . "plupload";
$tempFilePath = Application_Model_StoredFile::uploadFile($upload_dir); $tempFilePath = Application_Model_StoredFile::uploadFile($upload_dir);

View File

@ -33,8 +33,7 @@ directory for convenience. This is super easy to do, just run:
To send an test message to airtime_analyzer, you can use the message_sender.php script in the tools directory. To send an test message to airtime_analyzer, you can use the message_sender.php script in the tools directory.
For example, run: For example, run:
$ php tools/message_sender.php '{ "tmp_file_path" : "foo.mp3" }' $ php tools/message_sender.php '{ "tmp_file_path" : "foo.mp3", "final_directory" : ".", "callback_url" : "http://airtime.localhost/rest/media/1", "api_key" : "YOUR_API_KEY" }'
Logging Logging
========= =========