Class FilesAndFoldersClient
java.lang.Object
org.odpi.openmetadata.accessservices.datamanager.client.DataManagerBaseClient
org.odpi.openmetadata.accessservices.datamanager.client.SchemaManagerClient
org.odpi.openmetadata.accessservices.datamanager.client.FilesAndFoldersClient
- All Implemented Interfaces:
org.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface,org.odpi.openmetadata.accessservices.datamanager.api.SchemaManagerInterface
public class FilesAndFoldersClient
extends SchemaManagerClient
implements org.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface
FilesAndFoldersClient is the client for managing the creation of files and folder assets.
-
Constructor Summary
ConstructorsConstructorDescriptionFilesAndFoldersClient(String serverName, String serverPlatformURLRoot) Create a new client with no authentication embedded in the HTTP request.FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, String userId, String password) Create a new client that passes userId and password in each HTTP request.FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, String userId, String password, org.odpi.openmetadata.frameworks.auditlog.AuditLog auditLog) Create a new client that passes userId and password in each HTTP request.FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, DataManagerRESTClient restClient, int maxPageSize) Create a new client that is to be used within an OMAG Server.FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, org.odpi.openmetadata.frameworks.auditlog.AuditLog auditLog) Create a new client with no authentication embedded in the HTTP request. -
Method Summary
Modifier and TypeMethodDescriptionaddDataFileToCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, org.odpi.openmetadata.accessservices.datamanager.properties.DataFileProperties dataFileProperties, String connectorProviderName) Creates a new file asset and links it to the folder structure implied in the path name.addDataFileToCatalogFromTemplate(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String templateGUID, org.odpi.openmetadata.accessservices.datamanager.properties.TemplateProperties templateProperties) Add an asset description a file based on the content of a template object.addDataFolderToCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, org.odpi.openmetadata.accessservices.datamanager.properties.FileFolderProperties fileFolderProperties, String connectorProviderName) Creates a new folder asset that is identified as a data asset.addDataFolderToCatalogFromTemplate(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String templateGUID, org.odpi.openmetadata.accessservices.datamanager.properties.TemplateProperties templateProperties) Add an asset description a file based on the content of a template object.voidarchiveDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, org.odpi.openmetadata.accessservices.datamanager.properties.ArchiveProperties archiveProperties) Mark the file asset description in the catalog as archived.voidarchiveDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, org.odpi.openmetadata.accessservices.datamanager.properties.ArchiveProperties archiveProperties) Mark the data folder asset description in the catalog as archived.voidattachDataFileAssetToFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) Link an existing file asset to a folder.voidattachTopLevelFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String fileSystemGUID, String folderGUID) Links a folder to a file system.createNestedFolders(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String parentGUID, String pathName) Creates a new folder asset for each element in the pathName.voiddeleteDataFileFromCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, String fullPathname) Remove the file asset description from the catalog.voiddeleteDataFolderFromCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, String fullPathname) Remove the data folder asset description from the catalog.voiddetachDataFileAssetFromFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) Remove a link between a file asset and a folder.voiddetachTopLevelFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String fileSystemGUID, String folderGUID) Removed the link between a folder and a file system.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement>findFilesByPathName(String userId, String pathName, int startFrom, int pageSize) Retrieve data files by the supplied wildcard name.org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElementgetFileByGUID(String userId, String fileGUID) Retrieve a FolderProperties asset by its unique identifier (GUID).org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElementgetFileByPathName(String userId, String pathName) Retrieve a folder by its fully qualified path name.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement>getFilesByPathName(String userId, String pathName, int startFrom, int pageSize) Retrieve data files by the supplied wildcard name.org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElementgetFolderByGUID(String userId, String folderGUID) Retrieve a FolderProperties asset by its unique identifier (GUID).org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElementgetFolderByPathName(String userId, String pathName) Retrieve a folder by its fully qualified path name.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement>getFolderFiles(String userId, String folderGUID, int startFrom, int pageSize) Get the data files inside a folder - both those that are nested and those that are linked.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement>getNestedFolders(String userId, String parentFolderGUID, int startFrom, int pageSize) Return the list of folders nested inside a folder.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement>getTopLevelDataFiles(String userId, String fileSystemGUID, int startFrom, int pageSize) Return the list of folders nested inside a folder.List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement>getTopLevelFolders(String userId, String fileSystemGUID, int startFrom, int pageSize) Return the list of folders linked to the file server capability.voidmoveDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) Move a data file from its current parent folder to a new parent folder - this changes the file's qualified name but not its unique identifier (guid).voidmoveDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String dataFolderGUID) Move a data folder from its current parent folder to a new parent folder - this changes the folder's qualified name but not its unique identifier (guid).voidupdateDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, boolean isMergeUpdate, org.odpi.openmetadata.accessservices.datamanager.properties.DataFileProperties dataFileProperties) Update the file asset description in the catalog.voidupdateDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, boolean isMergeUpdate, org.odpi.openmetadata.accessservices.datamanager.properties.FileFolderProperties fileFolderProperties) Update the data folder asset description in the catalog.Methods inherited from class org.odpi.openmetadata.accessservices.datamanager.client.SchemaManagerClient
clearCalculatedValue, clearQueryTargetRelationship, clearSchemaElementRelationship, clearSchemaTypes, createEnumSchemaType, createLiteralSchemaType, createMapSchemaType, createPrimitiveSchemaType, createSchemaAttribute, createSchemaAttributeFromTemplate, createSchemaTypeChoice, createSchemaTypeFromTemplate, createStructSchemaType, findSchemaAttributes, findSchemaType, findValidValueSet, getNestedAttributes, getSchemaAttributeByGUID, getSchemaAttributesByName, getSchemaTypeByGUID, getSchemaTypeByName, getSchemaTypeForElement, getSchemaTypeParent, getValidValueSetByName, removeSchemaAttribute, removeSchemaType, setupCalculatedValue, setupQueryTargetRelationship, setupSchemaElementRelationship, setupSchemaType, updateQueryTargetRelationship, updateSchemaAttribute, updateSchemaTypeMethods inherited from class org.odpi.openmetadata.accessservices.datamanager.client.DataManagerBaseClient
removeReferenceable
-
Constructor Details
-
FilesAndFoldersClient
public FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, org.odpi.openmetadata.frameworks.auditlog.AuditLog auditLog) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException Create a new client with no authentication embedded in the HTTP request.- Parameters:
serverName- name of the server to connect toserverPlatformURLRoot- the network address of the server running the OMAS REST servicesauditLog- logging destination- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
FilesAndFoldersClient
public FilesAndFoldersClient(String serverName, String serverPlatformURLRoot) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException Create a new client with no authentication embedded in the HTTP request.- Parameters:
serverName- name of the server to connect toserverPlatformURLRoot- the network address of the server running the OMAS REST services- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
FilesAndFoldersClient
public FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, String userId, String password, org.odpi.openmetadata.frameworks.auditlog.AuditLog auditLog) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException Create a new client that passes userId and password in each HTTP request. This is the userId/password of the calling server. The end user's userId is sent on each request.- Parameters:
serverName- name of the server to connect toserverPlatformURLRoot- the network address of the server running the OMAS REST servicesuserId- caller's userId embedded in all HTTP requestspassword- caller's userId embedded in all HTTP requestsauditLog- logging destination- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
FilesAndFoldersClient
public FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, String userId, String password) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException Create a new client that passes userId and password in each HTTP request. This is the userId/password of the calling server. The end user's userId is sent on each request.- Parameters:
serverName- name of the server to connect toserverPlatformURLRoot- the network address of the server running the OMAS REST servicesuserId- caller's userId embedded in all HTTP requestspassword- caller's userId embedded in all HTTP requests- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
FilesAndFoldersClient
public FilesAndFoldersClient(String serverName, String serverPlatformURLRoot, DataManagerRESTClient restClient, int maxPageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException Create a new client that is to be used within an OMAG Server.- Parameters:
serverName- name of the server to connect toserverPlatformURLRoot- the network address of the server running the OMAS REST servicesrestClient- pre-initialized REST clientmaxPageSize- pre-initialized parameter limit- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- there is a problem with the information about the remote OMAS
-
-
Method Details
-
createNestedFolders
public List<String> createNestedFolders(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String parentGUID, String pathName) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Creates a new folder asset for each element in the pathName. For example, a pathName of "one/two/three" creates 3 new folder assets, one called "one", the next called "one/two" and the last one called "one/two/three".- Specified by:
createNestedFoldersin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullparentGUID- unique identifier of root object to connect the folder to (fileSystemGUID or folderGUID)pathName- pathname of the folder (or folders)- Returns:
- list of GUIDs from the top level to the leaf of the supplied pathname
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
attachTopLevelFolder
public void attachTopLevelFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String fileSystemGUID, String folderGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Links a folder to a file system. The folder is not changed.- Specified by:
attachTopLevelFolderin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfileSystemGUID- unique identifier of the file systemfolderGUID- unique identifier of the folder in the catalog- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
detachTopLevelFolder
public void detachTopLevelFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String fileSystemGUID, String folderGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Removed the link between a folder and a file system.- Specified by:
detachTopLevelFolderin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfileSystemGUID- unique identifier of the file systemfolderGUID- unique identifier of the folder in the catalog- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
addDataFileToCatalog
public List<String> addDataFileToCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, org.odpi.openmetadata.accessservices.datamanager.properties.DataFileProperties dataFileProperties, String connectorProviderName) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Creates a new file asset and links it to the folder structure implied in the path name. If the folder structure is not catalogued already, this is created automatically using the createFolderStructureInCatalog() method. For example, a pathName of "one/two/three/MyFile.txt" potentially creates 3 new folder assets, one called "one", the next called "one/two" and the last one called "one/two/three" plus a file asset called "one/two/three/MyFile.txt".- Specified by:
addDataFileToCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFileProperties- details of the data file to add to the catalog as an assetconnectorProviderName- class name of connector provider for connector to access this asset- Returns:
- list of GUIDs from the top level to the root of the pathname
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
addDataFileToCatalogFromTemplate
public List<String> addDataFileToCatalogFromTemplate(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String templateGUID, org.odpi.openmetadata.accessservices.datamanager.properties.TemplateProperties templateProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Add an asset description a file based on the content of a template object. Link this new asset to the folder structure implied in the path name. If the folder structure is not catalogued already, this is created automatically using the createFolderStructureInCatalog() method. For example, a pathName of "one/two/three/MyFile.txt" potentially creates 3 new folder assets, one called "one", the next called "one/two" and the last one called "one/two/three" plus a file asset called "one/two/three/MyFile.txt".- Specified by:
addDataFileToCatalogFromTemplatein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulltemplateGUID- unique identifier of the file asset to copytemplateProperties- override properties for the asset- Returns:
- list of GUIDs from the top level to the root of the pathname
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
updateDataFileInCatalog
public void updateDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, boolean isMergeUpdate, org.odpi.openmetadata.accessservices.datamanager.properties.DataFileProperties dataFileProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Update the file asset description in the catalog.- Specified by:
updateDataFileInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFileGUID- unique identifier of the data file assetisMergeUpdate- should the supplied properties completely override the existing properties or augment them?dataFileProperties- properties for the asset- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
archiveDataFileInCatalog
public void archiveDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, org.odpi.openmetadata.accessservices.datamanager.properties.ArchiveProperties archiveProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Mark the file asset description in the catalog as archived.- Specified by:
archiveDataFileInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFileGUID- unique identifier of the data file assetarchiveProperties- properties to help locate the archive copy- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
deleteDataFileFromCatalog
public void deleteDataFileFromCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFileGUID, String fullPathname) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Remove the file asset description from the catalog.- Specified by:
deleteDataFileFromCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFileGUID- unique identifier of the data file assetfullPathname- unique path and file name for file (optional)- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
addDataFolderToCatalog
public List<String> addDataFolderToCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, org.odpi.openmetadata.accessservices.datamanager.properties.FileFolderProperties fileFolderProperties, String connectorProviderName) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Creates a new folder asset that is identified as a data asset. This means the files and sub-folders within it collectively make up the contents of the data asset. As with other types of file-based asset, links are made to the folder structure implied in the path name. If the folder structure is not catalogued already, this is created automatically using the createFolderStructureInCatalog() method. For example, a pathName of "one/two/three/MyDataFolder" potentially creates 3 new folder assets, one called "one", the next called "one/two" and the last one called "one/two/three" plus a DataFolder asset called "one/two/three/MyDataFolder".- Specified by:
addDataFolderToCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfileFolderProperties- properties to describe the folder propertiesconnectorProviderName- class name of connector provider for connector to access this asset- Returns:
- list of GUIDs from the top level to the root of the pathname
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
addDataFolderToCatalogFromTemplate
public List<String> addDataFolderToCatalogFromTemplate(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String templateGUID, org.odpi.openmetadata.accessservices.datamanager.properties.TemplateProperties templateProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Add an asset description a file based on the content of a template object. Link this new asset to the folder structure implied in the path name. If the folder structure is not catalogued already, this is created automatically using the createFolderStructureInCatalog() method. For example, a pathName of "one/two/three/MyFile.txt" potentially creates 3 new folder assets, one called "one", the next called "one/two" and the last one called "one/two/three" plus a file asset called "one/two/three/MyFile.txt".- Specified by:
addDataFolderToCatalogFromTemplatein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulltemplateGUID- unique identifier of the file asset to copytemplateProperties- override properties for the asset- Returns:
- list of GUIDs from the top level to the root of the pathname
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
updateDataFolderInCatalog
public void updateDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, boolean isMergeUpdate, org.odpi.openmetadata.accessservices.datamanager.properties.FileFolderProperties fileFolderProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Update the data folder asset description in the catalog.- Specified by:
updateDataFolderInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFolderGUID- unique identifier of the data folder assetisMergeUpdate- should the supplied properties completely override the existing properties or augment them?fileFolderProperties- properties for the asset- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
archiveDataFolderInCatalog
public void archiveDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, org.odpi.openmetadata.accessservices.datamanager.properties.ArchiveProperties archiveProperties) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Mark the data folder asset description in the catalog as archived.- Specified by:
archiveDataFolderInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFolderGUID- unique identifier of the data folder assetarchiveProperties- properties to help locate the archive copy- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
deleteDataFolderFromCatalog
public void deleteDataFolderFromCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String dataFolderGUID, String fullPathname) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Remove the data folder asset description from the catalog.- Specified by:
deleteDataFolderFromCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling user (assumed to be the owner)fileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nulldataFolderGUID- unique identifier of the data folder assetfullPathname- unique path and file name for file (optional)- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
attachDataFileAssetToFolder
public void attachDataFileAssetToFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Link an existing file asset to a folder. The file is not changed as this is used to create a logical link to the folder.- Specified by:
attachDataFileAssetToFolderin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfolderGUID- unique identifier of the folderfileGUID- unique identifier of the file- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
detachDataFileAssetFromFolder
public void detachDataFileAssetFromFolder(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Remove a link between a file asset and a folder. The file is not changed. Use moveDataFileInCatalog to record the fact that the physical file has moved. Use attachDataFileAssetToFolder to create logical link to a new folder.- Specified by:
detachDataFileAssetFromFolderin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfolderGUID- unique identifier of the folderfileGUID- unique identifier of the file- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
moveDataFileInCatalog
public void moveDataFileInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String fileGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Move a data file from its current parent folder to a new parent folder - this changes the file's qualified name but not its unique identifier (guid). Similarly to the endpoint in the connection object.- Specified by:
moveDataFileInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfolderGUID- unique identifier of the folderfileGUID- unique identifier of the file- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
moveDataFolderInCatalog
public void moveDataFolderInCatalog(String userId, String fileManagerCapabilityGUID, String fileManagerCapabilityName, String folderGUID, String dataFolderGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Move a data folder from its current parent folder to a new parent folder - this changes the folder's qualified name but not its unique identifier (guid). Similarly to the endpoint in the connection object.- Specified by:
moveDataFolderInCatalogin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileManagerCapabilityGUID- unique identifier of the software server capability representing an owning external file manager or nullfileManagerCapabilityName- unique name of the software server capability representing an owning external file manager or nullfolderGUID- unique identifier of the folderdataFolderGUID- unique identifier of the data folder to move- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFolderByGUID
public org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement getFolderByGUID(String userId, String folderGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve a FolderProperties asset by its unique identifier (GUID).- Specified by:
getFolderByGUIDin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfolderGUID- unique identifier used to locate the folder- Returns:
- Folder properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFolderByPathName
public org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement getFolderByPathName(String userId, String pathName) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve a folder by its fully qualified path name.- Specified by:
getFolderByPathNamein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userpathName- path name- Returns:
- FolderProperties properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getTopLevelFolders
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement> getTopLevelFolders(String userId, String fileSystemGUID, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Return the list of folders linked to the file server capability.- Specified by:
getTopLevelFoldersin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileSystemGUID- unique identifier of the software server capability representing the file systemstartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of folder properties (null means no nested folders)
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getNestedFolders
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.FileFolderElement> getNestedFolders(String userId, String parentFolderGUID, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Return the list of folders nested inside a folder.- Specified by:
getNestedFoldersin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userparentFolderGUID- unique identifier of the parent folder or file systemstartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of folder properties (null means no nested folders)
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getTopLevelDataFiles
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement> getTopLevelDataFiles(String userId, String fileSystemGUID, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Return the list of folders nested inside a folder.- Specified by:
getTopLevelDataFilesin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileSystemGUID- unique identifier of the software server capability representing the file systemstartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of file properties (null means no top-level files)
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFolderFiles
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement> getFolderFiles(String userId, String folderGUID, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Get the data files inside a folder - both those that are nested and those that are linked.- Specified by:
getFolderFilesin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfolderGUID- unique identifier of the parent folderstartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of file properties (null means no files)
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFileByGUID
public org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement getFileByGUID(String userId, String fileGUID) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve a FolderProperties asset by its unique identifier (GUID).- Specified by:
getFileByGUIDin interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userfileGUID- unique identifier used to locate the folder- Returns:
- File properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFileByPathName
public org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement getFileByPathName(String userId, String pathName) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve a folder by its fully qualified path name.- Specified by:
getFileByPathNamein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userpathName- path name- Returns:
- File properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
getFilesByPathName
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement> getFilesByPathName(String userId, String pathName, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve data files by the supplied wildcard name. The wildcard is specified using regular expressions (RegEx) and the method matches on the pathName property.- Specified by:
getFilesByPathNamein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userpathName- path namestartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of matching file properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-
findFilesByPathName
public List<org.odpi.openmetadata.accessservices.datamanager.metadataelements.DataFileElement> findFilesByPathName(String userId, String pathName, int startFrom, int pageSize) throws org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException, org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException, org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException Retrieve data files by the supplied wildcard name. The wildcard is specified using regular expressions (RegEx) and the method matches on the qualifiedName, name and pathName property.- Specified by:
findFilesByPathNamein interfaceorg.odpi.openmetadata.accessservices.datamanager.api.FilesAndFoldersInterface- Parameters:
userId- calling userpathName- path namestartFrom- starting point in the listpageSize- maximum number of results- Returns:
- list of matching file properties
- Throws:
org.odpi.openmetadata.frameworks.connectors.ffdc.InvalidParameterException- one of the parameters is null or invalidorg.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException- problem accessing property serverorg.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException- security access problem
-