We have a storage extension deployed on DXD side of an SDL Docs Implementation. The extension extends ComponentPresentationDAO class. On the Create method, it gives me an object of type "ComponentPresentation" on publishing. By converting this object to string it gives me a serialized JSON representing the published Component Presentation (as shown in the pic below).

Everything looks fine in the JSON except it has "MetadataFields" always set to null for the Component (Topic) inside the Component Presentation. The component(Topic) has some custom metadata in CMS and I expect the same custom metadata to be reflected in the JSON.

Any idea why the custom metadata is not appearing in the JSON

enter image description here

  • Could be you missed to include in the publish plugin xml configuration? – Velmurugan Sep 30 at 7:42
  • 1
    Double check customer-specific metadata fields are configured in the Publish plug-in XML settings for "DocumentObjRequestedMetadata", also same for publication "PublicationOutputRequestedMetadata"? also ensure published package .met file has your metadata fields and values – Velmurugan Sep 30 at 7:52
  • 1
    I think ItemMeta is in a separate DAO, so you'll have to be creative with mapping that. – Raimond Sep 30 at 11:40
  • Thanks @Raimond, you are right it has a separate DAO but since the metadata field is comming out null in the JSON, I was wondering if there is a way to populate that in Component Presentation DAO. – Saurabh Gangwar Sep 30 at 15:55
  • Thanks @Velmurugan, I will double-check the Publish Plugin XML Settings. Since the custom metadata is visible in the results of various GraphQL queries to PCA, it was safe to assume that the metadata was present in the publishing package. – Saurabh Gangwar Sep 30 at 16:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.