You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Ichiro Furusato <ic...@gmail.com> on 2010/09/23 14:28:47 UTC

The Long, Long Dependency Trail

Hello,

I've been working with Wicket for about a week now and things were
moving along all cruisy until I started adding Hibernate and
Databinder dependencies into my POM. Then all hell broke loose and I
seem to now find myself in the NoClassDefFoundError, then find and
manually install jar cycle. I mean, things with Wicket were just so,
well, SENSIBLE, and now I'm back in nightmare-programming-land again.

In looking at some of the examples on the Web that combine Wicket and
Hibernate, they don't seem to be needing anywhere near the number of
dependencies I am now adding. I'm guessing I must be doing something
wrong, as I'm still pretty new to Maven, being a longstanding Ant
person. That I've had to manually install a whole bunch (6) of jars
seems a clue. Part of this may be due to the folks who wrote
Databinder using git rather than a maven repository (why oh why?!).

My application extends net.databinder.auth.hib.AuthDataApplication so
that it can be an authenticating database application. I've attached
both the latest stack trace and my pom.xml file in hopes that some
kind soul can tell me where I've gone terribly wrong. Perhaps I'm
almost at the end of the dependency tunnel but I'm not yet seeing any
light yet. I'm guessing this is probably a blaringly obvious problem,
or maybe not a problem at all and I'm almost there.

Thanks very much,

Ichiro

PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
fun programming since HyperCard. I hope it's not significantly more
complicated a year or two from now than it is now. If the developer
team can keep to that ethos of simplicity Wicket will only gain in
popularity. Avoid the bloat.

Re: The Long, Long Dependency Trail

Posted by Ichiro Furusato <ic...@gmail.com>.
Thanks very much all for your helpful replies. I'll try to answer all at once:

Josh, I'm using Hibernate 3.5.6-Final. I'm going to clean out my .m2
repository of the Hibernate stuff, then try Bas' suggestion and see if
it works without me having to manually install the jars to my local
repository as I've done.

Martijn, that sounds like a good suggestion in a sense, but I'm
honestly trying to keep things as simple as possible (for future
maintainability given I might not be the one working on this project
next year), so hopefully I'll be able to get a pom.xml file together
that does everything necessary without needing any local manager. But
that's a good idea for my own stuff (i.e., at home) so I might give
that a try. Thanks.

Sebastian, just yesterday I tried letting Eclipse manage my
dependencies using Maven (since this project uses Maven) and it seems
sensible enough, just a different process and place to look to manage
my external libraries.

Thomas, prior to this project I used Ant exclusively, so that kind of
thing is certainly the way to go, and it scales fine to lots of jars.
You can get pretty tricky with Ant, and it's great for managing the
jar/war metadata, signing jars, etc., lots of things I don't know how
to do in Maven (assuming they call can be done -- this remains to be
seen).

Don, I've been tempted to looking into Ivy for a long time, and if it
weren't for the fact that the Wicket project seems pretty
Maven-centric (even acknowledging that they state that Maven is not
strictly required), I'd probaby go back to Ant and use Ivy for my
dependencies. I still may in the end. As I mentioned above, there's
things I know how to do in Ant that I may want to accomplish without
having to learn how in Maven. I still think Ant is pretty amazing
really. With Ivy it might be a complete solution for me (I'm not one
to use new software just because it's a popular fad, unless it's
actually an improvement over what I'm already doing).

Finally, thanks Nino, it turns out that I actually did use an
archetype to generate the beginnings of this project, which is
certainly one thing in Maven I do like.

Postscript: I added the maven repository as suggested by
Bas, backed all the Databinder stuff back to 1.3.0 so that
I didn't need the SNAPSHOTs (and thereby fixed a bug due
to a class that is no longer used), and stopped trying to use
AuthDataApplication as my base class (using just
DataApplication) since I'm using wicket-auth-roles and
already had my own role-based auth classes in place. So
now it works and has Hibernate and Databinder in the app.

Next step: start building the database classes.

Thanks all, this was very helpful.

Ichiro

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by nino martinez wael <ni...@gmail.com>.
if I where you i'd go use one of the legup archetypes or wicket stuff
iolite (although a bit outdated) and build on those, they provide the
boilder plate so you dont have to write it. Use a artifact manager
like nexus or artifactory..

As for the rest of it, I wrote an article here :
http://ninomartinez.wordpress.com/2009/12/10/building-software-cheat-sheet/

2010/9/23 Ichiro Furusato <ic...@gmail.com>:
> Hello,
>
> I've been working with Wicket for about a week now and things were
> moving along all cruisy until I started adding Hibernate and
> Databinder dependencies into my POM. Then all hell broke loose and I
> seem to now find myself in the NoClassDefFoundError, then find and
> manually install jar cycle. I mean, things with Wicket were just so,
> well, SENSIBLE, and now I'm back in nightmare-programming-land again.
>
> In looking at some of the examples on the Web that combine Wicket and
> Hibernate, they don't seem to be needing anywhere near the number of
> dependencies I am now adding. I'm guessing I must be doing something
> wrong, as I'm still pretty new to Maven, being a longstanding Ant
> person. That I've had to manually install a whole bunch (6) of jars
> seems a clue. Part of this may be due to the folks who wrote
> Databinder using git rather than a maven repository (why oh why?!).
>
> My application extends net.databinder.auth.hib.AuthDataApplication so
> that it can be an authenticating database application. I've attached
> both the latest stack trace and my pom.xml file in hopes that some
> kind soul can tell me where I've gone terribly wrong. Perhaps I'm
> almost at the end of the dependency tunnel but I'm not yet seeing any
> light yet. I'm guessing this is probably a blaringly obvious problem,
> or maybe not a problem at all and I'm almost there.
>
> Thanks very much,
>
> Ichiro
>
> PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
> fun programming since HyperCard. I hope it's not significantly more
> complicated a year or two from now than it is now. If the developer
> team can keep to that ethos of simplicity Wicket will only gain in
> popularity. Avoid the bloat.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by Don Ferguson <do...@gmail.com>.
If you want to stick with Ant, try Ivy instead of Maven.  It can read Maven pom files, and has a decent eclipse plug-in.

On Sep 23, 2010, at 5:28 AM, Ichiro Furusato wrote:

> . I'm guessing I must be doing something
> wrong, as I'm still pretty new to Maven, being a longstanding Ant
> person. 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by Bas Gooren <ba...@iswd.nl>.
(Sorry for the topic hijacking Ichiro ...) Interesting tip, thanks!

I've only been using maven for a year now, mainly by using m2eclipse to 
prevent library jars ending up in my source repository.

Sebastian

----- Original Message ----- 
From: "Martijn Dashorst" <ma...@gmail.com>
To: <us...@wicket.apache.org>
Sent: Thursday, September 23, 2010 2:49 PM
Subject: Re: The Long, Long Dependency Trail


I would not add those external repositories to your own pom, but rely
on a repository manager instead to retrieve the dependencies.

See:

 * artifactory
 * nexus
 * archiva

Martijn

On Thu, Sep 23, 2010 at 2:48 PM, Bas Gooren <ba...@iswd.nl> wrote:
> More recent versions of hibernate are available in the JBoss maven repo
> (which I do not see in your pom.xml):
>
> <repository>
> <id>jboss</id>
> <url>https://repository.jboss.org/nexus/content/repositories/releases</url>
> </repository>
>
> Sebastian
>
> ----- Original Message ----- From: "Josh Kamau" <jo...@gmail.com>
> To: <us...@wicket.apache.org>
> Sent: Thursday, September 23, 2010 2:44 PM
> Subject: Re: The Long, Long Dependency Trail
>
>
>> I suggest you use hibernate 3.5+. it seems more organized adding
>> hibernate-core , hibernate-annotations adds all the neccessary hibernate
>> dependencies.
>>
>> I normally use hibernate JPA entity manager and all i add is one
>> dependency
>> for hibernate-entitymanager.
>>
>> Regards.
>>
>> On Thu, Sep 23, 2010 at 3:28 PM, Ichiro Furusato
>> <ic...@gmail.com>wrote:
>>
>>> Hello,
>>>
>>> I've been working with Wicket for about a week now and things were
>>> moving along all cruisy until I started adding Hibernate and
>>> Databinder dependencies into my POM. Then all hell broke loose and I
>>> seem to now find myself in the NoClassDefFoundError, then find and
>>> manually install jar cycle. I mean, things with Wicket were just so,
>>> well, SENSIBLE, and now I'm back in nightmare-programming-land again.
>>>
>>> In looking at some of the examples on the Web that combine Wicket and
>>> Hibernate, they don't seem to be needing anywhere near the number of
>>> dependencies I am now adding. I'm guessing I must be doing something
>>> wrong, as I'm still pretty new to Maven, being a longstanding Ant
>>> person. That I've had to manually install a whole bunch (6) of jars
>>> seems a clue. Part of this may be due to the folks who wrote
>>> Databinder using git rather than a maven repository (why oh why?!).
>>>
>>> My application extends net.databinder.auth.hib.AuthDataApplication so
>>> that it can be an authenticating database application. I've attached
>>> both the latest stack trace and my pom.xml file in hopes that some
>>> kind soul can tell me where I've gone terribly wrong. Perhaps I'm
>>> almost at the end of the dependency tunnel but I'm not yet seeing any
>>> light yet. I'm guessing this is probably a blaringly obvious problem,
>>> or maybe not a problem at all and I'm almost there.
>>>
>>> Thanks very much,
>>>
>>> Ichiro
>>>
>>> PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
>>> fun programming since HyperCard. I hope it's not significantly more
>>> complicated a year or two from now than it is now. If the developer
>>> team can keep to that ethos of simplicity Wicket will only gain in
>>> popularity. Avoid the bloat.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.4 increases type safety for web applications
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.8

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by Martijn Dashorst <ma...@gmail.com>.
I would not add those external repositories to your own pom, but rely
on a repository manager instead to retrieve the dependencies.

See:

 * artifactory
 * nexus
 * archiva

Martijn

On Thu, Sep 23, 2010 at 2:48 PM, Bas Gooren <ba...@iswd.nl> wrote:
> More recent versions of hibernate are available in the JBoss maven repo
> (which I do not see in your pom.xml):
>
> <repository>
>  <id>jboss</id>
>  <url>https://repository.jboss.org/nexus/content/repositories/releases</url>
> </repository>
>
> Sebastian
>
> ----- Original Message ----- From: "Josh Kamau" <jo...@gmail.com>
> To: <us...@wicket.apache.org>
> Sent: Thursday, September 23, 2010 2:44 PM
> Subject: Re: The Long, Long Dependency Trail
>
>
>> I suggest you use hibernate 3.5+. it seems more organized adding
>> hibernate-core , hibernate-annotations adds all the neccessary hibernate
>> dependencies.
>>
>> I normally use hibernate JPA entity manager and all i add is one
>> dependency
>> for hibernate-entitymanager.
>>
>> Regards.
>>
>> On Thu, Sep 23, 2010 at 3:28 PM, Ichiro Furusato
>> <ic...@gmail.com>wrote:
>>
>>> Hello,
>>>
>>> I've been working with Wicket for about a week now and things were
>>> moving along all cruisy until I started adding Hibernate and
>>> Databinder dependencies into my POM. Then all hell broke loose and I
>>> seem to now find myself in the NoClassDefFoundError, then find and
>>> manually install jar cycle. I mean, things with Wicket were just so,
>>> well, SENSIBLE, and now I'm back in nightmare-programming-land again.
>>>
>>> In looking at some of the examples on the Web that combine Wicket and
>>> Hibernate, they don't seem to be needing anywhere near the number of
>>> dependencies I am now adding. I'm guessing I must be doing something
>>> wrong, as I'm still pretty new to Maven, being a longstanding Ant
>>> person. That I've had to manually install a whole bunch (6) of jars
>>> seems a clue. Part of this may be due to the folks who wrote
>>> Databinder using git rather than a maven repository (why oh why?!).
>>>
>>> My application extends net.databinder.auth.hib.AuthDataApplication so
>>> that it can be an authenticating database application. I've attached
>>> both the latest stack trace and my pom.xml file in hopes that some
>>> kind soul can tell me where I've gone terribly wrong. Perhaps I'm
>>> almost at the end of the dependency tunnel but I'm not yet seeing any
>>> light yet. I'm guessing this is probably a blaringly obvious problem,
>>> or maybe not a problem at all and I'm almost there.
>>>
>>> Thanks very much,
>>>
>>> Ichiro
>>>
>>> PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
>>> fun programming since HyperCard. I hope it's not significantly more
>>> complicated a year or two from now than it is now. If the developer
>>> team can keep to that ethos of simplicity Wicket will only gain in
>>> popularity. Avoid the bloat.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.4 increases type safety for web applications
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.8

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by Bas Gooren <ba...@iswd.nl>.
More recent versions of hibernate are available in the JBoss maven repo 
(which I do not see in your pom.xml):

<repository>
  <id>jboss</id>
  <url>https://repository.jboss.org/nexus/content/repositories/releases</url>
</repository>

Sebastian

----- Original Message ----- 
From: "Josh Kamau" <jo...@gmail.com>
To: <us...@wicket.apache.org>
Sent: Thursday, September 23, 2010 2:44 PM
Subject: Re: The Long, Long Dependency Trail


>I suggest you use hibernate 3.5+. it seems more organized adding
> hibernate-core , hibernate-annotations adds all the neccessary hibernate
> dependencies.
>
> I normally use hibernate JPA entity manager and all i add is one 
> dependency
> for hibernate-entitymanager.
>
> Regards.
>
> On Thu, Sep 23, 2010 at 3:28 PM, Ichiro Furusato
> <ic...@gmail.com>wrote:
>
>> Hello,
>>
>> I've been working with Wicket for about a week now and things were
>> moving along all cruisy until I started adding Hibernate and
>> Databinder dependencies into my POM. Then all hell broke loose and I
>> seem to now find myself in the NoClassDefFoundError, then find and
>> manually install jar cycle. I mean, things with Wicket were just so,
>> well, SENSIBLE, and now I'm back in nightmare-programming-land again.
>>
>> In looking at some of the examples on the Web that combine Wicket and
>> Hibernate, they don't seem to be needing anywhere near the number of
>> dependencies I am now adding. I'm guessing I must be doing something
>> wrong, as I'm still pretty new to Maven, being a longstanding Ant
>> person. That I've had to manually install a whole bunch (6) of jars
>> seems a clue. Part of this may be due to the folks who wrote
>> Databinder using git rather than a maven repository (why oh why?!).
>>
>> My application extends net.databinder.auth.hib.AuthDataApplication so
>> that it can be an authenticating database application. I've attached
>> both the latest stack trace and my pom.xml file in hopes that some
>> kind soul can tell me where I've gone terribly wrong. Perhaps I'm
>> almost at the end of the dependency tunnel but I'm not yet seeing any
>> light yet. I'm guessing this is probably a blaringly obvious problem,
>> or maybe not a problem at all and I'm almost there.
>>
>> Thanks very much,
>>
>> Ichiro
>>
>> PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
>> fun programming since HyperCard. I hope it's not significantly more
>> complicated a year or two from now than it is now. If the developer
>> team can keep to that ethos of simplicity Wicket will only gain in
>> popularity. Avoid the bloat.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: The Long, Long Dependency Trail

Posted by Josh Kamau <jo...@gmail.com>.
I suggest you use hibernate 3.5+. it seems more organized adding
hibernate-core , hibernate-annotations adds all the neccessary hibernate
dependencies.

I normally use hibernate JPA entity manager and all i add is one dependency
for hibernate-entitymanager.

Regards.

On Thu, Sep 23, 2010 at 3:28 PM, Ichiro Furusato
<ic...@gmail.com>wrote:

> Hello,
>
> I've been working with Wicket for about a week now and things were
> moving along all cruisy until I started adding Hibernate and
> Databinder dependencies into my POM. Then all hell broke loose and I
> seem to now find myself in the NoClassDefFoundError, then find and
> manually install jar cycle. I mean, things with Wicket were just so,
> well, SENSIBLE, and now I'm back in nightmare-programming-land again.
>
> In looking at some of the examples on the Web that combine Wicket and
> Hibernate, they don't seem to be needing anywhere near the number of
> dependencies I am now adding. I'm guessing I must be doing something
> wrong, as I'm still pretty new to Maven, being a longstanding Ant
> person. That I've had to manually install a whole bunch (6) of jars
> seems a clue. Part of this may be due to the folks who wrote
> Databinder using git rather than a maven repository (why oh why?!).
>
> My application extends net.databinder.auth.hib.AuthDataApplication so
> that it can be an authenticating database application. I've attached
> both the latest stack trace and my pom.xml file in hopes that some
> kind soul can tell me where I've gone terribly wrong. Perhaps I'm
> almost at the end of the dependency tunnel but I'm not yet seeing any
> light yet. I'm guessing this is probably a blaringly obvious problem,
> or maybe not a problem at all and I'm almost there.
>
> Thanks very much,
>
> Ichiro
>
> PS. BTW, I'm really enjoying Wicket so far; I haven't had this much
> fun programming since HyperCard. I hope it's not significantly more
> complicated a year or two from now than it is now. If the developer
> team can keep to that ethos of simplicity Wicket will only gain in
> popularity. Avoid the bloat.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>

Re: The Long, Long Dependency Trail

Posted by Thomas Kappler <th...@isb-sib.ch>.
On 09/23/10 14:28, Ichiro Furusato wrote:
> Hello,
>
> I've been working with Wicket for about a week now and things were
> moving along all cruisy until I started adding Hibernate and
> Databinder dependencies into my POM. Then all hell broke loose and I
> seem to now find myself in the NoClassDefFoundError, then find and
> manually install jar cycle. I mean, things with Wicket were just so,
> well, SENSIBLE, and now I'm back in nightmare-programming-land again.

This will probably only apply to smaller projects, but I'd like to offer 
my experience as an example. I recently made a Wicket app with JPA, 
Hibernate, and Jetty not using any dependency manager at all. I 
downloaded the Jars from each project's website, put them into lib/, and 
made a very small Ant build.xml containing

         <path id="compile.classpath">
                 <pathelement path="${build.home}"/>
                 <fileset dir="./lib">
                         <include name="*.jar"/>
                 </fileset>
                 <pathelement path="${classpath}"/>
         </path>

It worked without problems. Sometimes simple is better. Of course, if 
you need a ton of other libraries, it may get too complicated.

-- Thomas

-- 
-------------------------------------------------------------------
   Thomas Kappler                        thomas.kappler@isb-sib.ch
   Swiss Institute of Bioinformatics         Tel: +41 22 379 51 89
   CMU, rue Michel Servet 1
   1211 Geneve 4
   Switzerland                              http://www.uniprot.org
-------------------------------------------------------------------

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org