Music Service

2003-01-01 : This is a continuation of a long running project. It's mentioned on the 2002 Projects page. But now there's some code (a teensy bit) and an outline.

From ideas.txt

connection manager:
    establish connection
    fetch catalog
    fetch file fragment
      returns OK; failed (access denied, not cached, not found)
    connection established
    connection lost

    remote catalog updated
    remote clear of upload-required flag (upload successful)

catalog and backing store manager:
    load/save catalog
    compare catalog to other catalog
      returns a list of updates
    compare catalog to backing store
      returns a list of updates
    apply update to catalog
    set/clear upload required flag
    set/clear protect-file flag
    set cache size limit
    get cache space available, space used, space of in-use files, upload required, protected; file counts
    free some cache space (only implicit?)
    add file to store as file-info
    set/clear file in use

download list manager:
    start/stop downloading
    add/remove download request
    re-order queue
    (list of pending downloads/denied downloads)

  view list of pending updates
  approve/throw out action
  start/stop allowing uploads
  set/clear master cache role
  if a file on the download list gets deleted by a catalog update, it should be removed from the download list.

file info:
  hash/deleted flag
  version (date added to catalog)
  source file (for move)
  exists in backing store
  upload required flag
  last used timestamp
  in use flag
  keep-file flag

  add revision to catalog
  move backing store
  del backing store
  add backing store

2003-03-15 : Did some more work today. Implemented a chunk of the CatalogManager - read and write catalog, plus the basic catalog update methods. Also wrote a MusicService class to host a CatalogManager so you can actually run the app, although it doesn't do anything.

Next step is to add ability to compare the catalog to the backing store and thus generate some pending updates so I can actually exercise the update methods.

2004-04-22 : I'm putting my further thoughts on the file synchronization engine in a project of their own.

You can get the source via anonymous CVS at

  • cvs -d co 2003/MusicService

    Note that it is currently set up with a dependency on a private library.

    C o m m e n t s :    
    (nothing yet)