commit 07ec0028b6bd1728e20af320dd8b24b7d9e58710 Author: smarcet Date: Tue Oct 13 15:05:37 2020 -0300 Added log Change-Id: I7ce1d1df28b0adad1a356656dcac13b500b67034 Signed-off-by: smarcet diff --git a/app/Services/FileSystem/Dropbox/DropboxAdapter.php b/app/Services/FileSystem/Dropbox/DropboxAdapter.php index 5fb8d82..23d7004 100644 --- a/app/Services/FileSystem/Dropbox/DropboxAdapter.php +++ b/app/Services/FileSystem/Dropbox/DropboxAdapter.php @@ -35,7 +35,7 @@ final class DropboxAdapter extends BaseDropboxAdapter try { $res = $client->listSharedLinks($path); foreach ($res as $entry) { - if($entry['path_lower'] === strtolower($path) ) + if($entry['.tag'] === 'file' ) return $entry['url']; } } diff --git a/app/Services/FileSystem/Swift/SwiftAdapter.php b/app/Services/FileSystem/Swift/SwiftAdapter.php index 2e2ba58..44d8a94 100644 --- a/app/Services/FileSystem/Swift/SwiftAdapter.php +++ b/app/Services/FileSystem/Swift/SwiftAdapter.php @@ -354,7 +354,7 @@ final class SwiftAdapter extends AbstractAdapter if(is_null($obj)) return null; $url = $obj->getPublicUri(); - Log::debug(sprintf("SwiftAdapter get Url for path %s got %s", $path, $url)); + //Log::debug(sprintf("SwiftAdapter get Url for path %s got %s", $path, $url)); return $url; } } diff --git a/app/Services/Model/Imp/PresentationVideoMediaUploadProcessor.php b/app/Services/Model/Imp/PresentationVideoMediaUploadProcessor.php index be93f69..4228a8a 100644 --- a/app/Services/Model/Imp/PresentationVideoMediaUploadProcessor.php +++ b/app/Services/Model/Imp/PresentationVideoMediaUploadProcessor.php @@ -145,7 +145,14 @@ final class PresentationVideoMediaUploadProcessor $strategy = FileDownloadStrategyFactory::build($mediaUpload->getMediaUploadType()->getPrivateStorageType()); if (!is_null($strategy)) { - $assetUrl = $strategy->getUrl($mediaUpload->getRelativePath(IStorageTypesConstants::PrivateType, $mountingFolder)); + $relativePath = $mediaUpload->getRelativePath(IStorageTypesConstants::PrivateType, $mountingFolder); + Log::debug(sprintf("PresentationVideoMediaUploadProcessor::processEvent event %s processing media upload %s relativePath %s", $event_id, $mediaUpload->getId(), $relativePath)); + $assetUrl = $strategy->getUrl($relativePath); + if($assetUrl == '#') + { + Log::debug(sprintf("PresentationVideoMediaUploadProcessor::processEvent event %s processing media upload %s got asset url %s is not valid", $event_id, $mediaUpload->getId(), $assetUrl)); + return false; + } Log::debug(sprintf("PresentationVideoMediaUploadProcessor::processEvent event %s processing media upload %s got asset url %s", $event_id, $mediaUpload->getId(), $assetUrl)); // Create Asset Request diff --git a/app/Services/Utils/DoctrineTransactionService.php b/app/Services/Utils/DoctrineTransactionService.php index f65a5c0..cd66ae3 100644 --- a/app/Services/Utils/DoctrineTransactionService.php +++ b/app/Services/Utils/DoctrineTransactionService.php @@ -80,12 +80,10 @@ final class DoctrineTransactionService implements ITransactionService $con = $em->getConnection(); } $con->setTransactionIsolation($isolationLevel); - Log::debug("DoctrineTransactionService::transaction con->beginTransaction"); $con->beginTransaction(); // suspend auto-commit $result = $callback($this); $em->flush(); $con->commit(); - Log::debug("DoctrineTransactionService::transaction con->commit"); $done = true; } catch (RetryableException $ex) { Log::warning("retrying ...");