Mapa mental
Data fragmentation
Contenido del mapa
Data fragmentation
Correct if we guarantee
- Completeness
- Given a relation R and a set of fragments, any data item (either a tuple or a set of attributes) of R can be found in at least one fragment. Thus, data are not lost when fragmenting
- Disjointness
- Given a relation R and a set of fragments, any data item placed in a fragment cannot be found in any of the other fragments. Re- member that data replication must be considered a posteriori, in the allo- cation stage, as a task independent of data fragmentation
- Reconstruction
- Given a relation R and a set of fragments, the original re- lation can always be reconstructed from the fragments by means of rela- tional algebraic operators
- Completeness
Horizontal fragmentation
- A selection predicate is used to create different fragments and, according to an attribute value, place each tuple in the corresponding fragment.
- Example
- We want to geographically distribute data about projects
- The predicates to be used would be city = NAME_CITY (where NAME_CITY is each of the city attribute values: Barcelona, Hong Kong, Portland, Glasgow or Frankfurt). Each predicate will result in a fragment
- We want to geographically distribute data about projects
- When
- When it needs to mirror geographically distributed data (each node main- ly accesses data related to itself)
- Facilitate recovery and parallelism
- Reduce the depth of indexes (since each fragment has its own index, the number of indexes increases but their size is reduced
- Reduce contention
- Contention occurs when we are denied access to a database resource because of conflicts with other users, normally related to concurrency control techniques
- Since several mutually exclusive users, who work on different nodes, can access different fragments simultaneously and no conflicts will be caused
- When it needs to mirror geographically distributed data (each node main- ly accesses data related to itself)
- What extend should we fragment?
Vertical fragmentation
- Example
- We want to store the name , city and country attributes at each node, whereas the other data will be stored at the Hong Kong head office.
- project(pno,name,city,country) and project(pno,budget,category,productivityRatio,income)
- We want to store the name , city and country attributes at each node, whereas the other data will be stored at the Hong Kong head office.
- Example
Hybrid fragmentation
- Combines both techniques
- Further fragmenting fragments produced by a previous fragmentation strategy
- Example
- We want to geographically distribute data about projects, but only those attributes of interest at each node (the others will be stored in Hong Kong)
- VF 1 ( ∏ project(pno,name,city,country) ) and ......................................... VF 2 ( ∏ project(pno,budget,category,productivityRatio,income) )
- VF 2 will be placed at the Hong Kong node,
- VF 1 will be further fragmented by applying the horizontal fragmentation (i.e., city = NAME_CITY)
- VF 1 ( ∏ project(pno,name,city,country) ) and ......................................... VF 2 ( ∏ project(pno,budget,category,productivityRatio,income) )
- We want to geographically distribute data about projects, but only those attributes of interest at each node (the others will be stored in Hong Kong)
- Combines both techniques
Información
- Descripción
- Informática Mapa Mental sobre Data fragmentation, creado por Roger Martin Campanario el 21/09/2018.
- Creado por
- Roger Martin Campanario
- Visitas
- 0
- Valoración