You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Konstantin Ignatyev (JIRA)" <ji...@apache.org> on 2011/07/12 23:37:03 UTC

[jira] [Created] (WICKET-3891) in development mode Wicket stops picking up markup changes

in development mode Wicket stops picking up markup changes
----------------------------------------------------------

                 Key: WICKET-3891
                 URL: https://issues.apache.org/jira/browse/WICKET-3891
             Project: Wicket
          Issue Type: Bug
          Components: wicket-core
    Affects Versions: 1.5-RC5.1
         Environment: OS X 
            Reporter: Konstantin Ignatyev


I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.

With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.

More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.

That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064775#comment-13064775 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

The problem is not in MarkupCache.
The problem seems to be that org.apache.wicket.page.PageStoreManager.SessionEntry doesn't get serialized and thus the transient field Page#markup is never null-ified, thus the markup cache is not asked at all.

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064354#comment-13064354 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

A quickstart will help us debug it!

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064718#comment-13064718 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

Can you try with 1.5-SNAPSHOT ?
Recently we fixed something similar: WICKET-3878.

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Robert McGuinness (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064237#comment-13064237 ] 

Robert McGuinness commented on WICKET-3891:
-------------------------------------------

Is it similar to https://issues.apache.org/jira/browse/WICKET-3878?

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064787#comment-13064787 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

--- wicket-core/src/main/java/org/apache/wicket/Component.java	(revision 1145858)
+++ wicket-core/src/main/java/org/apache/wicket/Component.java	(working copy)
@@ -3807,6 +3807,10 @@
 	 */
 	protected void onDetach()
 	{
+		if (getApplication().usesDevelopmentConfig())
+		{
+			markup = null;
+		}
 		setFlag(FLAG_DETACHING, false);
 	}

This solves the problem but I'm not sure how it worked before.
The pages touched in one request are cached in the http session so that they are ready to use for the next request. On the next request the new touched pages override the previous ones. 

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13065538#comment-13065538 ] 

Konstantin Ignatyev edited comment on WICKET-3891 at 7/14/11 9:30 PM:
----------------------------------------------------------------------

Tried to create repro project, but cannot. Simple code works fine, but real project does not. However there are couple of things I have noticed: in real project I see version in the page URL even I have disabled it.

 override def init()  {
    super.init()
    getPageSettings.setVersionPagesByDefault(false)

Project is in Scala if that makes any difference for Wicket

And it does not pick up changes to the super class markup, if I update page's markupt then ALL the changes are picked up- in the superclass' markup and in the page's markup

      was (Author: kgignatyev):
    Tried to create repro project, but cannot. Simple code works fine, but real project does not. However there are couple of things I have noticed: in real project I see version in the page URL even I have disabled it.

 override def init()  {
    super.init()
    getMarkupSettings.setStripWicketTags(false)

Project is in Scala if that makes any difference for Wicket

And it does not pick up changes to the super class markup, if I update page's markupt then ALL the changes are picked up- in the superclass' markup and in the page's markup
  
> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13067658#comment-13067658 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

I think the proper fix for MarkupCache is:

--- wicket-core/src/main/java/org/apache/wicket/markup/MarkupCache.java	(revision 1148203)
+++ wicket-core/src/main/java/org/apache/wicket/markup/MarkupCache.java	(working copy)
@@ -198,19 +198,22 @@
 				// if that is cached. If the base markup has been removed, than remove the derived
 				// markup as well.
 
-				MarkupResourceStream resourceStream = markup.getMarkupResourceStream()
-					.getBaseMarkupResourceStream();
-
-				// Is the base markup available in the cache?
-				if ((resourceStream != null) && !isMarkupCached(resourceStream))
+				if (Markup.NO_MARKUP != markup)
 				{
-					iter.remove();
-					count++;
+					MarkupResourceStream resourceStream = markup.getMarkupResourceStream()
+						.getBaseMarkupResourceStream();
 
-					if (log.isDebugEnabled())
+					// Is the base markup available in the cache?
+					if ((resourceStream != null) && !isMarkupCached(resourceStream))
 					{
-						log.debug("Removed derived markup from cache: " +
-							markup.getMarkupResourceStream());
+						iter.remove();
+						count++;
+
+						if (log.isDebugEnabled())
+						{
+							log.debug("Removed derived markup from cache: " +
+								markup.getMarkupResourceStream());
+						}
 					}

I.e. if (markup != Markup.NO_MARKUP) then do the rest. This is the only way markup.getMarkupResourceStream() can return 'null'.

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064797#comment-13064797 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

applied, recompiled, does not help, still superclass markup changes are not reflected

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064241#comment-13064241 ] 

Igor Vaynberg commented on WICKET-3891:
---------------------------------------

WICKET-3878 had to do with parent-child markup relationships. does all markup stop reloading for you after a while? does it do the same if you run without jrebel?

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064766#comment-13064766 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

Just compiled SNAPSHOT from trunk and tried: now that is easy to reproduce I think - markup refresh does not work at all.

I have this chain CorePage <- BaseDecoratedPage <- SubsectionBasePage<- SusectionRealPage1

so I am looking at SusectionRealPage1 that inherits markup from the above chain, and I am changing markup for its superclass  - SubsectionBasePage. The change does not get reflected when I refresh browser pointing at SusectionRealPage1, even if I manually specify new version number for the page - that used to help in RC5.1, see my comment above

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13067415#comment-13067415 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

Here is the exception I saw in the log and after that W stopped picking up markup changes: 
<2011-07-18 15:54:42,502> ERROR [org.apache.wicket.util.thread.Task$1] - Unhandled exception thrown by user code in task ModificationWatcher (ModificationWatcher Task)
java.lang.NullPointerException
	at org.apache.wicket.markup.MarkupCache.removeMarkupWhereBaseMarkupIsNoLongerInTheCache(MarkupCache.java:201)
	at org.apache.wicket.markup.MarkupCache.removeMarkup(MarkupCache.java:149)
	at org.apache.wicket.markup.MarkupCache$1.onChange(MarkupCache.java:518)
	at org.apache.wicket.util.listener.ChangeListenerSet$1.notify(ChangeListenerSet.java:45)
	at org.apache.wicket.util.listener.ChangeListenerSet$1.notify(ChangeListenerSet.java:43)
	at org.apache.wicket.util.listener.ListenerCollection.notify(ListenerCollection.java:79)
	at org.apache.wicket.util.listener.ChangeListenerSet.notifyListeners(ChangeListenerSet.java:40)
	at org.apache.wicket.util.watch.ModificationWatcher$1.run(ModificationWatcher.java:158)
	at org.apache.wicket.util.thread.Task$1.run(Task.java:115)
	at java.lang.Thread.run(Thread.java:680)


At the time application had one page opened in one browser and that page has timer tasks that pings server for updates every second.
Hope that helps



> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Juergen Donnerstag (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Juergen Donnerstag reassigned WICKET-3891:
------------------------------------------

    Assignee: Juergen Donnerstag

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>            Assignee: Juergen Donnerstag
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13065538#comment-13065538 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

Tried to create repro project, but cannot. Simple code works fine, but real project does not. However there are couple of things I have noticed: in real project I see version in the page URL even I have disabled it.

 override def init()  {
    super.init()
    getMarkupSettings.setStripWicketTags(false)

Project is in Scala if that makes any difference for Wicket

And it does not pick up changes to the super class markup, if I update page's markupt then ALL the changes are picked up- in the superclass' markup and in the page's markup

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Juergen Donnerstag (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Juergen Donnerstag resolved WICKET-3891.
----------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5-RC6

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>            Assignee: Juergen Donnerstag
>             Fix For: 1.5-RC6
>
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064801#comment-13064801 ] 

Martin Grigorov commented on WICKET-3891:
-----------------------------------------

Please provide a quickstart with steps to reproduce.

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13064692#comment-13064692 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

Did not try without JRebel as am so addicted to the tool :) however before RC5.1 all was working well therefore I think there is little reason to believe that JRebel causes this to happen.

Would it make sense to add something like 'flush markup cache' to the ajax debug panel that floats at the bottom of the screen in dev mode anyway? 

I wish I had time to recreate this behavior in a repro application - it takes awhile for that behavior to manifest. Is there anything helpful you can get from logs? I could enable them or add logging statement in relevant places in the source if that would be any help for you.

> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-3891) in development mode Wicket stops picking up markup changes

Posted by "Konstantin Ignatyev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13067521#comment-13067521 ] 

Konstantin Ignatyev commented on WICKET-3891:
---------------------------------------------

The following changes fix problem for me:

Index: wicket-core/src/main/java/org/apache/wicket/Component.java
===================================================================
--- wicket-core/src/main/java/org/apache/wicket/Component.java	(revision 1148111)
+++ wicket-core/src/main/java/org/apache/wicket/Component.java	(working copy)
@@ -3807,6 +3807,10 @@
 	 */
 	protected void onDetach()
 	{
+		if (getApplication().usesDevelopmentConfig())
+	    {
+		markup = null;
+		}
 		setFlag(FLAG_DETACHING, false);
 	}
 
Index: wicket-core/src/main/java/org/apache/wicket/markup/MarkupCache.java
===================================================================
--- wicket-core/src/main/java/org/apache/wicket/markup/MarkupCache.java	(revision 1148111)
+++ wicket-core/src/main/java/org/apache/wicket/markup/MarkupCache.java	(working copy)
@@ -197,7 +197,7 @@
 				// Check if the markup associated with key has a base markup. And if yes, test
 				// if that is cached. If the base markup has been removed, than remove the derived
 				// markup as well.
-
+try{
 				MarkupResourceStream resourceStream = markup.getMarkupResourceStream()
 					.getBaseMarkupResourceStream();
 
@@ -213,7 +213,13 @@
 							markup.getMarkupResourceStream());
 					}
 				}
+			}catch(Exception e){
+				e.printStackTrace();
+				log.info("kgi catch happened");
+				iter.remove();
+				count++;
 			}
+			}
 		}
 	}


> in development mode Wicket stops picking up markup changes
> ----------------------------------------------------------
>
>                 Key: WICKET-3891
>                 URL: https://issues.apache.org/jira/browse/WICKET-3891
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: OS X 
>            Reporter: Konstantin Ignatyev
>
> I have wicket application running via mvn jetty:run under JRebel to facilitate code hotswap.
> With 1.5RC5.1 Wicket does not pick markup changes unless I change requested version, and it still put version on URL even I have getPageSettings.setVersionPagesByDefault(false); , but that is a minor inconvenience.
> More annoying that after awhile Wicket stops picking up changes in the markup of components used on my page. I mean that I can change markup for my components and it gets reflected upon page refresh (with requesting non existent version), but at some point it stops, changes to the markup of subcomponents are not picked up.
> That forces me to restart application, which is major productivity killer....

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira