• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Saving information

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi ,

I am developing a program that needs to save information on the local computer .
The program will share the information with other users on the Internet.

Something like Napster, but with different information.

I am looking the best way to save the info.

On Files , To use MySql Db.

Where can I find information on the methods that I can use ?

Thanks,

ur
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sounds to me like you are talking about Sun's JXTA approach.
Bill
 
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Whether to save data to flat files or a database is an interesting choice. You'd have to weigh the data structure, volume, access requirements (eg, search) and so on. What kind of data will you be sharing? What kinds of operations will people do on the data?

A nice design idea is to hide the final decision behind a data abstraction layer. I built a server with a DataStore component with simple get, put, erase, list functions. I have a flat file store and an in-memory store. It would be easy to make a database version as well. Because they all use the same interface I can switch between them without changing one line of the rest of the system.

Take a look at "defer decisions" in Knight's Principles. See how much of the program you can build without knowing where the data goes!
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic