1

Migration to ZK8

asked 2015-10-27 09:17:48 +0800

WilliamB gravatar image WilliamB
1609 1 6

updated 2015-10-27 14:31:43 +0800

Greetings,

I was wondering if there was an article somewhere on the impact from migrating a ZK7 application to ZK8?

I've looked on the forum for the migration keyword but found nothing for 8. Beside those threads:

  1. http://forum.zkoss.org/question/99178/upgrading-to-zk8-javalangnoclassdeffounderror-javassistutilproxyproxy-caused-by-javalangclassnotfoundexception-javassistutilproxyproxy/
  2. http://forum.zkoss.org/question/98991/orgzkossxelxelexception-resource-not-found-httpwwwzkossorgdspwebcore/

Cheers,

delete flag offensive retag edit

8 Answers

Sort by » oldest newest most voted
1

answered 2015-11-02 09:01:58 +0800

Darksu gravatar image Darksu
1991 1 4

Hello WilliamB,

I found a similar issue at zk tracker:

http://tracker.zkoss.org/browse/ZK-2787

They suggest using @Immutable before the getter function because the new form binding approach in ZK 8 would do deeply proxy by default.

Best Regards,

Darksu

link publish delete flag offensive edit

Comments

Thanks Darksu. Hum that is gonna be cumbersome though, as some of the Dto I use in my forms are object retrieved from projection in the database, subModule which does not have access to ZK dependency ...

WilliamB ( 2015-11-02 09:10:34 +0800 )edit

Found this to be in line with my issue : http://books.zkoss.org/zk-mvvm-book/8.0/syntax/immutablefields.html

WilliamB ( 2016-04-04 10:19:07 +0800 )edit
1

answered 2016-03-30 09:28:25 +0800

WilliamB gravatar image WilliamB
1609 1 6

Ok the time has come to really migrate my application to ZK8. What I did before was just a quick test.

Is there still no official page about the migration from 7 to 8 ???

link publish delete flag offensive edit
1

answered 2016-03-30 11:53:21 +0800

chillworld gravatar image chillworld flag of Belgium
5367 4 9
https://github.com/chillw...

Release notes where in the bottom are a few important things :

https://www.zkoss.org/product/zk/releasenote/8.0.0

Greetz chill.

link publish delete flag offensive edit

Comments

Thanks Chill, Bit surprised nothing on the form binding change in those logs (found the article somwhere else)

WilliamB ( 2016-03-30 12:12:48 +0800 )edit

With the form Binding it's actually simple. in zul nothing changes. Only a small change when you have the Form in java code, but I can help you with that.

chillworld ( 2016-03-30 14:17:58 +0800 )edit
0

answered 2015-10-27 10:58:10 +0800

Darksu gravatar image Darksu
1991 1 4

Hello WilliamB,

ZK has created similar articles for previous versions, so it's possible they will do one for version 8.

Until then please be free to ask anything you need here at the forums and you will get all the answers you need.

Best Regards,

Darksu

link publish delete flag offensive edit

Comments

First issue I'm running into after correcting the SimpleForm compilation issue is : org.zkoss.xel.XelException: Resource not found: http://www.zkoss.org/dsp/web/core

WilliamB ( 2015-10-27 14:36:08 +0800 )edit
0

answered 2015-10-27 15:43:55 +0800

WilliamB gravatar image WilliamB
1609 1 6

updated 2015-10-28 10:27:51 +0800

Ok so here is my way through migrating ZK 7 => 8 I'll split it through several message, hoping it helps other.

MESSAGE 1 :

1°) Compilation issue with SimpleForm removal. => http://blog.zkoss.org/index.php/2015/02/03/zk8-new-form-binding-approach/

2°) Launching Tomcat : Ok Loading my main page in my browser :

org.zkoss.xel.XelException: Resource not found: http://www.zkoss.org/dsp/web/core

I'm referencing the core taglib in my page

<?taglib uri="http://www.zkoss.org/dsp/web/core" prefix="c"?>

I then find another thread about that issue : http://forum.zkoss.org/question/98991/orgzkossxelxelexception-resource-not-found-httpwwwzkossorgdspwebcore/

But no clear answer, since I'm using zkspring I try to update to 3.2.0 as one comment suggest : http://tracker.zkoss.org/browse/ZKSPRING-49

Now when I launch Tomcat :

org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from class path resource [octaveWebContext.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.getEnvironment()Lorg/springframework/core/env/Environment;

Also with the 3.2.0 I'm getting "duplicate" dependency for Spring beans etc ... With the 3.1, I only had the spring-beans-4.1.5.Release (which is the spring version I specify in my pom.xml). With 3.2.0 I get a shitload of spring.jar added like this:

org.springframework.binding-2.2.1.RELEASE.jar
com.springsource.org.apache.commons.logging-1.1.1.jar
org.springframework.beans-3.0.4.RELEASE.jar
org.springframework.core-3.0.4.RELEASE.jar
org.springframework.context-3.0.4.RELEASE.jar
etc...

Once i excluded all those that were duplicate of my own spring dependency the server started fine.

link publish delete flag offensive edit

Comments

I also have the same issue on simpleform . I think they have removed it in ZK8 . What is alternate ?

Senthilchettyin ( 2015-12-11 02:56:20 +0800 )edit
0

answered 2015-10-28 10:27:06 +0800

WilliamB gravatar image WilliamB
1609 1 6

updated 2015-10-28 16:29:39 +0800

MESSAGE 2 :

The application launch, alleluia!

Going to another page I get hit by this error

org.zkoss.zk.ui.UiException: Not allowed to set vflex and height at the same time except vflex="min"

No indication of the zul line or the component type incriminated.

So onward with a breakpoint at the line 450 of HtmlBasedComponent to see which component throws the error. And I start the correctiong the zul.

=> Btw I've no clue why someone put both in the same tag though, so this new exception is welcome imo.


Next issue the autocomplete combobox. Something fishy has changed and the selected element stays in the model even when you change the value in the box, thus autoselecting it again while you are editing the value typed in the field ...

link publish delete flag offensive edit

Comments

I see that all the time, people start with vflex, they don't succeed and start with height and leave the vflex there. Find it good they throw an error for it.

chillworld ( 2015-10-28 12:20:52 +0800 )edit
0

answered 2015-10-29 09:01:00 +0800

Darksu gravatar image Darksu
1991 1 4

Hello WilliamB,

Regarding the autocomplete combobox issue, can you post the code you are using for your tests?

Best Regards,

Darksu

link publish delete flag offensive edit

Comments

I contacted the support and they have created a ticket for it : http://tracker.zkoss.org/browse/ZK-2937

WilliamB ( 2015-10-30 15:42:44 +0800 )edit
0

answered 2015-10-30 15:44:06 +0800

WilliamB gravatar image WilliamB
1609 1 6

Next one is when I've a proxified bean with a java.util.Date field in a Date Picker it breaks :

Cannot create a proxy object:[class java.sql.Date], an empty constructor is needed.

So seems ZK tries to proxify on the wrong Type of Date.

link publish delete flag offensive edit

Comments

Test test test

Senthilchettyin ( 2017-07-22 07:02:44 +0800 )edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
2 followers

RSS

Stats

Asked: 2015-10-27 09:17:48 +0800

Seen: 188 times

Last updated: Mar 30 '16

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More