on 11-10-2014 5:04 PM
I am searching for a method that could returns the media folder full path like: C:/dev/work/myproject/hybris/data/media/sys_master/
I tried mediaService.getMedia but it returns only the path of the media inside sys_master Like testscriptfolder/h97/h0e/8797404266526.txt
Hi Richard,
basically String path = de.hybris.platform.util.Config.getParameter("media.read.dir"); should get you the media folder.
Best regardsYou must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sys_master is the tenantId. You can use tenantService.getCurrentTenantId to get the tenant injected dynamically. Hope that helps!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank u Dirk
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please have a look at the documentation of MediaFolders:
https://wiki.hybris.com/display/release5/MediaFolders
[...]"The MediaFolders of the hybris Commerce Suite installation are tenant-specific, so that every individual tenant will have individual media folders. For every individual tenant, an individual directory named sys_ ${tenant} is created in the deployment directory of the application server. For example, you may have the following MediaFolders: cronjob, hmc and impex, and the following tenants: master and junit."[...]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Dirk, It worked, what about sys_master and sys_junit folders?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
5 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.