public interface DataHub
Modifier and Type | Method and Description |
---|---|
void |
clearDatabase(java.lang.String database)
Clears the database of all documents
|
void |
clearUserModules()
Removes user's modules from the modules db
|
void |
deleteDocument(java.lang.String uri,
DatabaseKind databaseKind)
Deletes document based on supplied doc uri in supplied database
|
FlowRunner |
getFlowRunner()
Creates and returns the FlowRunner object using the datahub's autowired hubconfig
|
java.lang.String |
getPortInUseBy(DatabaseKind kind)
Returns name of what is using the port
|
java.lang.String |
getServerVersion()
Returns the string presentation of the server version, eg: "9.03-1"
|
void |
initProject()
Initializes the project on disk, creates scaffold project code
|
void |
install()
Installs the data hub configuration and server-side config files into MarkLogic
Must be run as a user with sufficient privileges to install a data hub.
|
void |
install(HubDeployStatusListener listener)
Installs the data hub configuration and server-side config files into MarkLogic
Must be run as a user with sufficient privileges to install a data hub.
|
InstallInfo |
isInstalled()
Determines if the data hub is installed in MarkLogic
|
boolean |
isPortInUse(DatabaseKind kind)
Checks to see if the port is in use
|
boolean |
isSafeToInstall()
Checks to make sure all the versions and database in a valid configuration with version check
Must be run as a user with sufficient privileges to install a data hub.
|
boolean |
isServerVersionOk()
Checks to see if the datahub and server versions are compatible
|
boolean |
isServerVersionValid(java.lang.String versionString)
Validates the MarkLogic server to ensure compatibility with the hub
|
java.util.HashMap |
runPreInstallCheck()
Runs the pre-install check for the datahub populating the object
with variables necessary to perform the install.
|
void |
setPortInUseBy(DatabaseKind kind,
java.lang.String usedBy)
Sets what appserver name is using the port
|
void |
setServerVersion(java.lang.String serverVersion)
Sets the server version holder on the datahub object - currently unused
|
void |
setServerVersionOk(boolean serverVersionOk)
Sets true or false if the server version is okay with this version of DHF
|
void |
uninstall()
Uninstalls the data hub configuration, server-side config files and final databases and servers from MarkLogic
Must be run as a user with sufficient privileges to install a data hub.
|
void |
uninstall(HubDeployStatusListener listener)
Uninstalls the data hub configuration, server-side config files and final databases and servers from MarkLogic
Must be run as a user with sufficient privileges to install a data hub.
|
void |
updateIndexes()
Updates the indexes in the database based on the project
Must be run as a user with flow-developer-role or equivalent
|
boolean |
upgradeHub()
Upgrades the installed datahub on the server to this version of the DataHub
Must be run as a user with sufficient privileges to install a data hub.
|
void clearDatabase(java.lang.String database)
database
- - the name of the database in string formInstallInfo isInstalled()
boolean isServerVersionValid(java.lang.String versionString)
versionString
- - the version of the server to validateServerValidationException
- if the server is not compatiblevoid initProject()
void clearUserModules()
void deleteDocument(java.lang.String uri, DatabaseKind databaseKind)
uri
- - document uridatabaseKind
- - database typejava.util.HashMap runPreInstallCheck()
void install()
void install(HubDeployStatusListener listener)
listener
- - the callback method to receive status updatesvoid updateIndexes()
void uninstall()
void uninstall(HubDeployStatusListener listener)
listener
- - the callback method to receive status updatesboolean isSafeToInstall()
boolean isPortInUse(DatabaseKind kind)
kind
- - the DatabaseKind enum value (ex STAGING or JOB)void setPortInUseBy(DatabaseKind kind, java.lang.String usedBy)
kind
- - the DatabaseKind enum value (ex STAGING or JOB)usedBy
- - string name of what is using the portjava.lang.String getPortInUseBy(DatabaseKind kind)
kind
- - the DatabaseKind enum value (ex STAGING or JOB)boolean isServerVersionOk()
void setServerVersionOk(boolean serverVersionOk)
serverVersionOk
- - true if it compatible or false if it is notjava.lang.String getServerVersion()
void setServerVersion(java.lang.String serverVersion)
serverVersion
- - server version as a string, eg: "9.03-1"boolean upgradeHub() throws CantUpgradeException
CantUpgradeException
- - exception thrown when an upgrade can't happenFlowRunner getFlowRunner()