Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

View: New views
5 Messages — Rating Filter:   Alert me  

Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

by hbf :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Dear list,

My goal is to use Wicket-RAD HEAD with Wicket HEAD or Wicket 1.4-SNAPSHOT. I am not sure how to set up Eclipse to get this.

What I did is the following: I checked out Wicket-RAD and made it a project in my Eclipse. I can now use 'svn up' and 'mvn install' (with Eclipse plugin m2eclipse it's Run As -> Maven install) to build Wicket-RAD and install it into my local m2 maven repository.

My projects pom.xml has dependencies on junit, wicket-rad-jpa, wicket-rad-core, and hsqldb. That's it. If I check the project settings 'Java Build Path', I see that wicket-1.3.5 is being used. I assume this comes because wicket-rad-core has a dependency on wicket-1.3.5. However, I'd like to have Wicket 1.4 HEAD or Wicket 1.4-SNAPSHOT. How can I achieve this?

I fear that if I add *additional* dependencies on wicket-1.4-SNAPSHOT, this will result in a complete chaos as Wicket-RAD will continue to use/reference wicket-1.3.5 while my code is referencing 1.4. Right?

Thanks a lot,
Kaspar


Re: Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

by wfaler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,
If you don't mind getting your hands dirty, the easiest way is probably downloading trunk from SVN (instructions exist on the wiki: http://sites.google.com/site/wicketrad ), then searching for "org.apache.wicket" in the pom.xml files and updating it to the 1.4 version you want to use.

After this, you should be able to just run "mvn clean install eclipse:clean eclipse:eclipse" to get everything generated for you.
It is possible that some changes have broken, so you might have to fix/ignore some tests and compilation issues, but I would expect the problems to be minimal.

As for the difference between the last release and trunk: not much really, mostly just a few bug fixes, I will try to upgrade to 1.4 soon, but I haven't had time yet.

hbf wrote:
Dear list,

My goal is to use Wicket-RAD HEAD with Wicket HEAD or Wicket 1.4-SNAPSHOT. I am not sure how to set up Eclipse to get this.

What I did is the following: I checked out Wicket-RAD and made it a project in my Eclipse. I can now use 'svn up' and 'mvn install' (with Eclipse plugin m2eclipse it's Run As -> Maven install) to build Wicket-RAD and install it into my local m2 maven repository.

My projects pom.xml has dependencies on junit, wicket-rad-jpa, wicket-rad-core, and hsqldb. That's it. If I check the project settings 'Java Build Path', I see that wicket-1.3.5 is being used. I assume this comes because wicket-rad-core has a dependency on wicket-1.3.5. However, I'd like to have Wicket 1.4 HEAD or Wicket 1.4-SNAPSHOT. How can I achieve this?

I fear that if I add *additional* dependencies on wicket-1.4-SNAPSHOT, this will result in a complete chaos as Wicket-RAD will continue to use/reference wicket-1.3.5 while my code is referencing 1.4. Right?

Thanks a lot,
Kaspar

Re: Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

by hbf :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I've imported the subprojects (wicket-rad-core, etc.) into Eclipse and changed all pom.xml files to use wicket-1.4-SNAPSHOT, as you have suggested. Indeed only a few things needed fixing. The attached patch contains the details and here is a description of these changes:

1. wicket-contrib-tinymce: Only changes in pom.xml were needed. First of all, I changed the version from 1.3.5 to 1.4-SNAPSHOT (see 2. below). Then the change to depend on wicket-1.4-SNAPSHOT, and finally and most importantly for me, I set the compiler level:

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>1.5</source>
          <target>1.5</target>
        </configuration>
      </plugin>

Without this, I got a strange error (unknown symbol Component.add(Component [])) due to Java 1.4's lack of generics.

2. wicket-rad-core: Updated the Wicket version in file wicketVersion. Changed a few occurences of setModel () to setDefaultModel() in FeedbackLabel.java. Updated the pom.xml to depend on wicket-1.4-SNAPSHOT in stead of 1.3 and to depend on wicket-contrib-tinymce 1.4-SNAPSHOT (see above). Notice that wicketstuff-dojo is still 1.3.0-beta.

I hope this helps in migrating to SVN trunk to 1.4!

Cheers,
Kaspar

wicket-rad-patch-1.4-SNAPSHOT.txt 

Re: Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

by hbf :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

P.S. I got a NoSuchMethodError exception when launching Wicket with Jetty from Eclipse: "Task ModificationWatcher terminated",

java.lang.NoSuchMethodError:
org.slf4j.Logger.isTraceEnabled()Z
    at org.apache.wicket.util.thread.Task$1.run(Task.java:103)
    at java.lang.Thread.run(Thread.java:595)

I fixed this by changing the the version of slf4j-* to 1.4.2 in wicket-rad-core/pom.xml (as in the other subprojects of wicket-rad):

                <dependency>
                        <groupId>org.slf4j</groupId>
                        <artifactId>slf4j-log4j12</artifactId>
                        <version>1.4.2</version>
                </dependency>
                <dependency>
                        <groupId>org.slf4j</groupId>
                        <artifactId>slf4j-api</artifactId>
                        <version>1.4.2</version>
                </dependency>

Kaspar

Re: Wicket-RAD 0.6 with Wicket 1.4-SNAPSHOT

by wfaler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks!

hbf wrote:
I've imported the subprojects (wicket-rad-core, etc.) into Eclipse and changed all pom.xml files to use wicket-1.4-SNAPSHOT, as you have suggested. Indeed only a few things needed fixing. The attached patch contains the details and here is a description of these changes:

1. wicket-contrib-tinymce: Only changes in pom.xml were needed. First of all, I changed the version from 1.3.5 to 1.4-SNAPSHOT (see 2. below). Then the change to depend on wicket-1.4-SNAPSHOT, and finally and most importantly for me, I set the compiler level:

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>1.5</source>
          <target>1.5</target>
        </configuration>
      </plugin>

Without this, I got a strange error (unknown symbol Component.add(Component [])) due to Java 1.4's lack of generics.

2. wicket-rad-core: Updated the Wicket version in file wicketVersion. Changed a few occurences of setModel () to setDefaultModel() in FeedbackLabel.java. Updated the pom.xml to depend on wicket-1.4-SNAPSHOT in stead of 1.3 and to depend on wicket-contrib-tinymce 1.4-SNAPSHOT (see above). Notice that wicketstuff-dojo is still 1.3.0-beta.

I hope this helps in migrating to SVN trunk to 1.4!

Cheers,
Kaspar

wicket-rad-patch-1.4-SNAPSHOT.txt