Packages

case class ChainAppConfig(directory: Path, confs: Config*)(implicit ec: ExecutionContext) extends DbAppConfig with ChainDbManagement with JdbcProfileComponent[ChainAppConfig] with Product with Serializable

Configuration for the Bitcoin-S chain verification module

directory

The data directory of the module

confs

Optional sequence of configuration overrides

Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ChainAppConfig
  2. Serializable
  3. Product
  4. Equals
  5. JdbcProfileComponent
  6. ChainDbManagement
  7. DbManagement
  8. DbAppConfig
  9. AppConfig
  10. Logging
  11. StartStopAsync
  12. StartStop
  13. AnyRef
  14. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new ChainAppConfig(directory: Path, confs: Config*)(implicit ec: ExecutionContext)

    directory

    The data directory of the module

    confs

    Optional sequence of configuration overrides

Type Members

  1. type ConfigType = ChainAppConfig

    Sub members of AppConfig should override this type with the type of themselves, ensuring withOverrides return the correct type

    Sub members of AppConfig should override this type with the type of themselves, ensuring withOverrides return the correct type

    Attributes
    protected[bitcoins]
    Definition Classes
    ChainAppConfigAppConfig

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def addCallbacks(newCallbacks: ChainCallbacks): ChainCallbacks
  5. lazy val allTables: List[slick.jdbc.JdbcProfile.API.TableQuery[slick.jdbc.JdbcProfile.API.Table[_]]]
    Definition Classes
    ChainDbManagementDbManagement
  6. lazy val appConfig: ChainAppConfig
    Definition Classes
    ChainAppConfigJdbcProfileComponent
  7. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  8. def baseDatadir: Path

    The base data directory.

    The base data directory. This is where we look for a configuration file

    Attributes
    protected[bitcoins]
    Definition Classes
    ChainAppConfigAppConfig
  9. lazy val chain: BitcoinChainParams

    Chain parameters for the blockchain we're on

    Chain parameters for the blockchain we're on

    Definition Classes
    AppConfig
  10. def chainCallbacks: ChainCallbacks
  11. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  12. lazy val config: Config
    Attributes
    protected
    Definition Classes
    AppConfig
  13. def configOverrides: List[Config]

    List of user-provided configs that should override defaults

    List of user-provided configs that should override defaults

    Attributes
    protected[bitcoins]
    Definition Classes
    ChainAppConfigAppConfig
  14. def createSchema(createIfNotExists: Boolean = true)(implicit ec: ExecutionContext): Future[Unit]
    Definition Classes
    DbManagement
  15. def createTable(table: slick.jdbc.JdbcProfile.API.TableQuery[_ <: slick.jdbc.JdbcProfile.API.Table[_]], createIfNotExists: Boolean = true)(implicit ec: ExecutionContext): Future[Unit]

    Creates the given table

    Creates the given table

    Definition Classes
    DbManagement
  16. lazy val database: slick.jdbc.JdbcProfile.API.Database

    The database we are connecting to

    The database we are connecting to

    Definition Classes
    JdbcProfileComponent
  17. lazy val datadir: Path

    The network specific data directory.

    The network specific data directory.

    Definition Classes
    AppConfig
  18. lazy val dbConfig: DatabaseConfig[JdbcProfile]

    The configuration details for connecting/using the database for our projects that require database connections

    The configuration details for connecting/using the database for our projects that require database connections

    Definition Classes
    JdbcProfileComponent
  19. lazy val dbHost: String

    The host of our postgresql database

    The host of our postgresql database

    Definition Classes
    DbAppConfig
  20. lazy val dbName: String

    The name of our database

    The name of our database

    Definition Classes
    DbAppConfig
  21. lazy val dbPath: Path

    The path where our DB is located

    The path where our DB is located

    Definition Classes
    DbAppConfig
  22. lazy val dbPort: Int

    The port number of our postgresql database

    The port number of our postgresql database

    Definition Classes
    DbAppConfig
  23. def debug(mkr: Marker, msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  24. def debug(msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  25. def debug(msg: => Any): Unit
    Attributes
    protected
    Definition Classes
    Logging
  26. lazy val driver: DatabaseDriver
    Definition Classes
    DbAppConfig
  27. def dropAll()(implicit ec: ExecutionContext): Future[Unit]
    Definition Classes
    DbManagement
  28. def dropTable(tableName: String)(implicit ec: ExecutionContext): Future[Int]
    Definition Classes
    DbManagement
  29. def dropTable(table: slick.jdbc.JdbcProfile.API.TableQuery[slick.jdbc.JdbcProfile.API.Table[_]]): Future[Unit]
    Definition Classes
    DbManagement
  30. implicit val ec: ExecutionContext
    Definition Classes
    ChainAppConfigChainDbManagement
  31. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  32. def error(mkr: Marker, msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  33. def error(msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  34. def error(msg: => Any): Unit
    Attributes
    protected
    Definition Classes
    Logging
  35. lazy val filterBatchSize: Int
  36. lazy val filterHeaderBatchSize: Int
  37. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  38. lazy val forceRecalcChainWork: Boolean
  39. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  40. def getConfigString(path: String): String
    Definition Classes
    AppConfig
  41. def getConfigStringOpt(path: String): Option[String]
    Definition Classes
    AppConfig
  42. lazy val hikariLoggingInterval: Option[Duration]

    Gets how often we should log hikari connection pool stats if None, this means isHikariLoggingEnabled is not enabled

    Gets how often we should log hikari connection pool stats if None, this means isHikariLoggingEnabled is not enabled

    Definition Classes
    DbAppConfig
  43. def info(): MigrationInfoService

    Returns flyway information about the state of migrations

    Returns flyway information about the state of migrations

    Definition Classes
    DbManagement
    See also

    https://flywaydb.org/documentation/command/info

  44. def info(mkr: Marker, msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  45. def info(msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  46. def info(msg: => Any): Unit
    Attributes
    protected
    Definition Classes
    Logging
  47. def isDebugEnabled: Boolean
    Attributes
    protected
    Definition Classes
    Logging
  48. def isErrorEnabled: Boolean
    Attributes
    protected
    Definition Classes
    Logging
  49. lazy val isHikariLoggingEnabled: Boolean
    Definition Classes
    DbAppConfig
  50. def isInfoEnabled: Boolean
    Attributes
    protected
    Definition Classes
    Logging
  51. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  52. def isStarted(): Future[Boolean]

    Checks whether or not the chain project is initialized by trying to read the genesis block header from our block header table

  53. def isTraceEnabled: Boolean
    Attributes
    protected
    Definition Classes
    Logging
  54. def isWarnEnabled: Boolean
    Attributes
    protected
    Definition Classes
    Logging
  55. lazy val jdbcUrl: String
    Definition Classes
    DbAppConfig
  56. def logger: Logger
    Attributes
    protected
    Definition Classes
    Logging
  57. def loggerName: String
    Attributes
    protected
    Definition Classes
    Logging
  58. def migrate(): Int

    Executes migrations related to this database

    Executes migrations related to this database

    Definition Classes
    DbManagement
    See also

    https://flywaydb.org/documentation/api/#programmatic-configuration-java

  59. def migrationsApplied(): Int
    Definition Classes
    DbManagement
  60. def moduleName: String

    Name of the module.

    Name of the module. chain, wallet, node etc.

    Attributes
    protected[bitcoins]
    Definition Classes
    ChainAppConfigAppConfig
  61. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  62. lazy val network: BitcoinNetwork

    The blockchain network we're on

    The blockchain network we're on

    Definition Classes
    AppConfig
  63. def newConfigOfType(configs: Seq[Config]): ChainAppConfig

    Constructor to make a new instance of this config type

    Constructor to make a new instance of this config type

    Attributes
    protected[bitcoins]
    Definition Classes
    ChainAppConfigAppConfig
  64. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  65. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  66. lazy val numThreads: Int
    Definition Classes
    JdbcProfileComponent
  67. lazy val password: String
    Definition Classes
    JdbcProfileComponent
  68. def productElementNames: Iterator[String]
    Definition Classes
    Product
  69. lazy val profile: JdbcProfile
    Definition Classes
    JdbcProfileComponent
  70. lazy val schemaName: Option[String]
    Definition Classes
    DbAppConfig
  71. lazy val slickDbConfig: DatabaseConfig[JdbcProfile]
    Definition Classes
    DbAppConfig
  72. def start(): Future[Unit]

    Initializes our chain project if it is needed This creates the necessary tables for the chain project and inserts preliminary data like the genesis block header

    Initializes our chain project if it is needed This creates the necessary tables for the chain project and inserts preliminary data like the genesis block header

    Definition Classes
    ChainAppConfigAppConfigStartStop
  73. def startHikariLogger(interval: Duration): HikariLogging

    Starts the background logger for hikari

    Starts the background logger for hikari

    interval

    - how often hikari logs database connection pool information

    Attributes
    protected
    Definition Classes
    JdbcProfileComponent
  74. def stop(): Future[Unit]

    Releases the thread pool associated with this AppConfig's DB

    Releases the thread pool associated with this AppConfig's DB

    Definition Classes
    ChainAppConfigDbAppConfigStartStop
  75. def stopHikariLogger(): Unit
    Attributes
    protected
    Definition Classes
    JdbcProfileComponent
  76. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  77. implicit def tableQueryToWithSchema(tableQuery: slick.jdbc.JdbcProfile.API.TableQuery[_]): slick.jdbc.JdbcProfile.API.TableQuery[slick.jdbc.JdbcProfile.API.Table[_]]

    Internally, slick defines the schema member as

    Internally, slick defines the schema member as

    def schema: SchemaDescription = buildTableSchemaDescription(q.shaped.value.asInstanceOf[Table[_]])

    we need to cast between TableQuery's of specific table types to the more generic TableQuery[Table[_]] to get methods in this trait working as they require schema (which essentially does this cast anyway)

    This cast is needed because TableQuery is not covariant in its type parameter. However, since Query is covariant in its first type parameter, I believe the cast from TableQuery[T1] to TableQuery[T2] will always be safe so long as T1 is a subtype of T2 AND T1#TableElementType is equal to T2#TableElementType.

    The above conditions are always the case when this is called in the current code base and will stay that way so long as no one tries anything too fancy.

    Attributes
    protected
    Definition Classes
    DbManagement
  78. def trace(mkr: Marker, msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  79. def trace(msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  80. def trace(msg: => Any): Unit
    Attributes
    protected
    Definition Classes
    Logging
  81. lazy val username: String
    Definition Classes
    JdbcProfileComponent
  82. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  83. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  84. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  85. def warn(mkr: Marker, msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  86. def warn(msg: => Any, t: => Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  87. def warn(msg: => Any): Unit
    Attributes
    protected
    Definition Classes
    Logging
  88. def withOverrides(config: Config, configs: Config*): ConfigType

    This method returns a new AppConfig, where every key under bitcoin-s overrides the configuration picked up by other means (the reference.conf provided by bitcoin-s and the application.conf provided by the user).

    This method returns a new AppConfig, where every key under bitcoin-s overrides the configuration picked up by other means (the reference.conf provided by bitcoin-s and the application.conf provided by the user). If you pass in configs with overlapping keys (e.g. several configs with the key bitcoin-s.network), the latter config overrides the first.

    Definition Classes
    AppConfig

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from ChainDbManagement

Inherited from DbManagement

Inherited from DbAppConfig

Inherited from AppConfig

Inherited from Logging

Inherited from StartStopAsync[Unit]

Inherited from StartStop[Future[Unit]]

Inherited from AnyRef

Inherited from Any

Ungrouped