Does ISHRemote only see a Document Object if it has object, version and language layer present?

Hi,

I am still researching and trying to understand the workings of ISHRemote for manipulating objects in Tridion Docs.

While testing various calls to Get-IshDocumentObj it appears to sometimes remove only the language layer of a document object.

When I view the document object in Tridion Web Client I can still see the Object and Version layer. However, when I test further attempts to get or remove this object view ISHRemote, it doesn't find it.

Can anyone explain the visibility of a topic object in Tridion Web Client that cannot be seen via call to Get-IshDocumentObj using ISHRemote?

Any feedback appreciated,

Regards,

Ann

Parents Reply
  • Hi Ann,

    It does not differ 'Remove-IshDocumentObj' eventually calls the Delete API function as you can see on https://github.com/sdl/ISHRemote/blob/master/Source/ISHRemote/Trisoft.ISHRemote/Cmdlets/DocumentObj/RemoveIshDocumentObj.cs line 208. The main difference is that ISHRemote in total expects full logical-version-language, and only the delete tries to do cleanup for the last version (if all languages are gone) and also for the logical (if all versions and languages are gone).

    Now what you experience is that delete of that last logical level is blocked. And that will be the same for ISHRemote and the API call.

    So there are some best practices, as delete the pyramid of information in order

    1. Publications first as they reference (root) maps and resources (typically library topics)
    2. Then root maps, sub maps, etc as they reference topics
    3. Then Topics as they reference images and conrefs and variables (typically offered by library topics)
    4. Then Library Topics who could reference each other or images
    5. Then Images

    Another approach if you don't know or care about the information architecture is to brute-force loop. If you 10 objects referencing each other, probably one is top of the pyramid and the others will fail, so one delete will work. Enabling the next delete in the next loop.

    I understand - and experienced it multiple times myself - that referential integrity is part of the CMS and especially complicates negative/removal operations. Of course that is one of those things that set the CMS apart from a folder with files.

    Best wishes,
    Dave

Children
No Data