Attaching a File to a DITA Map Using a Control File Fails - Fluid Topics - 3.8

Fluid Topics Troubleshooting Guide

Product
Fluid Topics
FT_Version
3.8
Platform
RHEL
Category
Reference Guide
language
English

Issue

When using a control file to attach a file to a DITA Map with a DITAVAL, adding the attachment fails.

Fluid Topics Dataflow logs display the following error:

@processPublication (abbe6b34abdd22fc541ba098661b93b8.map) was not found, it cannot be attached to Attachment ($attachmentOriginId)

Impact(s) on users

This issue prevents KHUB Admin users from attaching a document (typically PDF files) to a map with a DITAVAL.

This issue causes no impact to end-users.

Possible root cause(s)

This issue might occur when:

  • The filepaths of the maps and/or DITAVALs in the control file are incorrect.
  • The khubId and/or originId of the attachment are incorrect.

Solution(s)

Solution 1 – Correct filepaths

Check if filepaths are all absolute paths.

Paths must be the same as seen in the Metadata Journal.

Example

The OD1000 Configuration Guide has the following DITAVAL path information in its Metadata Journal. The associated metadata is dita:ditavalPath.

The diitavalPath is displayed in the Metadata Journal

The path must be written as such in the control file:

<?xml version='1.0' encoding='utf-8'?>
<controlFile>
<resources>
<resource>
<filePath>_od1000_configuration_guide.ditamap</filePath>
<instances>
<instance>
<filePath>od1000/Ditaval/Expert.ditaval</filePath> <!-- Expert.ditaval would not work - see the Metadata Journal dita:ditavalPath -->
<attachments>
<attachment>
<originId>standard_time_zones_of_the_world</originId>
<displayName>Standard Time Zones of the World</displayName>
<filePath>standard_time_zones_of_the_world.png</filePath>
</attachment>
</attachments>
</instance>
</instances>
</resource>
</resources>
</controlFile>

For more information on how to write filepaths for the control file, see the Manage DITA Map Attachments with a Control File section.

Solution 2 – Correct khubIds and originIds

Check if the khubId and/or originId of the attachment are correct.

Map attachments have two unique identifiers:

  • khubId: an internal technical identifier, e.g., aaaaaaaaa
  • originId: a more user-friendly identifier you can set for future reference, e.g., my_pretty_identifier

Example

The time_capacitor_assembly_scheme.pdf file was attached to the _maintenance_guide map with the legacy method, using the mapping.json file. It received a unique identifier khubId=~Nq5~1bUD4, that you can find at the end of its URL: https://myfluidtopics.com/viewer/book-attachment/WqSSSFS55/~Nq5~1bUD4

Attachments uploaded using the legacy method do not have originIds. This is a new property introduced in Fluid Topics version 3.5.

To attach a new version of the time_capacitor_assembly_scheme.pdf file to the map using a control file with originId=time_capacitor_assembly_scheme.pdf, for Fluid Topics, this is a new file because the only known attachment has no originId. This is why it is added to the map, and does not replace the previous attachment.

Provided that https://myfluidtopics.com/viewer/book-attachment/WqSSSFS55/~Nq5~1bUD4 is the PDF that needs to be replaced with a newer version, add the following lines to your control file:

<khubId>~Nq5~1bUD4</khubId> <!-- so that Fluid Topics identifies properly the attachment to be replaced -->
<originId>time_capacitor_assembly_scheme.pdf</originId> <!-- so that Fluid Topics adds this business identifier to the map -->

From now on, you will be able to use only the time_capacitor_assembly_scheme.pdf originId if needed.