• Save
Hibernate Shards
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Hibernate Shards

on

  • 926 views

Topiconf 2007

Topiconf 2007

Statistics

Views

Total Views
926
Views on SlideShare
921
Embed Views
5

Actions

Likes
0
Downloads
0
Comments
0

2 Embeds 5

http://www.linkedin.com 4
https://www.linkedin.com 1

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Hibernate Shards Presentation Transcript

  • 1. (N)Hibernate Shards Topicus & (Distributed) Databases
  • 2. Wattes?
    • "You can't always put all your relational data in a single relational database. Sometimes you simply have too much data... Whatever your reasons, talking to multiple relational databases inevitably complicates the development of your application.“
    • http://www.hibernate.org/414.html
    07-06-09
  • 3. Hibernate Shards
    • Standard Hibernate programming model
    • Flexible sharding strategies
      • ShardAccessStrategy
      • ShardResolutionStrategy
      • ShardSelectionStrategy
    • Support for virtual shards (Resharding)
    • Free/open source
    07-06-09
  • 4. Hibernate Shards
    • Hibernate + Shards
    •  
    • ShardedSession
    • ShardedSessionFactory
    • ShardedCriteria
    • ShardedQuery
    • Hibernate
    • Session
    • SessionFactory
    • Criteria
    • Query
    1 2 1
  • 5. Recipe for Hibernate Shards
    • Definieer de shards in de configuratie
    • Definieer de Id generator in mappings
      • ShardedTableHiLoGenerator
      • ShardedUUIDGenerator
    • Instantieer de ShardStrategyFactory
    • Gebruik de sharded factory op de plaats van de gewone
  • 6. Distributed?
    • Virtual Shards (Gevaarlijk!)
    • Welk object moet waar?
    • Wat moeten we doen als we mappings aan moeten passen??
    • Tip: Vooraf extra virtual shards
  • 7. Nadelen
    • Id generatie werkt niet via JPA
    • A en B (met een relatie tussen elkaar) mogen niet op aparte shards leven.
    • Base types niet als identifier
    • Replicated data alleen read-only.
    • Sorteren in criteria kan niet
    • Geen HQL.
  • 8. Vragen
    • ?
    07-06-09