On 8/9/07, Luciano Resende <[EMAIL PROTECTED]> wrote:
>
> Hi Simon,
>
>    Could you please send the exact URL you are passing to the
> contribution service ?
>
>    I have added a test case for what I understood your problem is, and
> that is working fine, but note that in the test case, I'm calling
> getClass().getResource("/deployables"), and that gives me a url like :
> file:/..../deployables, and that would pass the logic to correct
> identify a "folder".
>
> On 8/9/07, Simon Laws <[EMAIL PROTECTED]> wrote:
> > I've just noticed that if I have a contribution directory as follows
> >
> > /my/contribution/dir/mycomposite.composite
> >
> > And I pass the source URL /my/contribution/dir to the contribution
> service
> > it complains that it can't find /my/contribution/mycomposite.composite.
> > If I pass the source URL /my/contribution/dir/ it works (note slash on
> end).
> >
> >
> > Is this a fault?
> >
> > Simon
> >
>
>
> --
> Luciano Resende
> Apache Tuscany Committer
> http://people.apache.org/~lresende
> http://lresende.blogspot.com/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
> Hi Luciano

This was the piece of code that was causing me problems...

            contributionURL = new URL("file:/" +
currentDirectory.getCanonicalPath() + "/src/main/resources/" + nodeName +
"/");

            // Contribute the SCA application
            Contribution contribution = contributionService.contribute("
http://calculator";,
                                                          contributionURL,
                                                          resolver,
                                                          false);
            Composite composite = contribution.getDeployables().get(0);

            // Add the deployable composite to the domain
            domain.getDomainComposite().getIncludes().add(composite);
            domain.getCompositeBuilder().build(composite);

Where the directory structure is.

src/
   main/
      resources/
               nodeA/
                     META-INF/
                         sca-contribution.xml
                      wsdl
                         mutiply.wsdl
                      calculator.composite

And I want to read the contribution from the nodeA directory.

Maybe you can spot something from this. But if nothing comes to mind
immediately don't worry. I'll check this test in over the next few days and
we can look at it directly.

Regards

Simon

Reply via email to