dataproduct¶
A dataproduct
in ALFA defines a contract that a data domain owner will adhere to. Data products define what is published and consumed by the data domain along with related metadata.
ALFA users may consider using dataproduct
once they have a set of entity
/record
/enum
/service
etc. definitions, and want to present a subset of those as an ‘external view’ of the data they control.
It enables you to manage how your domain interacts with those outside.
Similar to defining a service making use of existing model types, a dataproduct
is created referencing defined models and annotations. This ensures a Data Product is a core concept of the data domain, is always maintained, validated and in sync.
The dataproduct
definition can be exported as JSON and can be used to drive external configuration and applications to adhere to contracts defined for the data domain.
Syntax¶
The following syntax is used to define a dataproduct
.
Each dataproduct
defines what it publishes. What is published becomes what can be defined as being consumed by another dataproduct
.
Annotations can be used to add metadata at any level.
dataproduct <NAME>
{
publish
{
<LIST OF TYPES>
}
consume
{
<SOURCE DATAPRODUCT>
{
<LIST OF TYPES>
}
}
}
A subset of a dataproduct
definition is shown below:
@Owner( "TradeTeam" )
dataproduct Trade
{
publish
{
@SourceSystem("FixedIncomeSystem")
@Interface(Type=InterfaceType.Queue, SubType="Kafka")
@SLA(Frequency=FrequencyType.Realtime)
Bond
@SourceSystem("FixedIncomeSystem")
@Interface(Type=InterfaceType.Queue, SubType="Kafka")
@SLA(Frequency=FrequencyType.Hourly)
CreditDefaultSwap
@SourceSystem("CommoSystem")
@Interface(Type=InterfaceType.Queue, SubType="Kafka")
@SLA(Frequency=FrequencyType.Realtime)
Forward
}
consume {
alfabank.dataproducts.common.Common {
alfabank.dataproducts.common.Currency
alfabank.dataproducts.common.Country
}
}
}
Data Products can be federated to data domain owners. They get aggregated and displayed in ALFA Documentation as shown below.
Viewable at https://alfa-demo.github.io/dataproduct-trade/edm-index.html.