Interface BusinessDataModelRepository

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void dropAndUninstall​(long tenantId)  
      org.bonitasoft.engine.bdm.model.BusinessObjectModel getBusinessObjectModel()
      Returns the currently deployed Business Object Data Model, or null if no BDM is deployed.
      byte[] getClientBDMZip()
      Retrieve the client side BDM generated zip.
      java.lang.String getInstalledBDMVersion()
      Returns the currently deployed BDM version, or null if no BDM is deployed.
      java.lang.String install​(byte[] bdmArchive, long userId)
      Deploys a Business Data Model / repository on the specified tenant.
      boolean isBDMDeployed()  
      boolean isDeployed​(byte[] bdmArchive)
      Determine if the given BDM archive is equivalent to the currently deployed BDM.
      void uninstall​(long tenantId)
      Undeploy Business Data Model from specified tenant
    • Method Detail

      • install

        java.lang.String install​(byte[] bdmArchive,
                                 long userId)
                          throws SBusinessDataRepositoryDeploymentException,
                                 org.bonitasoft.engine.business.data.InvalidBusinessDataModelException
        Deploys a Business Data Model / repository on the specified tenant.
        Parameters:
        bdmArchive - the Business Data Model, as a jar containing the Business Object classes to deploy.
        userId - the ID of the user installing the BDM, typically tenant admin (id=-1)
        Returns:
        the version of the BDM just deployed.
        Throws:
        SBusinessDataRepositoryDeploymentException - if a deployment exception occurs.
        org.bonitasoft.engine.business.data.InvalidBusinessDataModelException
      • isBDMDeployed

        boolean isBDMDeployed()
      • getInstalledBDMVersion

        java.lang.String getInstalledBDMVersion()
                                         throws SBusinessDataRepositoryException
        Returns the currently deployed BDM version, or null if no BDM is deployed.
        Returns:
        the currently deployed BDM version, or null if no BDM is deployed.
        Throws:
        SBusinessDataRepositoryException - if the BDM cannot be retrieved.
      • getBusinessObjectModel

        org.bonitasoft.engine.bdm.model.BusinessObjectModel getBusinessObjectModel()
                                                                            throws SBusinessDataRepositoryException
        Returns the currently deployed Business Object Data Model, or null if no BDM is deployed.
        Returns:
        the currently deployed Business Object Data Model, or null if no BDM is deployed.
        Throws:
        SBusinessDataRepositoryException - if the BDM cannot be retrieved.
      • isDeployed

        boolean isDeployed​(byte[] bdmArchive)
                    throws org.bonitasoft.engine.business.data.InvalidBusinessDataModelException,
                           SBusinessDataRepositoryDeploymentException
        Determine if the given BDM archive is equivalent to the currently deployed BDM.
        Parameters:
        bdmArchive - the Business Data Model, as a zip containing the Business Object Model.
        Returns:
        true If the given BDM archive is the same as the one already deployed. False otherwise.
        Throws:
        org.bonitasoft.engine.business.data.InvalidBusinessDataModelException - if the given BDM archive is invalid
        SBusinessDataRepositoryDeploymentException - if the server jar generation of the given BDM fails