Interface IServiceInstanceDao

    • Method Detail

      • getIdsByChannelIdAndServiceId

        java.util.Collection<java.lang.String> getIdsByChannelIdAndServiceId​(java.lang.String channelId,
                                                                             java.lang.String serviceId,
                                                                             ITransaction transaction)
                                                                      throws DaoException,
                                                                             PortalException
        Get a list of ids in a given channel and of a given service. The channel or the service may be ommitted. In this case only the other condition will select the returned ids.
        Parameters:
        channelId -
        serviceId -
        transaction -
        Returns:
        Throws:
        DaoException
        PortalException
      • getCustomProperties

        java.util.HashMap<java.lang.String,​java.lang.String> getCustomProperties​(java.lang.String serviceInstanceId,
                                                                                       ITransaction daoTransaction)
                                                                                throws DaoException,
                                                                                       PortalException
        Get all service instance's custom properties.
        Parameters:
        serviceInstanceId -
        daoTransaction -
        Returns:
        Throws:
        DaoException
        PortalException
        Since:
        4.0.3
      • setCustomProperty

        void setCustomProperty​(java.lang.String serviceInstanceId,
                               java.lang.String name,
                               java.lang.String value,
                               ITransaction daoTransaction)
                        throws DaoException,
                               PortalException
        Set service instance´s custom property.
        Parameters:
        serviceInstanceId -
        name -
        value -
        transaction -
        Throws:
        DaoException
        PortalException
      • getIdsOfDependentServiceInstances

        java.util.Collection<java.lang.String> getIdsOfDependentServiceInstances​(java.lang.String serviceInstanceId,
                                                                                 ITransaction transaction)
                                                                          throws PortalException
        Get the ids of all service instances that depends on the given service instance.
        Parameters:
        serviceInstanceId - the service instance the returned service instances depend on.
        transaction - the transaction for persistence access.
        Returns:
        the dependent service instances.
        Throws:
        PortalException
      • getIdsByServiceInstanceAndDependencyType

        java.util.Collection<java.lang.String> getIdsByServiceInstanceAndDependencyType​(java.lang.String serviceInstanceId,
                                                                                        java.lang.String dependencyType,
                                                                                        ITransaction transaction)
                                                                                 throws DaoException,
                                                                                        PortalException
        Get the ids of the service instances that the given service instance depends on by the given dependency type.
        Parameters:
        serviceInstanceId - the id of the service instance that depends on the returned service instances.
        dependencyType - the type of dependency.
        transaction - the transaction for persistence access.
        Returns:
        the ids of the service instances that the given service instance depends on by the given dependency type.
        Throws:
        ManagerException
        PortalException
        DaoException
      • addServiceInstanceDependency

        void addServiceInstanceDependency​(ServiceInstanceDependencyConfig serviceInstanceDependencyConfig,
                                          ITransaction transaction)
                                   throws PortalException
        Add the given service instance dependency to the persistence.
        Parameters:
        serviceInstanceDependencyConfig - the information about the dependency to be added.
        transaction - the transaction for persistence access.
        Throws:
        PortalException
      • removeServiceInstanceDependencies

        void removeServiceInstanceDependencies​(java.lang.String dependentServiceInstanceId,
                                               java.lang.String dependencyType,
                                               ITransaction transaction)
                                        throws PortalException
        Remove the service instance dependencies that matches the dependent service instance id and dependency type given.
        Parameters:
        dependentServiceInstanceId -
        dependencyType -
        transaction -
        Throws:
        PortalException
      • getDependencyIdsByServiceInstanceId

        java.util.Collection<java.lang.String> getDependencyIdsByServiceInstanceId​(java.lang.String serviceInstanceId,
                                                                                   ITransaction transaction)
                                                                            throws DaoException,
                                                                                   PortalException
        Get the ids of all the service instances that the given service instance depends on
        Parameters:
        serviceInstanceId -
        transaction -
        Returns:
        the ids of the service instances that the given service instance depends on.
        Throws:
        DaoException
        PortalException
      • getByRestShortName

        ServiceInstanceConfig getByRestShortName​(java.lang.String restShortName,
                                                 ITransaction transaction)
                                          throws DaoException,
                                                 PortalException
        Get the service's instance by rest short name, only for valid service instance.
        Parameters:
        restShortName - rest short name of the service instance.
        transaction - transaction used to perform the query.
        Returns:
        the serviceInstanceConfig that represents the service instance.
        Throws:
        DaoException - if any database error occurs during the process.
        PortalException - if any other error occurs during the process.
      • getServiceInstancesIdsByAutoAdminPageId

        java.util.Collection<java.lang.String> getServiceInstancesIdsByAutoAdminPageId​(java.lang.String pageId,
                                                                                       ITransaction transaction)
                                                                                throws PortalException
        Returns a collection of serviceInstanceIds that contain the pageid as its auto administration page.
        Parameters:
        pageId - to list the service instance ids by.
        transaction - the transaction in which the operation should happen
        Returns:
        collection of serviceInstanceIds that contain the pageid as its auto administration page.
        Throws:
        PortalException
        Since:
        7.0.0
      • getDependenciesOfDependentServiceInstances

        java.util.Map<java.lang.String,​java.util.Set<java.lang.String>> getDependenciesOfDependentServiceInstances​(java.lang.String serviceInstanceId,
                                                                                                                         ITransaction transaction)
                                                                                                                  throws PortalException
        Returns a map with all the dependencies of a given service instance (grouped by the dependency type).
        Parameters:
        serviceInstanceId - the dependent service instance id.
        transaction - the transaction.
        Returns:
        a map with all the dependencies of a given service instance (grouped by the dependency type).
        Throws:
        PortalException
        Since:
        14.1.0