Class Celesta

    • Method Detail

      • getSetupProperties

        public Properties getSetupProperties()
        Description copied from interface: ICelesta
        Returns properties that were used to initialize Celesta. Attention: it makes sense using this object as read only, dynamic change of these properties does lead to nothing.
        Specified by:
        getSetupProperties in interface ICelesta
      • getProfiler

        public IProfiler getProfiler()
        Description copied from interface: ICelesta
        Returns a IProfiler of this celesta instance.
        Specified by:
        getProfiler in interface ICelesta
        Returns:
        a profiler of this celesta instance.
      • getDBAdaptor

        public DBAdaptor getDBAdaptor()
        Description copied from interface: ICelesta
        Returns a DBAdaptor of this celesta instance.
        Specified by:
        getDBAdaptor in interface ICelesta
        Returns:
        a db adaptor of this celesta instance.
      • getScore

        public Score getScore()
        Description copied from interface: ICelesta
        Returns Celesta metadata (tables description).
        Specified by:
        getScore in interface ICelesta
      • close

        public void close()
        Stops working of Celesta. After the call the instance of Celesta becomes unusable.
        Specified by:
        close in interface AutoCloseable
      • createInstance

        public static Celesta createInstance​(Properties properties,
                                             DataSource dataSource)
        Creates Celesta instance with specified properties and DataSource.
        Parameters:
        properties - Celesta initialization properties. All the properties regarding db connection will be ignored, but rdbms.connection.url is still required in order for Celesta to define the database type (you may pass only the prefix, e. g. jdbc:postgresql)
        dataSource - Provided data source.
        Returns:
      • createInstance

        public static Celesta createInstance​(Properties properties,
                                             ConnectionPool connectionPool)
        Creates Celesta instance with specified properties and ConnectionPool.
        Parameters:
        properties - Celesta initialization properties. All the properties regarding db connection will be ignored, but rdbms.connection.url is still required in order for Celesta to define the database type (you may pass only the prefix, e. g. jdbc:postgresql)
        connectionPool - Provided connection pool (either DatasourceConnectionPool or InternalConnectionPool).
        Returns:
      • createInstance

        public static Celesta createInstance​(Properties properties)
        Creates Celesta instance with the specified properties and internal connection pool.
        Parameters:
        properties - Celesta initialization properties
        Returns:
      • createInstance

        public static Celesta createInstance()
        Creates Celesta instance with properties specified in celesta.properties file.
        Returns:
      • loadPropertiesDynamically

        public static Properties loadPropertiesDynamically()
        Reads and returns properties from celesta.properties file.
        Returns:
      • isProfilemode

        public boolean isProfilemode()
        Returns if profiling mode is set (whether the time of method calls is written to 'calllog' table).
        Returns:
      • nullsFirst

        public boolean nullsFirst()
        Returns the behavior NULLS FIRST of current database.
        Returns:
      • setProfilemode

        public void setProfilemode​(boolean profilemode)
        Sets profiling mode.
        Parameters:
        profilemode - profiling mode