Most of the time people use to go for simpler approaches when they are designing their applications for example using text files to store data. That is perfectly suitable for an application that does not evolve / grow over time. Even though the above factors are violated, still people hesitate to use embedded databases because of simplicity. If you are looking to store data in a text file please reconsider your decision over following facts,
1. Does it grow with time?
2. Is the schema complex?
3. Does application needs flexibility such as merging with other data sources, changing schema or etc ?
4. Does size of the application matter?
Before I read the project proposal of Sip communicator, Chat History Service, I had no idea of embedding a database to our application. After that, I learnt a bit about embedded databases. I developed a sample code that a beginner can start working on SQL embedded databases. I have used apache derby (http://db.apache.org/derby/index.html) database for my sample application.
Apache Derby, an Apache DB subproject, is an open source relational database implemented entirely in Java and available under the Apache License, Some key advantages include:
1. Derby has a small footprint -- about 2 megabytes for the base engine and embedded JDBC driver.
2. Derby is based on the Java, JDBC, and SQL standards.
3. Derby provides an embedded JDBC driver that lets you embed Derby in any Java-based solution.
4. Derby also supports the more familiar client/server mode with the Derby Network Client JDBC driver and Derby Network Server.
5. Derby is easy to install, deploy, and use.
You can download the eclipse sample project that I sent to Sip Communicator. Please go through the manuals and find more details about it. (http://db.apache.org/derby/manuals/index.htm)
Friday, May 1, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment