Sorry. Pilot error ;-) Turns out that I was getting fooled by the error message. It had nothing to do with not finding the HttpUtils class. It was that my "dest dir" was not yet created and the failure was internal to HttpUtils -- but this fact was masked by the InvocationTargetException. I figured this out by switching to Ant's Get Task... Oh well, live and learn. Thanks, -- Chris
--- Ole Matzura <[EMAIL PROTECTED]> wrote: > hmm.. > > judging from your error message and the source code > for the InvokeStatic tag > (http://cvs.apache.org/viewcvs.cgi/jakarta-commons/jelly/src/java/org/apache/commons/jelly/tags/core/InvokeStaticTag.java?rev=1.9&view=auto) > it seems your exception is created using the > createLoadClassFailedException method (at the > bottom). Strangely though, for > InvocationTargetException, this should not be the > case as it has its own catch clause which does not > use that method for creating its exception (or I am > just too tired now ??) .. maybe you dont have the > latest version of the jelly core? (which on the > other hand doesn't fit with your invocation working > later on..) > > sorry for making stupid suggestions.. just trying to > help out :-) > > good luck! > > /Ole > > ________________________________ > > From: Chris Berry [mailto:[EMAIL PROTECTED] > Sent: Sun 30/01/2005 19:56 > To: Maven Users List > Subject: RE: Problem w/ HttpUtils > > > > These jars are a part of maven itself > I don't think that I should have to explicitly > declare > them. And also, this same code works fine when used > slightly differently (in a slightly different call > sequence). Regardless, I tried your suggestion, and > it > has no effect... > > Is there a way for the plugin.jelly itself to > "import" > this class -- i.e. to explicitly make sure that it > is > present before trying to use it... > > Thanks, > -- Chris > > --- Ole Matzura <[EMAIL PROTECTED]> wrote: > > > hmm.. > > > > sorry for some basic questions; httputils has > > dependencies on httpclient and commons-lang, are > > they all in your > > plugins' dependency-list? > > > > /Ole > > > > ________________________________ > > > > From: Chris Berry [mailto:[EMAIL PROTECTED] > > Sent: Sun 30/01/2005 19:25 > > To: Maven Users List > > Subject: RE: Problem w/ HttpUtils > > > > > > > > Unfortunately, that doesn't help. > > > > --- Ole Matzura <[EMAIL PROTECTED]> wrote: > > > > > Hi! > > > > > > have you tried to add maven-1.0.2.jar to your > > > dependency classpath in your jelly script? Or > > maybe > > > just create > > > a standard dependency to it in project.xml? > > > > > > ie > > > > > > <dependency> > > > <groupId>maven</groupId> > > > <artifactId>maven</artifactId> > > > <version>1.0.2</version> > > > </dependency> > > > > > > regards! > > > > > > /Ole > > > > > > ________________________________ > > > > > > From: Chris Berry > [mailto:[EMAIL PROTECTED] > > > Sent: Sun 30/01/2005 17:51 > > > To: [email protected] > > > Subject: Problem w/ HttpUtils > > > > > > > > > > > > Greetings, > > > I am using HttpUtils to manually fetch > > dependencies. > > > I > > > do this because maven does not adequately chain > > > dependencies. I.e if A depends on B, and B > depends > > > on > > > C, then B should chain in it's own dependencies > > and > > > not force A to prescribe them (since A should > not > > > know > > > this directly) > > > > > > So I create a package (a tarball or a jar), for, > > > say, > > > B, and store a filelist in that tarball listing > > it's > > > dependencies. Then A depends on B -- and B knows > > > that > > > it has further dependencies and manually brings > > them > > > in -- using maven's HttpUtils. > > > > > > So far so good. I have all of this working. But > > when > > > I > > > moved the process forward to a different point > in > > my > > > build cycle (i.e. in my plugin) it fails. I get > a > > > "class not found" for HttpUtils. > > > > > > Can someone please explain how to make this > work?? > > > HttpUtils is a part of maven, and I can see it > in > > > maven.jar -- and it works at a later point in my > > > process -- so some other plugin I'm using must > set > > > stuff up for me. I suspect that there is some > > magic > > > line of jelly that I need to add, but looking > thru > > > plugins, I cannot discern what it is... > > > > > > BTW: The file I'm fetching exists and the > > > maven.repo.remote is correct. > > > > > > I'm confused. > > > Thanks, > > > -- Chris > > > > > > Further info follows:: > > > --------------------------------------- > > > Here is the jelly:: > > > > > > <j:catch var="ex"> > > > <j:invokeStatic var="dummy" > > > method="getFile" > > > > > > className="org.apache.maven.util.HttpUtils"> > > > <j:arg type="java.lang.String" > > > value="${remoteFile}" /> > > > <j:arg type="java.io.File" > > > value="${localFile}"/> > > > <j:arg type="boolean" > > > value="false"/> > > > <j:arg type="boolean" > > > value="true"/> > > > <j:arg type="java.lang.String" > > > value="${maven.proxy.host}" /> > > > <j:arg type="java.lang.String" > > > value="${maven.proxy.port}" /> > > > <j:arg type="java.lang.String" > > > value="${maven.proxy.username}" /> > > > <j:arg type="java.lang.String" > > > value="${maven.proxy.password}" /> > > > <j:arg type="boolean" > > > value="false"/> > > > </j:invokeStatic> > > > </j:catch> > > > ------------------------------------------------ > > > And here is the error:: > > > > > > et:expand-jar-dependencies: > > > jws:expand-jarlist-to-dir: > > > [echo] jarsFlist= > > > > > > commons-logging/jars/commons-logging-1.0.3.jar,junit/jars/junit-3.8.1.jar,log4j/jars/log4j-1.2.8.jar,commons-beanutil > > > > > > s/jars/commons-beanutils-1.7.0.jar,commons-cli/jars/commons-cli-1.0.jar,commons-collections/jars/commons-collections-3.1.jar,commons-dbcp/ja > > > > === message truncated ===> --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] __________________________________ Do you Yahoo!? Yahoo! Mail - You care about security. So do we. http://promotions.yahoo.com/new_mail --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
