deleteOldSolrData(ctx, keytype, version)
Deletes a collection from SOLR.
Parameters
Name | Type | Description |
---|---|---|
ctx | Struct, required | Database details, see above |
keytype | String, required | The name of the collection |
version | Integer, required | The earliest version of the data to keep. Versions earlier than this will be deleted |
Returns
Boolean. True when the collection is deleted.
Example
<cfset ds=APPLICATION.datasource>
<cfset dt=APPLICATION.databasetype>
<!--- get a data importer --->
<cfmodule template="/icm/admin/dataimport/importer_v1.cfm" name="di" datasource=#ds# databasetype=#dt#>
<!--- delete a solr collection --->
<cfset di.deleteOldSolrData(ctx=#di#,
version=15,
keytype="name"
)>
<cfoutput>...Done<br></cfoutput><cfflush>
Last modified on 30 September 2022