dxa-web-application-java icon indicating copy to clipboard operation
dxa-web-application-java copied to clipboard

Link resolving breaks sometimes when editing content with XPM

Open willprice76 opened this issue 7 years ago • 4 comments

It appears that sometime when editing content with XPM that the published content ends up with version information in component links (eg tcm:12-345-v0). This will cause an exception to be thrown when DXA tries to resolve the link using the com.sdl.webapp.tridion.linking.AbstractTridionLinkResolver as this expects an integer in the 3rd segment of the tcm uri (see line 66 from version 1.7)

willprice76 avatar Sep 21 '17 08:09 willprice76

Can you share a bit more details about this, like what version of SDL Web are you experiencing this on, and which hotfixes do you have installed? Also you mention it appears sometimes, is there any reproducible scenario or is it completely random?

bkoopman avatar Sep 21 '17 09:09 bkoopman

Its Web 8.5 with DXA Java 1.7. Unfortunately I don't have a reproduction scenario - its sporadic, but I notice that the issue has been around for longer: https://tridion.stackexchange.com/questions/15847/problem-using-xpm-to-edit-image/15849#comment23104_15849

willprice76 avatar Sep 21 '17 14:09 willprice76

I'm wondering if it might be an XPM or CIS/CIL issue possibly, hence my questions. It will be difficult to classify if we can't reproduce it.

bkoopman avatar Sep 21 '17 14:09 bkoopman

There were changes in SDL Web 8.5 which make it possible that you get a TCM URI with -v0 suffix (referring to the "dynamic version") where you wouldn't get that in earlier versions. TCM URI parsing logic should be able to deal with a version number in the TCM URI, but apparently the DXA Java TCM URI parsing logic chokes on it.

rpannekoek avatar Sep 21 '17 15:09 rpannekoek