Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Chan Kim 2 posts 72 karma points
    Oct 30, 2020 @ 07:37
    Chan Kim
    0

    Usync Complete "The given path's format is not supported." error

    Being a non-developer, I am using Umbraco CMS and I am trying to use Usync.complete(currently in trial status).

    While testing, we are having some problems. Everything seems to be working fine but "media" related functions are not working. Been through the documentation and FAQs but could not find the solution.

    Following/similar error pops-up in few areas like Publisher: including media to push or Exporting Sync pack.

    Unhandled controller exception occurred for request '"https://cms-dev.test.com/umbraco/backoffice/uSync/uSyncExporterApi/ExportItems/"
    
    System.NotSupportedException: The given path's format is not supported.
       at System.Security.Permissions.FileIOPermission.EmulateFileIOPermissionChecks(String fullPath)
       at System.Security.Permissions.FileIOPermission.QuickDemand(FileIOPermissionAccess access, String fullPath, Boolean checkForDuplicates, Boolean needFullPath)
       at uSync8.BackOffice.Services.SyncFileService.GetAbsPath(String path)
       at uSync8.BackOffice.Services.SyncFileService.OpenWrite(String path)
       at uSync8.BackOffice.Services.SyncFileService.SaveFile(String filename, Stream stream)
       at uSync.Expansions.Core.Physical.uSyncMediaFileService.CopyMediaFile(IMedia item, String folder)
       at uSync.Expansions.Core.Services.uSyncDependencyService.ExportDependency(uSyncDependency dependency, String folder, ISyncExtendedHandler handler, HandlerSettings settings, SyncPackOptions options)
       at uSync.Expansions.Core.Services.uSyncDependencyService.ExportDependencies(IEnumerable`1 dependencies, String handlerSetName, SyncPackOptions options, SyncUpdateCallback update, Int32 startIndex, Int32 totalSteps)
       at uSync.Expansions.Core.Services.uSyncDependencyService.CreateSyncPack(IEnumerable`1 dependencies, String handlerSetName, SyncPackOptions options, uSyncCallbacks callbacks)
       at uSync.Exporter.Controllers.uSyncExporterApiController.Export(IEnumerable`1 dependencies, Boolean includeFiles, String name, String type, uSyncCallbacks callbacks)
       at uSync.Exporter.Controllers.uSyncExporterApiController.ExportItems(ExportItemsView model)
       at lambda_method(Closure , Object , Object[] )
       at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass6_2.<GetExecutor>b__2(Object instance, Object[] methodParameters)
       at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary`2 arguments, CancellationToken cancellationToken)
    --- End of stack trace from previous location where exception was thrown ---
    

    Currently using AWS instance for Umbraco and S3 for the media storage location.

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Oct 30, 2020 @ 09:18
    Kevin Jump
    0

    Hi,

    Sorry this is working for you .

    Just wondering did you have media in your media folders before you setup the S3 storage ? We have seen a couple of issues with media paths changing after people setup cloud storage and then the exports being affected by it.

    if you can add the following two lines to the config/serilog.config file. then you will hopefully get some extra debug logging in the umbraco logs (settings -> Log Viewer) just before the error :

        <add key="serilog:minimum-level:override:uSync.Expansions.Core.Physical.uSyncMediaFileService" value="Debug" />
        <add ket="serilog:minimum-level:override:uSync8.BackOffice.Services.SyncFileService" value="Debug"/>
    

    You will have to restart your site once you've edited this file to see the log entries.

    It would be good to see what these lines look like in your logs: CopyMediaFile: {Id} {folder} and "Saving File: {0}

    Kevin

  • Chan Kim 2 posts 72 karma points
    Oct 30, 2020 @ 22:01
    Chan Kim
    0

    Hi, Kevin

    I have tried this out and got result as following.

    Oct 30, 2020 9:42:58 PM Error   EC2AMAZ-S49PQNV Unhandled controller exception occurred for request '"https://cms-dev.test.com/umbraco/backoffice/uSync/uSyncPublisherApi/PerformStep/67be6690-d345-42f3-a89f-8ee0d67c4ba2?mode=push"'
    Oct 30, 2020 9:42:58 PM Debug   EC2AMAZ-S49PQNV Saving File: "D:\IIS_WWW\cms-dev.test.com\App_Data\TEMP\uSync\pack\guplx4ijhttps://test.s3-eu-west-1.amazonaws.com/Media/n5udbfwe/10px_img.jpeg"
    Oct 30, 2020 9:42:57 PM Debug   EC2AMAZ-S49PQNV file path from crop: "https://test.s3-eu-west-1.amazonaws.com/Media/n5udbfwe/10px_img.jpeg"
    Oct 30, 2020 9:42:57 PM Debug   EC2AMAZ-S49PQNV CopyMediaFile: 1698 "D:\IIS_WWW\cms-dev.test.com\App_Data\TEMP\uSync\pack\guplx4ij"
    

    I guess I should have mentioned more details of the the process these error came from: I have been testing pushing media using "remote media" function Local to remote server(Dev1 -> Dev2)

    And for your question on having media file beforehand: We were using S3 from the start.

    Umbraco was configured from start with S3 storage. But we did change S3 storage location for Dev2 to point to new one. Before, Dev1 and Dev2 were pointing at same S3 bucket. These tests were done on Dev1.

    Thanks

    Chan

  • Hong Sangyoung 2 posts 22 karma points
    Dec 22, 2020 @ 04:06
    Hong Sangyoung
    0

    Hi~ Kevin

    While trying uSync test, It has a same error.

    This is my error log.

    Please, check. And give me an information to solve this. - We have 2 Instance (Dev1, Dev2) that are installed uSync - We Use AWS S3 for Media storage (Use different bucket for each.)

    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV Saving File: "D:\IIS_WWW\cms-dev.intelliantech.com\App_Data\TEMP\uSync\pack\bi5amx34https://intellianwebstage.s3-us-west-2.amazonaws.com/Media/eayoegy5/2018_contest_winner_v4_500x500px-사본.jpg"
    Dec 22, 2020 11:17:04 AM    Error   EC2AMAZ-S49PQNV Unhandled controller exception occurred for request '"https://cms-dev.intelliantech.com/umbraco/backoffice/uSync/uSyncPublisherApi/PerformStep/2b3b84cd-cc35-4acc-89f3-f96af32f9b33?mode=push"'
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV 19: {Count} Required Media Items Exporting
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV PackMedia: 19 media files in "D:\IIS_WWW\cms-dev.intelliantech.com\App_Data\TEMP\uSync\pack\bi5amx34"
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV CopyMediaFile: 2597 "D:\IIS_WWW\cms-dev.intelliantech.com\App_Data\TEMP\uSync\pack\bi5amx34"
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV file path from crop: "https://intellianwebstage.s3-us-west-2.amazonaws.com/Media/eayoegy5/2018_contest_winner_v4_500x500px-사본.jpg"
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV PeformStep: ["2b3b84cd-cc35-4acc-89f3-f96af32f9b33":"Push"] - "dev2" - "publish"["Push Media"]
    Dec 22, 2020 11:17:04 AM    Debug   EC2AMAZ-S49PQNV PeformStep: Starting "Push Media" 0
    

    And It's detail error log...

    Exception
    System.NotSupportedException: The given path's format is not supported.
       at System.Security.Permissions.FileIOPermission.EmulateFileIOPermissionChecks(String fullPath)
       at System.Security.Permissions.FileIOPermission.QuickDemand(FileIOPermissionAccess access, String fullPath, Boolean checkForDuplicates, Boolean needFullPath)
       at uSync8.BackOffice.Services.SyncFileService.GetAbsPath(String path)
       at uSync8.BackOffice.Services.SyncFileService.OpenWrite(String path)
       at uSync8.BackOffice.Services.SyncFileService.SaveFile(String filename, Stream stream)
       at uSync.Expansions.Core.Physical.uSyncMediaFileService.CopyMediaFile(IMedia item, String folder)
       at uSync.Expansions.Core.Physical.uSyncMediaFileService.CopyMediaFile(Guid key, String folder)
       at uSync.Expansions.Core.Services.uSyncDependencyService.PackMedia(IEnumerable`1 keys, uSyncCallbacks callbacks)
       at uSync.Publisher.Publishers.SyncRealTimeStepPublisher.<PushMedia>d__16.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at uSync.Publisher.Controllers.uSyncPublisherApiController.<PerformStep>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Threading.Tasks.TaskHelpersExtensions.<CastToObject>d__1`1.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__1.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__3.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__3.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__3.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__15.MoveNext()
    
  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Dec 22, 2020 @ 11:31
    Kevin Jump
    0

    Hi,

    it might be worth looking at this in the issues repo - as it goes through some of the S3 config needed to get media to copy correctly.

    https://github.com/Jumoo/uSync.Complete.Issues/issues/75

    it contains config, and there is an updated dll in this comment : https://github.com/Jumoo/uSync.Complete.Issues/issues/75#issuecomment-737842760 which helps with s3 and when your media folder isn't called media

  • Hong Sangyoung 2 posts 22 karma points
    Dec 23, 2020 @ 07:18
    Hong Sangyoung
    0

    Sorry., But it doesn't work for me.

    In my case

    • Media(image) file upload OK (I checked It is located in S3 storage.)
    • So it is shown on the Media page.
    • But when I start uSync I get the error I mentioned.
  • jalexis 8 posts 80 karma points
    Sep 21, 2021 @ 12:29
    jalexis
    0

    Good day,

    May I know if you were able to fix this issue? I am currently experiencing the same error. Thank you

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 21, 2021 @ 13:01
    Kevin Jump
    0

    Hi Jalexis,

    I would make sure you are running the latest version of everything (uSync.Complete, and Azure/S3 providers you may have). and see if that resolves any issues you have.

    If its S3 then i would check out these few comments on the issue - they go over settings.

    https://github.com/Jumoo/uSync.Complete.Issues/issues/75#issuecomment-737752771

    it its Azure Blob storage, there are a few odd things about the media file name - you can see them in this issue: https://github.com/Jumoo/uSync.Complete.Issues/issues/63

  • jalexis 8 posts 80 karma points
    Sep 21, 2021 @ 14:42
    jalexis
    0

    Hi Kevin,

    I checked the links below but it doesn't fixed my issue. This is my exact error message when publishing from one server to another using usync.complete:

    enter image description here

    I'm also running the latest versions of usync and usync.complete.

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 21, 2021 @ 15:18
    Kevin Jump
    0

    Hi,

    if you can, add uSync debug logging to the config/serilog.config

    <add key="serilog:minimum-level:override:uSync" value="Debug"/>
    

    with this turned on you should see some logging about where uSync thinks it is packing the media files. eg.

    enter image description here

    you can use : SourceContext='uSync.Expansions.Core.Physical.SyncMediaFileService' as search term in the Umbraco log viewer to limit the results to media file things.

  • jalexis 8 posts 80 karma points
    Sep 21, 2021 @ 17:32
    jalexis
    0

    This is my logs, any idea what is wrong with the path? should the "file path from crop" have "/"? thanks!

    enter image description here

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 21, 2021 @ 18:11
    Kevin Jump
    0

    Hi,

    yeah i am guessing you have the Disable Virtual Path Provider setting set to true ?

    <add key="AzureBlobFileSystem.DisableVirtualPathProvider" value="true" />
    

    i think this means the paths are stored in the media with their fully qualifed URL. -

    I thought we delt with this, but it doesn't look like it, i will take a look and see what we can do.

  • jalexis 8 posts 80 karma points
    Sep 22, 2021 @ 02:28
    jalexis
    0

    Hi Kevin,

    Yes I set the AzureBlobFileSystem.DisableVirtualPathProvider to true. Still the same error. Thank you!

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 22, 2021 @ 08:10
    Kevin Jump
    0

    HI

    I think we have 95% of the fix for this (well i have it all working locally!) - just to confirm we are doing things as expected can you send us your Azure blob settings (minus the connection key etc obvs).

    e.g i've been testing with :

    <add key="AzureBlobFileSystem.ContainerName:media" value="usync-source-media" />
    <add key="AzureBlobFileSystem.RootUrl:media" value="https://*******.blob.core.windows.net/" />
    <add key="AzureBlobFileSystem.ConnectionString:media" value="*********** />
    <add key="AzureBlobFileSystem.MaxDays:media" value="365" />
    <add key="AzureBlobFileSystem.UseDefaultRoute:media" value="true" />
    <add key="AzureBlobFileSystem.UsePrivateContainer:media" value="false" />
    <add key="AzureBlobFileSystem.DisableVirtualPathProvider" value="true" />
    

    The key for us is we have to rewrite the blob urls (that are stored in the db - when setup like this)

    From : https://blobname.blob.core.windows.net/container/random/image.png

    to: /media/random/image.png

    mostly we can auto-detect this, but having more examples of people's config will help us work this out.

  • jalexis 8 posts 80 karma points
    Sep 22, 2021 @ 08:17
    jalexis
    1

    Hi Kevin,

    I have the same settings for Azure blob config:

    enter image description here

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 22, 2021 @ 11:35
    Kevin Jump
    1

    Hi we have a fix for this now,

    in uSync.Complete v8.11.2 ( https://github.com/Jumoo/uSync.Complete.Issues/releases/tag/v8.11.2)

    this release should be able to work out that with the VirtualPathProvider disabled the media files are stored a URLs. it will turn the url paths into generic /media/folder/file paths for the process of moving them, and then back again into the correct url at the other end.


    if for some reason the auto-detection of what the URL will be doesn't work you can add a property to the webconfig. to tell uSync what it is.

    <add key="uSync.mediaFolder" value="http://your.path.toblob/container" />
    

    but you shouldn't have to add this at it should autodetect it

  • jalexis 8 posts 80 karma points
    Sep 22, 2021 @ 12:43
    jalexis
    0

    Hi Kevin,

    Thank you so much! I was able to test it and I no longer encounter the error. But I noticed it is not detecting the correct URL at the other end. It picks up the /media/folder/file path. So I added uSync.mediaFolder in the web.config of the source environment. But still the same. Does it mean that I should also add this to the config of the destination environment?

    Also, just another question, we are using just one azure blob container for 2 environments. This is fine right?

    Thank you for your time!

  • Kevin Jump 2342 posts 14889 karma points MVP 8x c-trib
    Sep 22, 2021 @ 13:36
    Kevin Jump
    1

    Hi,

    yeah it should in theory detect the url on the target evironment too, but if it doesn't for some reason teh uSync.MediaFolder does need to go on that end of the setup.

    I would say it would you should have two separate blog containers - not just for uSync but in general,

    if you are sharing containers then if someone deletes and image from once side, then everything will seem OK, but when they empty the recycle bin that would remove the images that might be getting used on other other site. and you would loose them.

  • jalexis 8 posts 80 karma points
    Sep 22, 2021 @ 14:49
    jalexis
    0

    Thank you so much! This issue has been fixed already. It is working fine now. :)

Please Sign in or register to post replies

Write your reply to:

Draft