Hi Boris, Can you tell us why you needed a Symlink here? I'm asking because there may be a better way to do what you are trying.
Regards, Senaka. On Sun, Mar 3, 2013 at 11:17 PM, Ajith Vitharana <[email protected]> wrote: > Hi Boris, > > The "Governance Artifacts" are usually store inside the governance > registry space. > Therefore we don't allow to create the symlink for the governance > artifacts from out side the /_system/governance(this is a limitation). > Because creating symlinks from out side the governance leads to unnecessary > bugs. This decision was taken to fix the issue[1] > > [1]https://wso2.org/jira/browse/CARBON-11878 > > Thanks > Ajith > > > On Mon, Mar 4, 2013 at 5:18 AM, borice <[email protected]> wrote: > >> Hi, >> >> I'm writing a webapp which is deployed in G-Reg to add some >> project-specific >> services and am running into an exception when attempting to create a >> symlink to a resource. A snippet of the stack trace is included at the >> end >> of this message. This exception seems to be thrown if the media type of >> the >> resource I am trying to create the symlink to (the target) has the format >> "application/vnd.htrc-workset+xml". If I try to create a symlink to a >> resource that has "application/xml" as media type, for example, everything >> works correctly. >> >> For our purposes we have defined a few custom media types that we use for >> our project, such as: >> application/vnd.htrc-workset+xml >> application/vnd.htrc-entry+xml >> ...etc... >> >> My attempts at understanding why this exception occurs led me to the >> following piece of code from [1], lines 170-234. It seems that a regular >> expression is used to match media types of the format >> "application/vnd\\.[a-zA-Z0-9.-]+\\+xml", and for some reason it denies >> symlink creation requests if the target matches this media type. Why was >> this necessary? Shouldn't the restriction apply to just >> "application/vnd.wso2...."-like media types? >> >> Thank you, >> >> Boris Capitanu >> Research Programmer >> Illinois Informatics Institute >> National Center for Supercomputing Applications >> >> [1] >> >> http://wso2.org/svn/browse/wso2/carbon/platform/branches/4.0.0/components/governance/org.wso2.carbon.governance.list/4.0.1/src/main/java/org/wso2/carbon/governance/list/internal/GovernanceMgtUIListMetadataServiceComponent.java?annotate=140791&pathrev=140791 >> >> Stack trace: >> >> org.wso2.carbon.registry.core.exceptions.RegistryException: symlink >> creation >> is not allowed for artifact /htrc/boris/files/workset1.xml >> at >> >> org.wso2.carbon.governance.list.internal.GovernanceMgtUIListMetadataServiceComponent$3.createLink(GovernanceMgtUIListMetadataServiceComponent.java:229) >> at >> >> org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.createLink(HandlerManager.java:3019) >> at >> >> org.wso2.carbon.registry.core.jdbc.handlers.HandlerLifecycleManager.createLink(HandlerLifecycleManager.java:550) >> at >> >> org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.createLink(EmbeddedRegistry.java:2725) >> at >> >> org.wso2.carbon.registry.core.caching.CacheBackedRegistry.createLink(CacheBackedRegistry.java:401) >> at >> >> org.wso2.carbon.registry.core.session.UserRegistry.createLink(UserRegistry.java:1494) >> ... >> >> >> >> -- >> View this message in context: >> http://wso2-oxygen-tank.10903.n7.nabble.com/G-Reg-symlink-creation-is-not-allowed-for-artifact-tp75736.html >> Sent from the WSO2 Development mailing list archive at Nabble.com. >> _______________________________________________ >> Dev mailing list >> [email protected] >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> > > > > -- > Ajith Vitharana. > Senior Software Engineer, > Member,Management Committee, > Integration Technologies. > > WSO2 Inc. - http://wso2.org > Email : [email protected] > Mobile : +94772217350 > > > _______________________________________________ > Dev mailing list > [email protected] > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- * <http://wso2con.com/> * * Senaka Fernando* Member - Integration Technologies Management Committee; Technical Lead; WSO2 Inc.; http://wso2.com* Member; Apache Software Foundation; http://apache.org E-mail: senaka AT wso2.com **P: +1 408 754 7388; ext: 51736*; *M: +94 77 322 1818 Linked-In: http://linkedin.com/in/senakafernando *Lean . Enterprise . Middleware
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
