izumi.distage.framework

Members list

Concise view

Type members

Classlikes

Represents distage apps that can be checked by izumi.distage.framework.PlanCheck at compile-time. CheckableApp must be inherited in a top-level object to be usable with PlanCheck

Represents distage apps that can be checked by izumi.distage.framework.PlanCheck at compile-time. CheckableApp must be inherited in a top-level object to be usable with PlanCheck

Role-based applications automatically inherit from RoleCheckableApp and can be checked out of the box.

Apps assembled directly using distage-core's distage.Injector will need to implement the interface manually, using CoreCheckableApp or CoreCheckableAppSimple

Attributes

See also:
Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Attributes

Companion:
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
abstract class CoreCheckableApp[F[_]](implicit val tagK: Tag[F]) extends CheckableApp

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
abstract class CoreCheckableAppSimple[F[_]] extends CoreCheckableApp[F]

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
object DebugProperties extends DebugProperties

Attributes

Graph
Supertypes
trait DebugProperties
class Object
trait Matchable
class Any
Self type
object PlanCheck

API for performing compile-time and runtime checks of correctness for distage applications.

API for performing compile-time and runtime checks of correctness for distage applications.

The easiest way to add compile-time safety to your application is to add an object inheriting PlanCheck.Main in test scope of the same module where you define your Role Launcher

Attributes

See also:
Example:
 import izumi.distage.framework.PlanCheck
 import com.example.myapp.MainLauncher
 object WiringCheck extends PlanCheck.Main(MainLauncher)

This object will emit compile-time errors for any issues or omissions in your ModuleDefs

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
final case class PlanCheckConfig[Roles <: String, ExcludeActivations <: String, Config <: String, CheckConfig <: Boolean, PrintBindings <: Boolean, OnlyWarn <: Boolean](roles: Roles, excludeActivations: ExcludeActivations, config: Config, checkConfig: CheckConfig, printBindings: PrintBindings, onlyWarn: OnlyWarn)

Options to alter the behavior of izumi.distage.framework.PlanCheck

Options to alter the behavior of izumi.distage.framework.PlanCheck

Attributes

checkConfig

Try to parse config file checking all the config bindings added using izumi.distage.config.ConfigModuleDef. Default: true

config

Config resource file name, e.g. "application.conf" or "*" if using the same config settings as roleAppMain

excludeActivations

"repo:dummy" to ignore missing implementations or other issues in repo:dummy axis choice. "repo:dummy | scene:managed" to ignore missing implementations or other issues in repo:dummy axis choice and in scene:managed axis choice. "repo:dummy mode:test | scene:managed" to ignore missing implementations or other issues in repo:dummy mode:test activation and in scene:managed activation. This will ignore parts of the graph accessible through these activations and larger activations that include them. That is, anything involving scene:managed or the combination of both repo:dummy mode:test will not be checked. but activations repo:prod mode:test scene:provided and repo:dummy mode:prod scene:provided are not excluded and will be checked. Allows the check to pass even if some axis choices or combinations of choices are (wilfully) left invalid, e.g. if you do have repo:prod components, but no counterpart repo:dummy components, and don't want to add them, then you may exclude "repo:dummy" from being checked.

onlyWarn

Do not abort compilation when errors are found, just print a warning instead. Does not affect plan checks performed at runtime. Default: false

printBindings

Print all the bindings loaded from plugins when a problem is found during plan checking. Default: false

roles

"" to check all roles, "role1 role2" to check specific roles, " -role1 -role2" to check all roles except specific roles.

Companion:
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
final case class PlanCheckMaterializer[AppMain <: CheckableApp, -Cfg <: Any](checkPassed: Boolean, checkedPlugins: Seq[ModuleBase], app: AppMain, roles: String, excludeActivations: String, config: String, checkConfig: Option[Boolean], printBindings: Option[Boolean], onlyWarn: Option[Boolean])

This implicit performs a compile-time check for a given distage-based App when materialized.

This implicit performs a compile-time check for a given distage-based App when materialized.

The reason to use an implicit macro for this, instead of a direct def-macro is because implicit macros are more compositional – you may write new functions using the implicit without writing new macros, by contrast macros can only be composed inside new macros – and this in turn requires separating them into different sbt modules.

Attributes

AppMain

The application to check, this should be a static object, most often a main object inherited from izumi.distage.roles.RoleAppMain

Cfg

Additional configuration options for compile-time checker

See also:
Companion:
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
abstract class RoleCheckableApp[F[_]](implicit val tagK: Tag[F]) extends CheckableApp

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes