Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Nx: Few questions concerning URLyBird

 
Ulrich Heeger
Ranch Hand
Posts: 266
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I'm new here in this forum; I have got my assignment now and I have some questions. I would be very happy, if somebody could help me
1. some people in this forum here suggest the use of a Database-cache. It's a must or can I use direct access to the db.file for each client?
Because in my assignment, the DBAccess interface contains following lines:
Because of the comments, do I have to implement this method in the way of direct access to the db.db file or can I use also this method for access to the Database cache?
Thank you,
Ulrich
 
Bharat Ruparel
Ranch Hand
Posts: 493
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Ulrich,
Welcome to JavaRanch.
You wrote:

Because of the comments, do I have to implement this method in the way of direct access to the db.db file or can I use also this method for access to the Database cache?

I also have the URLy Bird assignment. I am not caching the database, primarily because I want to keep it simple and performance is not a criteria. I know others are caching the database. I chose not to, and will submit my assignment without caching. May be someone else who chose to cache data will answer your question. It seems to me that you should be able to read data from the Database cache based on the record number provided though, otherwise the whole benifit of providing a cache is questionable.
Welcome again and regards.
Bharat
 
Philippe Maquet
Bartender
Posts: 1872
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ulrich,
I don't think that this comment in DBAccess interface prevents you to implement a cache. As the content of the latter will be synchronized with the file, reading a record from cache is equivalent of reading it directly from file.
Implementing a cache or not is a design decision you must make among 4 possible choices :
  • No cache at all
  • Cache all records
  • Partial caching (cache size is a property)
  • Support of both 2 and 3 implementations


  • Best,
    Phil.
     
    Ulrich Heeger
    Ranch Hand
    Posts: 266
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Thanks a lot for your answers, they help me much.
    Now I can go forward and try my best
    greetings
    Ulrich
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic