Presentation is loading. Please wait.

Presentation is loading. Please wait.

Angela M. Carthan Advanced Database Systems CSC 8712 Georgia State University Department of Computer Science Technology 15 April 2008 Embedded Database.

Similar presentations

Presentation on theme: "Angela M. Carthan Advanced Database Systems CSC 8712 Georgia State University Department of Computer Science Technology 15 April 2008 Embedded Database."— Presentation transcript:

1 Angela M. Carthan Advanced Database Systems CSC 8712 Georgia State University Department of Computer Science Technology 15 April 2008 Embedded Database Management Systems

2 Outline What are Embedded Database Management (EDBM) Systems? Embedded Database vs. Regular Database Systems Real Time Database for Embedded Systems Embedding the db4o Object-Oriented Database Reducing Energy Consumption of Queries in Memory-resident Database Systems Storage Elasped Time Object Analysis Patterns for Embedded Systems

3 Introduction Embedded DBMS vs. regular DBMS??? Handling Complex Operations Disk Storage Space Expectations for user have gone up Size Cost Newer Design Growth in Memory Technology Data being shifted from memory to disk DBMS capabilities are improving nowadays

4 What are Embedded Database Management Systems? Embedded Systems- A specialized computer system that is part of a larger system. Housed on a single microprocessor board with the programs stored in ROM. All appliances that have a digital interface watches microwaves, VCRs, cars -- utilize embedded systems Embedded Database Systems- A database management system (DBMS) embedded into an application. Introduced in 1980s The first embedded databases largely 8-bit, or possibly 16-bit Nowadays EDBMS matured and gained faster (32-bit) processors, memory, and more complexity.

5 Diagram of Embedded Storage

6 Real Time Database for Embedded Systems Often assumed that fast data processing engine, meets real- time requirements. Input data must be correlated, merged, or compared. Data must be shared by concurrent tasks with different functions, time requirements and degrees of importance. Real Time systems use DBMS as a part of the architecture Simplify design Streamline development Improve performance.


8 Current Usage of RTDMS using Embedded Systems McObjects eXtremeDB - the latest commercial addition to family of EDB for real time-systems. Eliminate performance overhead while providing a predictable and reliable transactional model. Works best for pseudo-real-time and real-time systems; telecommunications equipment, factory floor automation systems, process control, zero-latency consumer electronics devices, and medical equipment.

9 Vs. Traditional Database Systems Real-time database systems (RTDBSs) - repositories for data and provide efficient storage, retrieval and manipulation of data. Differences lie in the requirements of the managed data, timing constraints on transactions, and performance goals.T Conventional DBMS goal is to achieve good throughput or average response time Real-Time DBMS provides a predictable response time to guarantee the completion of time-critical transactions.

10 Embedding the db4o Object Oriented Database db4o -open-source, object-oriented database from db4objects. Versions of db4o exist for Java and.NET/Mono. It's an ideal OODBMs engine for Linux applications written in either the Java or.NET frameworks. Allows multiuser access- any access on the database is invisibly wrapped in a transaction and all operations adhere to ACID principles (atomicity, consistency, isolation and durability).

11 Example; A Dictionary Database The application manipulates a database that stores words and their definitions. In such an application, we might define a class to model dictionary entries as follows:

12 Define Class public class DictEntry { private string theWord; private string pronunciation; private ArrayList definitions; public DictEntry() { } // Create a new Dictionary Entry public DictEntry(string _theWord, string _pronunciation) {theWord = _theWord; pronunciation = _pronunciation; definitions = new ArrayList(); }

13 Develop a class describing definition public class Defn { public static int NOUN = 1; public static int PRONOUN = 2; public static int VERB = 3; public static int ADJECTIVE = 4; public static int ADVERB = 5; public static int CONJUNCTION = 6; public static int PARTICIPLE = 7; public static int GERUND = 8; private int pos; private string definition; public Defn(int _pos, string _definition) { pos = _pos; definition = _definition; }

14 Individual characters within a word are stored at different node levels.

15 Activation Depth- Ie; Suppose I've fetched object A into memory from a db4o database using a db.get() call. If I then call db.activate(A,6), that tells db4o also to fetch into memory all objects referenced by A, up to a depth of 6. db.activate() calls that are sprinkled throughout the search routines of the binary tree and the trie classes ensure that the search operation always pulls in enough of the index so that the search can proceed. Object Memory Db.get() Db.activate(A.6 )

16 Drawbacks Accessibility Poor Elapsed Time Rate

17 Vs. Traditional Database Systems Unlike Traditional object-relational database systems, db4o does not require you to pass your code through an instrumentation pre- or post-compilation step. Nor must classes whose objects are to be made persistent be derived from a special persistence-aware superclass. db4o works with ordinary objects, and does not to be informed of an object's structure before that object is stored into a db4o database.

18 Reducing Energy Consumption of Queries in Memory-resident Database Systems Memory paradigm is different Partitioned and more structured Banks – each bank can be controlled individually Lot of work done for compilers, OS and architecture Authors goal Study the implications of banked memory environment on memory- resident databases Reduce energy consumption of embedded systems that run such DBMS Reduce energy consumption of embedded systems that run such DBMS Any interesting takes from DBMS? Cannot simply extend existing models Hardware and DB designers can use our results for redesigning embedded DBMS


20 Banked Memory

21 Available Operating Modes Active (2.063 nJ) Power Dwn (0.025 nJ) Nap (0.035 nJ) Standby (0.743 nJ) Read / Write 9000 cycles1 cycle 16 cycles

22 Energy Management Idea Goal: To reduce the energy consumption of a query by utilizing banks idleness during the querys execution A query accesses only a small set of tables a.k.a, banks Unused memory banks can be placed into a low-power operating mode Question is how and when? Two approaches Correct (automated) use of low-power modes at hardware level Changing a query to use minimal energy – software level

23 Hardware Scheme – Static Standby Already exists in most memory systems (RDRAM) Its a per-access optimization After a read/write access, the memory module that gets accessed can be placed into the standby mode in the following cycle. Open/close (page) policies - Static standby mode Scheme may lead to frequent resynchronizations The rest of the schemes that we propose aim to minimize the expensive resynchronization costs (also, static)

24 Hardware Scheme – Dynamic Threshold Full Power StandbyNap Power Down 10 1001000 1 16 9000

25 Query plans give a detailed break up of primitive operations that are contained in a query A typical query will have: Scan (SELECT) Check for a condition (>, <, ==) Refine results (GROUP BY, JOIN) Could also be recursive (scan of scan) SQL Example: Whos birthday is it today? SELECT name FROM addressbook WHEREDOB = today and CITY = my city

26 Energy Evaluation Software scheme is the best Bank idleness are well estimated using access patterns

27 Conclusion There is a gap between memory growth and DB design Verified this by simple hardware and software schemes to reduce energy consumption Hardware vs. Software schemes Hardware is good when access patterns are totally random Software is good when access patterns show enough inter-table access times (which is related to energy savings) – up to 68% reduction in energy Combination of both would be ideal

28 Improvement: Object Analysis Patterns for Embedded Systems Currently, most embedded systems uses ad hoc development approaches that emphasize design coding over analysis. Analyze phase is often neglect in current development practice. This causes errors during design and coding. Propose; Object Analysis Patterns for use in the analysis phase in the development to guide construction. Meets System Requirements Lower Elapsed Time Lower Shipping Cost

29 Broy Logical Interface Architecture for Embedded Systems

30 Abstracted Software Development Process

31 Example; User Interface

32 Bibliography [ Konrad04] Sascha Konrad, Betty H.C.Cheng, Object Analysis Patterns for Embedded Systmes," IEEE Transactions on Software Engineering (IEEE 04), pages 970-992. [Pisharath04] Jayapraskash Pisharath, Alok Choudhary, Mahmut Kandemir, Reducing Engergy Consumption of Queries in Memory-Resident Database Systems," International Conference on Compilers, Architectures and Synthesis of Embedded Systems (CASES 04), Washington, DC, September 24, 2004, pages 35-45. [Cmkovic05] Ivica Cmkovix, Component- Based Software Engineering for Embedded Systems," Internation Conference on Software Engineeing (ICSE 05), St.Louus, MS, May 15- 21, 2005, pages 712-715 [Kraft07] Tobias Kraft, A Cost Estimation Component for Statement Sequences, Very Large Databases Conference,(VLDB), Vienna, Austria, September 23-28, 2007, pages 1382- 1385 [Navas01] Julio Navas, Michael Wynblatt, The Network is the Database, Association of Computer Machinery (ACM), Santa Barbara, CA May 21-24, 2001, pages 544-551

Download ppt "Angela M. Carthan Advanced Database Systems CSC 8712 Georgia State University Department of Computer Science Technology 15 April 2008 Embedded Database."

Similar presentations

Ads by Google