Content Tools

Overview

These functions extend Appian content and offer document/folder search, directory listing, and the ability to get/set the searchable attribute of a folder.

Functions are designed for and only work on Appian content, not the local filesystem. All search functions assume the root folder and all subfolders are searchable. Search functions will not return results contained within non-searchable objects.

All functions use the serviceContext of the user account executing the expression at runtime.

Key Features & Functionality

Data Types

  • contentSecurityRoleMap: CDT that backs the returnContentRoleMap function

Smart Services

  • Copy Document (Change Extension)
  • Delete Document Version
  • Delete Folder Contents
  • Delete Files Older Than
  • Delete Files Created Before
  • Delete Multiple Documents
  • Remove Member From Folder Security
  • Inherit Security From Parent for Folder
  • Inherit Security from Parent for Document
  • Remove Member From KC Security
  • Delete Rule/Constant Versions
  • Set Folder Security
  • Create Document Version
  • Create expression rule
  • Update expression rule expression
  • Update expression rule parameters

Functions

  • getfoldersrequiringchangesapproval
  • getsubfoldersfromfolder
  • getdocumentsfromfolder
  • getdocumentinternalidsfromfolder
  • getfilesolderthandate: Get files older than a particular date
  • getfileslargerthansize: Get files larger than a particular size
  • finddocumentsbyname
  • getconstantorruleuuidbyname
  • findcontentbyattribute
  • getcontentdetailsbyuuid
  • getcontentdetailsbyinternalname
  • getcontentobjectdetailsbyid
  • getcontentobjectswithnumofversions: function to find rules or constants with a given number of versions. Useful to find out objects that can increase memory usage in the collaboration engine. See https://forum.appian.com/suite/help/16.3/kb/kb-1226.html
  • getcontentobjectrevisionhistorydetails: Retrieves the revision history of a content object formatted as "[version id, date created, date updated, size, author]"
  • getconstantsfromfolder
  • getconstantsbyname
  • setfoldersearchability
  • getfoldersearchability
  • getdownloadersfromgroup
  • returncontentrolemap
  • getprocessmodeldetailsbyuuid
  • getrulereferencebyname
  • generateuuid
Anonymous
  • What is the status of the "Find Folders by Name" function?  It's listed in the plug-in deployment description, but doesn't seem to be available as a rule within the expression editor, and now it isn't listed in the description here.

  • v1.3.0 Release Notes
    • Added Set Folder Security smart service
  • v1.2.2 Release Notes
    • Converted code base to Gradle
  • Hi,

    The functions listed above mention "getconstantsbyname", but after deploying the latest version of the plugin it seems that the function is unavailable. Is there an issue with the .jar, or is the description outdated?

    Thanks,

    Dan

  • This looks like a corrupt jar file.  Are you sure you loaded the jar and not the zip containing the plugins and the application.

  • Trying to install this on an environment running 18.2. 

    Any ideas?

    13:23:47,404 INFO  [stdout] (Appian Plugin Hot Deploy) 2020-05-11 13:23:47,403 [Appian Plugin Hot Deploy] ERROR com.appiancorp.plugins.osgi.AppianOsgiPluginFactory - AppianOsgiPluginFactory.reportUnloadablePlugin [/home/appian/appian/_admin/plugins/ContentTools-1.2.0.jar]

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy) com.atlassian.plugin.PluginParseException: Unable to scan for host components in plugin classes

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.execute(HostComponentSpringStage.java:62)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.osgi.AppianPluginTransformer.transform(AppianPluginTransformer.java:258)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.osgi.AppianOsgiPluginFactory.createOsgiPluginJar(AppianOsgiPluginFactory.java:232)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.osgi.AppianOsgiPluginFactory.create(AppianOsgiPluginFactory.java:191)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.loaders.ScanningPluginLoader.deployPluginFromUnit(ScanningPluginLoader.java:116)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.loaders.UnloadingDirectoryPluginLoader.deployPluginFromUnit(UnloadingDirectoryPluginLoader.java:111)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.loaders.ScanningPluginLoader.addFoundPlugins(ScanningPluginLoader.java:176)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.loaders.UnloadingDirectoryPluginLoader.addFoundPlugins(UnloadingDirectoryPluginLoader.java:56)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.loaders.PluginVersion2DefaultLoader.addFoundPlugins(PluginVersion2DefaultLoader.java:46)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.manager.DefaultPluginManager.scanForNewPlugins(DefaultPluginManager.java:396)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.AppianPluginManager.scanForNewPlugins0(AppianPluginManager.java:187)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.AppianPluginManager.scanForNewPlugins(AppianPluginManager.java:179)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.appiancorp.plugins.HotDeployerRunnable.run(HotDeployerRunnable.java:29)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at java.lang.Thread.run(Thread.java:748)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy) Caused by: java.io.IOException: Error parsing class file

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.osgi.util.ClassBinaryScanner.scanClassBinary(ClassBinaryScanner.java:66)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.findUsedHostComponents(HostComponentSpringStage.java:195)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.osgi.factory.transform.stage.HostComponentSpringStage.execute(HostComponentSpringStage.java:58)

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  ... 19 more

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy) Caused by: java.lang.ArrayIndexOutOfBoundsException: 18

    13:23:47,406 INFO  [stdout] (Appian Plugin Hot Deploy)  at aQute.lib.osgi.Clazz.parseClassFile(Clazz.java:448)

    13:23:47,407 INFO  [stdout] (Appian Plugin Hot Deploy)  at aQute.lib.osgi.Clazz.parseClassFile(Clazz.java:369)

    13:23:47,407 INFO  [stdout] (Appian Plugin Hot Deploy)  at aQute.lib.osgi.Clazz.parseClassFileWithCollector(Clazz.java:359)

    13:23:47,407 INFO  [stdout] (Appian Plugin Hot Deploy)  at com.atlassian.plugin.osgi.util.ClassBinaryScanner.scanClassBinary(ClassBinaryScanner.java:38)

    13:23:47,407 INFO  [stdout] (Appian Plugin Hot Deploy)  ... 21 more

    13:23:47,407 INFO  [stdout] (Appian Plugin Hot Deploy) 2020-05-11 13:23:47,407 [Appian Plugin Hot Deploy] ERROR com.appiancorp.plugins.LoggingPluginEventListener - Failed to load Plug-in 'Unknown-484532458' (Unknown-484532458) version 0.0: 'Unable to load plugin: Unable to scan for host components in plugin classes'

  • Hi - Compatible Version(s) is based on what the app author has tested with at the time of submission. Appian has great backwards compatibility so in general, there's no need to worry if a new Appian version comes out but the plug-in hasn't been updated. We just updated this plug-in today and the new version has been tested with 20.1, so the compatibility has been updated. The new plug-in version adds the Delete Rule/Constant Versions Smart Service. 

  • How does this plugin compare to Content Expressions (v1.0.8) [com.appiancorp.cloud.plugins.contentfunctions]? We are currently using the Content Expressions plugin which I don't believe is available anymore - superceded by the above plugin? - and some OOTB functions. We did have to update a few things following the 19.1 upgrade to use the OOTB function 'findcontentbyattribute' in processes that were using the 'finddocumentsbyname()' function from the plugin. Can we safely upgrade to this plugin?

  • Glad to know this will work with 20.1 - Can you update the information for this plugin? It currently says 'Compatible Version(s): 17.2 +, 19.3 - which is misleading. Perhaps it should say 17.1 - 20.1.