2

Our customer has specified the domains that he wants for every language as:

www.domain.com -> Spanish www.domain.com/en -> English

For this, we configured cd_dynamic_conf.xml as:

<Configuration Version="7.1"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:noNamespaceSchemaLocation="schemas/cd_dynamic_conf.xsd">
    <URLMappings>
        <StaticMappings>
            <Publications>
                <Publication Id="28">
                     <Host Protocol="http" Domain="www.domain.com" Port="" Path="" />                           
                </Publication>
                <Publication Id="29">
                     <Host Protocol="http" Domain="www.domain.com" Port="" Path="en" />
                </Publication>                

            </Publications>
        </StaticMappings>
        <StorageMapping IdentifyPublicationByProperty="publicationUrl"/>
    </URLMappings>
    <TCDLEngine>
        <Properties>
        </Properties>
    </TCDLEngine>
</Configuration>

For the first domain we defined and empty Path. But It seems that is not supported.

If we visit an url as:

www.domain.com/social

The Resolver is determining the publicationId correctly and is working fine.

But if we visit an url as:

www.domain.com/beneficios

The Resolver is determining as publicationId the publication of English. It seems that is matching en in the url and is assigning an incorrect publication.

Then, we deduced that the first case is working because it's not matching anything and it's getting it by default.

Is the empty path supported?

The other option that we managed is to include a path that we rewrite using apache (like "es" or something similar), but this option has two problems:

  1. We have to add some Rewrite rules in apache that make all more complicated.
  2. All the url's includes these artificial path and we have to manage as exception, including the componentLink resolver. All the url's that DXA or Tridion resolve are incorrect for our website.

Also, We tried a configuration as:

<Configuration Version="7.1"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:noNamespaceSchemaLocation="schemas/cd_dynamic_conf.xsd">
    <URLMappings>
        <StaticMappings>
            <Publications>
                <Publication Id="28">
                     <Host Protocol="http" Domain="www.domain.com" Port="" Path="" />                           
                </Publication>
                <Publication Id="29">
                     <Host Protocol="http" Domain="www.domain.com" Port="" Path="/en/" />
                </Publication>                

            </Publications>
        </StaticMappings>
        <StorageMapping IdentifyPublicationByProperty="publicationUrl"/>
    </URLMappings>
    <TCDLEngine>
        <Properties>
        </Properties>
    </TCDLEngine>
</Configuration>

We added two / in the path of the English site to avoid the path matching, but this doesn't work. It seems that is removing the / from the path to match with the url. Also, the problem is that the process that is resolving the publicationId in the cd_dynamic.jar and we cannot modify it.

Any solution? Thank you!

1 Answer 1

2

I'm guessing this is regarding the pre release of DXA Java, and if I remember correctly we did encounter a defect in the content delivery path resolving in there, for which we had a hotfix available I think.

So to start at the beginning, is the empty path supported? Yes the empty path is supported and DXA should be able to handle it, which it does correctly as you notice with the www.domain.com/social URL.

I'll see if I can trace down the issue and the hotfix I think was created, or if we perhaps have solved it in the official DXA Java 1.2 release.

Update:

I just did a check on our DXA 1.3 version under development on SDL Web 8, and can confirm the issue is gone there, which indeed means the issues in the CD libraries was fixed. But that won't help you much now unles you want to consider upgrading to Web 8.

I think I found the hotfix for 2013 SP1, which is TT88475, but that isn't available publicly on the SDL Tridion World website at this point. I have a good suspicion that is because it is actually included in the 2013 SP1 HR1 hotfix rollup (even though it is not specifically mentioned in the documentation).

In case you are on 2013 SP1, I would suggest that you install the 2013 SP1 HR1 hotfix rollup, since that is the current supported version you should be on anyways. If that does not solve the issue, then you need to contact customer support and log the defect with them, so you can request an official hotfix for it (which I think at this point will still be granted pending the full release of SDL Web 8, but don't hold me on that, I might be wrong).

4
  • 1
    The bug found is in the TridionLocalizationResolver class, exactly in the function getPublicationMappingFromUrl. The library cd_dynamic is not resolving correctly this kind of issues.
    – tfinez
    Commented Dec 17, 2015 at 13:40
  • 1
    We compared between our version and dxa 1.2 and the management of this issue is identical. We are using cd_dynamic-71.0.jar
    – tfinez
    Commented Dec 17, 2015 at 13:41
  • I checked the tridion 2013 sp1 hr1 rollout, and the library cd_dynamic-7.1.0 is not included. The libs in the content delivery folder are: cd_deployer, cd_preview_web, cd_preview_webservice.
    – tfinez
    Commented Dec 17, 2015 at 15:32
  • We uploaded the version, but as expected, it's now working.
    – tfinez
    Commented Dec 18, 2015 at 8:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.