5

I have a websites having few pages present on domain root and others inside sub-domain en. On root pages we have dynamic component presentations from en publication in use. Whenever we are updating the root pages in XPM, we are getting error message:

No Publication Target or Target Type is defined for this Experience Manager-enabled Web site. To resolve this problem, Contact your SDL Web administrator.
   at Tridion.Web.UI.Models.SiteEdit.Services.GetPreviewSessionToken(PublishedItemInfo[] publishedItemsInfo, String publishingTargetId)
   at Tridion.Web.UI.Models.SiteEdit.SessionPreviewService.GetPreviewToken(PublishedItemInfo[] publishedItemsInfo, String publishingTargetId)
   at SyncInvokeGetPreviewToken(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at Tridion.Web.UI.Core.Extensibility.DataExtenderOperationInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.Pr

This seems correct as we have publication mapping defined for subdomains(en) only as per the topology manager settings configured below:

Get-ttmmapping

CmEnvironmentId     : Environment1
PublicationId       : tcm:0-4-1
EnvironmentPurpose  : EP1
WebApplicationId    : Application1
RelativeUrl         : /en
PrimaryMappedUrl    : https://domain/en
IsOffline           : False
CdEnvironment       : 
Id                  : Mapping1
ExtensionProperties : {}

Get-ttmwebsite 

BaseUrls             : {https://domain.com}
CdEnvironmentId      : CDEnvironment1
EnvironmentPurpose   : EP1
CdEnvironment        : 
ScopedRepositoryKeys : {}
Id                   : Website1
ExtensionProperties  : {}

Get-ttmwebapplication

ContextUrl           : /
WebsiteId            : Website1
EnvironmentPurpose   : EP1
CdEnvironment        : 
ScopedRepositoryKeys : {}
Id                   : Application1
ExtensionProperties  : {}

Now my question is can we configure topology manager to configure same publication ID for domain and sub-domain both in Web 8.5? Is there any way, we can use same publication with domain and sub-domain to work with XPM.

1 Answer 1

1

In my knowledge, Topology manager facilitates you with RelativeUrl & PrimaryMappedUrl. These two will be vaidated against your CdEnvironmentId. This means you can serve your data from one CD to diff domain, in genral this stands true and your relativeUrl let you operate on root or 'en' (etc.) of domain/subdomain.

The only thing to notice here is that the ttmMapping will let you use one publicationId only once, this means if it's registered for domain, it can not be used for sub-domains and vise versa.

For example:

Add-TtmMapping -PublicationId 'tcm:0-10-1' -WebApplicationId Website2_RootWebApp -RelativeUrl "/"

Add-TtmMapping -PublicationId 'tcm:0-20-1' -WebApplicationId Website2_RootWebApp -RelativeUrl "/en"

Add-TtmMapping -PublicationId 'tcm:0-30-1' -WebApplicationId Website2_RootWebApp -RelativeUrl "/nl"

Add-TtmMapping -PublicationId 'tcm:0-40-1' -WebApplicationId Website1_RootWebApp -RelativeUrl "/nl"

Here your 'PublicationId' should be unique with respect to your webapplication. This means, if you have multiple web applicatons, you can not use one publication to server all of the webapplicaions. See the last line example.

So, the answer to your question is -

  • Yes, you can configure both domain & subdomain in your topology but they should use diff publication Id.
  • You can not use same publication Id for domain & sub-domain both.

Hope this helps!

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.