On Jan 28, 2008 5:38 PM, Simon Laws <[EMAIL PROTECTED]> wrote: > snip... > > > I'm not too keen on scanning a disk directory as it doesn't apply to a > > distributed environment, I'd prefer to: > > - define a model representing a contribution repository > > - persist it in some XML form > > > > > I've started on some model code in my sandbox [1]. Feel free to use and > abuse. > > Regards > > Simon > > [1] > http://svn.apache.org/repos/asf/incubator/tuscany/sandbox/slaws/modules/ >
Looking a svn I find there is already a ContributionRepository implementation [1]. There may be a little bit too much function in there at the moment but it's useful to see it none the less. So, to work out what it does. First question concerns the "store()" method. public URL store(String contribution, URL sourceURL, InputStream contributionStream). Can someone explain what the sourceURL is for? The model in my sandbox [2], which is very simlar to the XML that the current contribution repository uses, now holds node and contribution name information [3]. These could be two separate models to decouple the management of contributions from the process of associating them together. I'd keep the info in one place but I expect other's views will vary. [1] http://svn.apache.org/repos/asf/incubator/tuscany/java/sca/modules/contribution-impl/src/main/java/org/apache/tuscany/sca/contribution/service/impl/ContributionRepositoryImpl.java [2] http://svn.apache.org/repos/asf/incubator/tuscany/sandbox/slaws/modules/ [3] http://svn.apache.org/repos/asf/incubator/tuscany/sandbox/slaws/modules/domain-model-xml/src/test/resources/org/apache/tuscany/sca/domain/model/xml/test.domain
