This page details the specific configuration and input options for the Upsert Workspace Orchestrator.
This guidance should be read in conjunction with the Common Configuration page which details the standard application configuration.
Purpose
The key purpose of this Orchestrator is to create and update workspace profiles.
Operation Name
UpsertWorkspace
Common Configuration
There is common configuration available within this job Orchestrator. The common configuration options can be found here.
Input Data Schema
Data can be read via SQL or CSV and requires the following data headers and values:
CSV
|
Headers |
Description |
Mandatory |
Expected Value |
|---|---|---|---|
|
|
This is the row ID |
Yes |
Numeric value |
|
|
Specifies the type of action to apply to the row |
Yes |
Either:
You can use an empty value (“”) which will update if a match is found or create if no match is found |
|
|
The ID of the iManage Library |
Yes |
iManage Library identifier i.e. ‘Active’ |
|
|
Allows you to target a specific workspace Id If |
No (unless |
iManage identifier i.e. ‘Active!1234’ |
|
|
A JSON object which contains a dictionary matching any applicable profile parameters for the corresponding Multiple parameters can be used in the search query If |
No (unless |
JSON format i.e. if using csv input then escaped values need to be used for multiple parameter queries. The following keys can be provided:
|
|
|
Specifies the specific template to be applied to the workspace |
Yes (for creation only) |
|
|
|
Specifies the Author |
No |
|
|
|
Specifies the Name |
Yes (for creation only) |
|
|
|
Specifies the Owner |
Yes (for creation only) |
|
|
|
Specifies the Owner Description |
No |
|
|
|
Specifies the Class |
No |
|
|
|
Specifies the Class Description |
No |
|
|
|
Specifies the Subclass |
No |
|
|
|
Specifies the Subclass Description |
No |
|
|
|
Specifies the Default Security |
Yes (for creation only) |
|
|
|
Specifies the Description |
No |
|
|
|
Specifies the name of the entry for this custom field. |
No (Unless Custom 2 is specified) |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies an optional description for the custom field. |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the name of the entry for this custom field. |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies an optional description for the custom field. |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the name of the entry for this custom field. |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 3 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the name of the entry for this custom field. |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 4 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 5 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 5 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 6 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 6 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 7 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 7 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 8 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 8 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 9 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 9 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 10 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 10 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 11 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 11 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 12 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 12 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 17 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 18 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 19 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 20 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 23 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 24 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 25 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 26 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 27 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 28 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 29 Value |
No (unless Custom 30 is specified) |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 29 Description |
No (unless Custom 30 is specified) |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Specifies the Custom 30 Value |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 32 Spaces are not allowed |
|
|
Specifies the Custom 30 Description |
No |
Alphanumeric: a-z, A-Z, 0-9 Max length: 254 |
|
|
Indicates if the row has been processed |
No |
'0' |
SQL
SQL Input uses the same values as the CSV input above. The SQL Schema is detailed below, with the addition of three fields, that are used to track the status of the record:
CREATE TABLE UpsertWorkspaceInput (
Id INT IDENTITY(1,1) PRIMARY KEY,
Action NVARCHAR(50) NOT NULL,
TargetLibraryId NVARCHAR(255) NOT NULL,
TargetObjectId NVARCHAR(255),
TemplateName NVARCHAR(255),
TargetObjectSearchQuery NVARCHAR(MAX),
Profile_Author NVARCHAR(255),
Profile_Custom1 NVARCHAR(255),
Profile_Custom1Description NVARCHAR(255),
Profile_Custom2 NVARCHAR(255),
Profile_Custom2Description NVARCHAR(255),
Profile_Custom3 NVARCHAR(255),
Profile_Custom3Description NVARCHAR(255),
Profile_Custom4 NVARCHAR(255),
Profile_Custom4Description NVARCHAR(255),
Profile_Custom5 NVARCHAR(255),
Profile_Custom5Description NVARCHAR(255),
Profile_Custom6 NVARCHAR(255),
Profile_Custom6Description NVARCHAR(255),
Profile_Custom7 NVARCHAR(255),
Profile_Custom7Description NVARCHAR(255),
Profile_Custom8 NVARCHAR(255),
Profile_Custom8Description NVARCHAR(255),
Profile_Custom9 NVARCHAR(255),
Profile_Custom9Description NVARCHAR(255),
Profile_Custom10 NVARCHAR(255),
Profile_Custom10Description NVARCHAR(255),
Profile_Custom11 NVARCHAR(255),
Profile_Custom11Description NVARCHAR(255),
Profile_Custom12 NVARCHAR(255),
Profile_Custom12Description NVARCHAR(255),
Profile_Custom17 FLOAT,
Profile_Custom18 FLOAT,
Profile_Custom19 FLOAT,
Profile_Custom20 FLOAT,
Profile_Custom23 DATETIMEOFFSET,
Profile_Custom24 DATETIMEOFFSET,
Profile_Custom25 BIT,
Profile_Custom26 BIT,
Profile_Custom27 BIT,
Profile_Custom28 BIT,
Profile_Custom29 NVARCHAR(255),
Profile_Custom29Description NVARCHAR(255),
Profile_Custom30 NVARCHAR(255),
Profile_Custom30Description NVARCHAR(255),
Profile_DefaultSecurity NVARCHAR(255),
Profile_Description NVARCHAR(MAX),
Profile_Name NVARCHAR(255),
Profile_Owner NVARCHAR(255),
Profile_OwnerDescription NVARCHAR(255),
Profile_Class NVARCHAR(255),
Profile_ClassDescription NVARCHAR(255),
Profile_Subclass NVARCHAR(255),
Profile_SubclassDescription NVARCHAR(255),
Processed BIT NOT NULL,
DateAddedUtc DATETIME NOT NULL DEFAULT (GETUTCDATE()),
DateUpdatedUtc DATETIME,
Profile_C1C2 NVARCHAR(255)
);
CREATE TRIGGER trg_UpsertUpdateDateTime
ON dbo.UpsertWorkspaceInput
AFTER UPDATE
AS
BEGIN
SET NOCOUNT ON;
/*
Avoids recursion if not disabled in the server.
If DateUpdateUtc is updated, regardless of other updates, it will not
change the date
*/
IF NOT UPDATE(DateUpdatedUtc)
BEGIN
UPDATE u
SET u.DateUpdatedUtc = GETUTCDATE()
FROM dbo.UpsertWorkspaceInput u
INNER JOIN Inserted i ON u.Id = i.Id;
END
END;
CREATE NONCLUSTERED INDEX IX_UpsertWorkspaceInput_Profile_C1C2
ON dbo.UpsertWorkspaceInput (Profile_C1C2);
Job File Options
This section details the configurable options within the orchestrator.
Orchestrator Level Options
|
Configuration |
Description |
Expected Value |
|---|---|---|
|
|
If enabled then any custom metadata (Custom1-30) which does not currently exist will be created |
|
|
|
If enabled then the application will process all results returned by the search query. When disabled then the application will only process the request if one search result is identified |
|
Create Options
|
Configuration |
Description |
Expected Value |
|---|---|---|
|
|
Sets whether the create process is enabled or disabled |
|
|
|
If enabled it will use metadata set under the template as the primary update if values are provided in both the template and the profile input |
|
Update Options
|
Configuration |
Description |
Expected Value |
|---|---|---|
|
|
Sets whether the update process is enabled or disabled |
|
|
|
Forces a workspace refile after update |
|
|
|
If enabled it will use metadata set under the template as the primary update if values are provided in both the template and the profile input |
|
Update Workspace Options
|
Configuration |
Description |
Expected Value |
|---|---|---|
|
|
Whether to update the non-security metadata on the workspace |
|
|
|
Whether to update the default security on the workspace |
|
|
|
Sets the behaviour for ACL updates |
Either:
|
Update Folder Options
These are the configuration options available under ‘TemplateSync’
|
Function |
Configuration |
Description |
Expected Value |
|---|---|---|---|
|
Matched |
|
If enabled then existing metadata will be updated |
|
|
|
If enabled then both Default Security and ACL updates will be carried out as per the template or input data |
|
|
|
Missing |
|
Sets the behaviour for any existing folders that are not included in the new template |
Either:
|
|
|
If enabled then search folders not included in the new template will be deleted |
|
Output Events
These output events are specific to the Upsert Workspace Orchestrator and works in addition to the common output events detailed in Common Configuration
The following output events can be persisted via the ‘Subscribed To’ configuration
|
Target |
Action |
Status |
Full Event Identifier |
|---|---|---|---|
|
|
|
|
|
|
|
|
|
|
These should be listed in the Orchestrator in the following format ‘Target:Action:Status’.
The event output schema is shown below:
CREATE TABLE UpsertWorkspaceOutput (
Id INT IDENTITY(1,1) PRIMARY KEY,
EventTime DATETIMEOFFSET NOT NULL,
CorrelationId VARCHAR(36) NOT NULL,
[Action] VARCHAR(30) NOT NULL,
[Status] VARCHAR(25) NOT NULL,
[Message] NVARCHAR(MAX) NOT NULL,
DataSourceRowId VARCHAR(25),
TargetObjectType VARCHAR(25) NOT NULL,
TargetObjectId VARCHAR(25),
TargetSearchQuery NVARCHAR(MAX) NULL,
TargetSearchQueryResultCount VARCHAR(10) NULL,
TargetSearchQueryResultList NVARCHAR(MAX) NULL,
Workspace NVARCHAR(MAX) NULL,
AppliedTemplateName NVARCHAR(255) NULL
);
Sample Job File
This is an example Job File for the UpsertWorkspace Orchestrator:
{
"Operation": "UpsertWorkspace",
"Options": {
"Create": {
"Enabled": true,
"UseTemplateDataAsPriority": false
},
"Update": {
"Enabled": true,
"ExplicitRefile": false,
"UseTemplateDataAsPriority": true,
"Workspace": {
"UpdateMetadata": true,
"UpdateDefaultSecurity": false,
"AclUpdateBehaviour": "Skip"
},
"Folder": {
"TemplateSync": {
"Enabled": true,
"Matched": {
"UpdateMetadata": true,
"UpdateDefaultSecurity": false,
},
"Missing": {
"Action": "RemoveIfEmpty",
"DeleteSearchFolders": true
}
}
}
},
"CreateMissingMetadata": true,
"ActionMultipleQueryResults": false
},
"InputType": "CSV",
"Inputs": {
"CSV": {
"Path": "<repo>\\source\\WorkspaceAutomate\\Test Files\\Csvs\\UpsertWorkspace.csv"
}
},
"Outputs": {
"Console": {
"Enabled": true,
"SubscribedTo": ["*"]
}
},
"Integrations": {
"IManage": {
"URL": "<url>",
"Username": "<username>",
"Password": "<password>"
}
}
}
Failure and Skip Behaviour
This Orchestrator follows the standard behaviour for failed/skipped records:
Skipped = Scenarios configured to not be processed for a specific reason e.g. Update Enabled: falsewould skip any processing of the the row if a matching workspace was found.
Failed = Administrate tried to perform an action on the target object and an unexpected error occurred. e.g. iManage connection dropped and Administrate was unable to delete a document that was configured to be deleted.
iManage Behaviour
This section details the different behaviour across different versions of iManage i.e. On-Prem, iManage Cloud and Cloud iManage.
There are no differences for this operation between On-Prem and Cloud iManage.