views:

53

answers:

1

I want to have a repository of Url to music(audio and video) with different file types (mp3,ogg,flv,avi) which can be used as a web-service.

Is there a free or open source solution for a repository (for example written in Java) which could help me, or do you have some recommendations, or patterns that could help me?

+3  A: 

I'm not completely clear on what you are asking, but this sounds like a good use case for a NoSQL document store. If I were you, I'd be looking into things like CouchDB, MongoDB, Amazon S3 , etc.

CouchDB provides an HTTP interface via RESTful calls to your documents. So you could store your media in it, and you'd have a URL for each media element. There are Java libraries to support it, plus it's just REST with JSON, so it is really easy to get it working with Java. Personally, I use Jackson for JSON processing.

I'm not sure about a pure Java solution, perhaps JackRabbit? But it seems it may be overkill for your needs. It wouldn't be hard to roll your own. Perhaps use Jersey to implement REST, and then just store files on the filesystem. I guess it all depends on the scale you need.

Hope this helps.

Tauren