Reputation: 187
I'm trying to upload files to S3 and transcode them using elastic encoder
I have my buckets and pipes active and I can upload files to my input bucket
I keep getting errors on the createJob function
$result = $client->createJob(array(
'PipelineId' => 'pipe.1',
'Input' => array(
'Key' => $counter[10],
'FrameRate' => 'auto',
'Resolution' => 'auto',
'AspectRatio' => 'auto',
'Interlaced' => 'auto',
'Container' => 'auto',
),
'Outputs' => array(
array(
'Key' => $counter[10].".out",
'ThumbnailPattern' => $counter[10],
'Rotate' => 'auto',
'PresetId' => '1351620000001-000001',
)
// ... repeated
),
));
I deleted most of the other parameters in this function as I don't need them.
Edit : exception 'Guzzle\Common\Exception\InvalidArgumentException' with message 'Command was not found matching CreateJob' in phar:///home/prosoccerdata/apps/demo/assets/plugins/aws/aws.phar/Guzzle/Service/Client.php:87 Stack trace:
phar:///home/prosoccerdata/apps/demo/assets/plugins/aws/aws.phar/Guzzle/Service/Client.php(76): Guzzle\Service\Client->getCommand('CreateJob', Array)
phar:///home/prosoccerdata/apps/demo/assets/plugins/aws/aws.phar/Aws/Common/Client /AbstractClient.php(105): Guzzle\Service\Client->__call('CreateJob', Array)
/home/prosoccerdata/apps/demo/beeldbank/beheer/upload.php(179): Aws\Common\Client\AbstractClient->__call('createJob', Array)
/home/prosoccerdata/apps/demo/beeldbank/beheer/upload.php(179): Aws\S3\S3Client->createJob(Array) {main}
Upvotes: 2
Views: 268
Reputation: 600
I had the same newbie issue. You have to changing S3Client to ElasticTranscoderClient.
use Aws\ElasticTranscoder\ElasticTranscoderClient;
$client = ElasticTranscoderClient::factory(array());
$result = $client->CreateJob(array());
I hope it helps.
Upvotes: 0