Skip to main content
Version: 4.47.0

Binary Delete

The Binary Delete component allows you to delete binaries from the Content Store.

The binaries are deleted from the ‘binaries.files’ and ‘binaries.chunks’ collections.

It uses either the source.localReference or target.localReference value from the incoming message to delete a binary.

Configuration

Connection string

A MongoDB connection string.

Example: mongodb://<username>:<password>@localhost:27017/<databaseName>

Here <databaseName> is the database to delete the binary from.

Use TLS

Enables TLS for your mongoDB connection.

Allow Invalid Certificates

Checking this will disable certificate validation. Warning: specifying this option in a production environment makes your application insecure and potentially vulnerable to expired certificates and to foreign processes posing as valid client instances.

Certificate Authority File

One or more certificate authorities to trust when making a TLS connection. In order to access the local filesystem, the XILL4_WORKDIRS environment variable must be set to the path of the directory to be accessed.

Example: .\ca.pem

Delete reference

  • Source: Delete binary based on the source.localReference value.
  • Target: Delete binary based on the target.localReference value.

Inputs

The component will look on the incoming message for the source.localReference or target.localReference key and uses that to delete the binary from the binaries GridFS bucket since it references the _id field of the binary. The binary in the Content Store matching this reference will be deleted.

Example:

{
"source": {
"localReference":"6232dea643dbbf33e0906e85"
}
}

Outputs

The output contains the value key which refers to the incoming message and the result key which contains the number of objects that were deleted.

Example:

{
"value": {
"source": {
"localReference":"6232dea643dbbf33e0906e85"
}
},
"result": {
"count":"1"
}
}

Note if no object matching the reference was found, count will be 0. If the object was found and deleted, count will be 1. If count is higher than 1, it is likely that the object was corrupted or only partially stored.