Interface VDPManager

All Superinterfaces:
Serializable

public interface VDPManager extends Serializable
Interface for clients to introspect a VDP Server
Since:
5.0
  • Method Details

    • getViewNames

      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.
    • getViewsWithPKNames

      Collection<String> getViewsWithPKNames(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 databases
      viewNameFilter - 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.
    • 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.
    • 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, never null.
      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, never null.
      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 String with 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 String with 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.
    • getViewNames

      Collection<String> getViewNames(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 databases
      viewNameFilter - 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.
    • getJDBCTableViewNames

      Collection<String> getJDBCTableViewNames(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 databases
      viewNameFilter - 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.
    • getSummaryViewNames

      Collection<String> getSummaryViewNames(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 databases
      viewNameFilter - 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

      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

      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.