Interface VDPManager
- All Superinterfaces:
Serializable
Interface for clients to introspect a VDP Server
- Since:
- 5.0
-
Method Summary
Modifier and TypeMethodDescriptiongenerateOrderByExpressionWithPK(int vdpDataSourceID, String viewName) Returns a default ORDER BY expression generated from the selected view's PK.generateOrderByExpressionWithPK(int vdpDataSourceID, Collection<String> pkFields) Returns a default ORDER BY expression generated from the selected PK fields.getCatalogNames(int vdpDataSourceID) Returns a collection with the names of the catalogs/databases of the VDP Server defined by the identifier of the data source.getDateFieldsFromView(int vdpDataSourceID, String viewName) Returns the date-type fields of a VDP view.getElements(int vdpDataSourceID, VDPViewElementFilter elementFilter) Returns a collection of the elements of the database defined in elementFilter and VDP Server defined by the identifier of the data source.getFieldsFromView(int vdpDataSourceID, String viewName) Deprecated.Deprecated since 8.0u03.getIncrementalCacheStoredProcedureName(int vdpDataSourceID) Returns the name of the stored procedure for incremental cache load of the VDP Server defined by the identifier of the data source.getJDBCTableViewNamesByCatalog(int vdpDataSourceID, String catalogName) Deprecated.Deprecated since 8.0u03.getJDBCTableViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) Returns a collection with the names of the base views over a jdbc table of the VDP Server defined by the identifier of the data source.getPKFieldsFromView(int vdpDataSourceID, String viewName) Deprecated.Deprecated since 8.0u03.getSummaryViewNamesByCatalog(int vdpDataSourceID, String catalogName) Deprecated.Deprecated since 8.0u03.getSummaryViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) Returns a collection with the names of the base views over a summary of the VDP Server defined by the identifier of the data sourcegetTextFieldsFromView(int vdpDataSourceID, String viewName) Returns the text-type fields of a VDP view.Collection<com.denodo.util.Pair<String,String>> getVDPI18NList(int vdpDataSourceID) Returns a collection of i18n labels from the VDP Server using the data source identified by vdpDataSourceID.getVDPLocale(int vdpDataSourceID, String code) Returns the VDP Locale defined by code parameter from VDP Server using the data source identified by vdpDataSourceID.getViewInfo(int vdpDataSourceID, String viewName) Returns the creation query, pks and fields of a VDP view and which ones are mandatory.getViewNames(int vdpDataSourceID) Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.getViewNamesByCatalog(int vdpDataSourceID, String catalogName) Deprecated.Deprecated since 8.0u03.getViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.getViewsWithPKNames(int vdpDataSourceID) Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.getViewsWithPKNames(int vdpDataSourceID, String catalogName) Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.getViewsWithPKNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.validateQuery(int vdpDataSourceID, String query) Checks if a query is valid (without executing it).validateQuery(int vdpDataSourceID, String query, String contextOpts) Checks if a query is valid (without executing it).
-
Method Details
-
getViewNames
Collection<String> getViewNames(int vdpDataSourceID) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getViewsWithPKNames
Collection<String> getViewsWithPKNames(int vdpDataSourceID) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source. Only views which define a PK will be included in the result.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getViewsWithPKNames
Collection<String> getViewsWithPKNames(int vdpDataSourceID, String catalogName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source. Only views which define a PK will be included in the result.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database.- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getIncrementalCacheStoredProcedureName
String getIncrementalCacheStoredProcedureName(int vdpDataSourceID) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns the name of the stored procedure for incremental cache load of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.- Returns:
- the name of the stored procedure.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
generateOrderByExpressionWithPK
String generateOrderByExpressionWithPK(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a default ORDER BY expression generated from the selected view's PK. The expression will have the following structure:ORDER BY pk_field_1 ASC[, pk_field_n ASC]*. An empty string will be returned in case the selected view does not have a PK.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view.- Returns:
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
generateOrderByExpressionWithPK
String generateOrderByExpressionWithPK(int vdpDataSourceID, Collection<String> pkFields) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a default ORDER BY expression generated from the selected PK fields. The expression will have the following structure:ORDER BY pk_field_1 ASC[, pk_field_n ASC]*.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.pkFields- the PK fields to generate the ORDER BY expression.- Returns:
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getPKFieldsFromView
@Deprecated Collection<String> getPKFieldsFromView(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Deprecated.Deprecated since 8.0u03.Use
getViewInfo(int, String)instead.Returns the PK fields of a VDP view. If a PK is not defined for the selected view, the method returns an emtpy collection, nevernull.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view.- Returns:
- the fields of the view and which ones are mandatory.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getDateFieldsFromView
Collection<String> getDateFieldsFromView(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns the date-type fields of a VDP view. If there are none,, the method returns an emtpy collection, nevernull.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view.- Returns:
- the fields of the view and which ones are mandatory.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getTextFieldsFromView
Collection<String> getTextFieldsFromView(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns the text-type fields of a VDP view. If there are none,, the method returns an emtpy collection, nevernull.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view.- Returns:
- the fields of the view and which ones are mandatory.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getFieldsFromView
@Deprecated VDPViewFields getFieldsFromView(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Deprecated.Deprecated since 8.0u03.Use
getViewInfo(int, String)instead.Returns the fields of a VDP view and which ones are mandatory.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view.- Returns:
- the fields of the view and which ones are mandatory.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
validateQuery
String validateQuery(int vdpDataSourceID, String query) throws InstanceNotFoundException, VDPConnectException, InternalErrorException Checks if a query is valid (without executing it). By 'valid', we mean the query syntax is correct and there are conditions for every mandatory field (if any).- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.query- the query to test.- Returns:
- if the query is invalid, a
Stringwith the error message;null, otherwise. - Throws:
InstanceNotFoundException- if the data source does not exist.VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InternalErrorException- if an error occurs during the process.
-
validateQuery
String validateQuery(int vdpDataSourceID, String query, String contextOpts) throws InstanceNotFoundException, VDPConnectException, InternalErrorException Checks if a query is valid (without executing it). By 'valid', we mean the query syntax is correct and there are conditions for every mandatory field (if any).- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.query- the query to test.contextOpts- the query context options. For instance: "'prop1'='val1','propN'='valN'"- Returns:
- if the query is invalid, a
Stringwith the error message;null, otherwise. - Throws:
InstanceNotFoundException- if the data source does not exist.VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InternalErrorException- if an error occurs during the process.
-
getViewNamesByCatalog
@Deprecated Collection<String> getViewNamesByCatalog(int vdpDataSourceID, String catalogName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Deprecated.Deprecated since 8.0u03.Use
VDPManager#getViewNamesByCatalog(int, String, String)instead.Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databases- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getViewNamesByCatalogAndFilter
Collection<String> getViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databasesviewNameFilter- filters view names. null or empty string accepted if no filter needed- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getViewsWithPKNamesByCatalogAndFilter
Collection<String> getViewsWithPKNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the views (base and derived) of the VDP Server defined by the identifier of the data source. Only views which define a PK will be included in the result- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databasesviewNameFilter- filters view names. null or empty string accepted if no filter needed- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getJDBCTableViewNamesByCatalog
@Deprecated Collection<String> getJDBCTableViewNamesByCatalog(int vdpDataSourceID, String catalogName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Deprecated.Deprecated since 8.0u03.Use
VDPManager#getJDBCTableViewNamesByCatalog(int, String, String)instead.Returns a collection with the names of the base views over a jdbc table of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databases- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getJDBCTableViewNamesByCatalogAndFilter
Collection<String> getJDBCTableViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the base views over a jdbc table of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databasesviewNameFilter- filters view names. null or empty string accepted if no filter needed- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getSummaryViewNamesByCatalog
@Deprecated Collection<String> getSummaryViewNamesByCatalog(int vdpDataSourceID, String catalogName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Deprecated.Deprecated since 8.0u03.Use
VDPManager#getSummaryViewNamesByCatalog(int, String, String)instead.Returns a collection with the names of the base views over a summary of the VDP Server defined by the identifier of the data source- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databases- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getSummaryViewNamesByCatalogAndFilter
Collection<String> getSummaryViewNamesByCatalogAndFilter(int vdpDataSourceID, String catalogName, String viewNameFilter) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the base views over a summary of the VDP Server defined by the identifier of the data source- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.catalogName- the name of the database. null accepted to search all databasesviewNameFilter- filters view names. null or empty string accepted if no filter needed- Returns:
- the collection of view names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getViewInfo
VDPViewInfo getViewInfo(int vdpDataSourceID, String viewName) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns the creation query, pks and fields of a VDP view and which ones are mandatory.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.viewName- the name of the view. Can also contain the catalog using 'catalog.viewname' format.- Returns:
- the creation query, pks and fields of the view and which ones are mandatory.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getCatalogNames
Collection<String> getCatalogNames(int vdpDataSourceID) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection with the names of the catalogs/databases of the VDP Server defined by the identifier of the data source.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.- Returns:
- the collection of catalog names.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getElements
Collection<VDPViewElement> getElements(int vdpDataSourceID, VDPViewElementFilter elementFilter) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection of the elements of the database defined in elementFilter and VDP Server defined by the identifier of the data source. Used to obtain elements tree- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.elementFilter- data to filter retrieved elements, like name of database or subtype.- Returns:
- the collection of elements.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getVDPI18NList
Collection<com.denodo.util.Pair<String,String>> getVDPI18NList(int vdpDataSourceID) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns a collection of i18n labels from the VDP Server using the data source identified by vdpDataSourceID.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.- Returns:
- the collection of i18n.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-
getVDPLocale
VDPLocale getVDPLocale(int vdpDataSourceID, String code) throws VDPConnectException, InstanceNotFoundException, InternalErrorException Returns the VDP Locale defined by code parameter from VDP Server using the data source identified by vdpDataSourceID.- Parameters:
vdpDataSourceID- the identifier of the VDP data source created in Scheduler.code- code of the locale- Returns:
- the collection of i18n.
- Throws:
VDPConnectException- if a connection error occurs against VDP. Typically, the connection was refused remotely or the authentication was wrong.InstanceNotFoundException- if the data source does not exist.InternalErrorException- if an error occurs during the process.
-