Hello, 

I've just done some debugging work for Ingo Renner. His project is somehow 
similar to the brix cms and the way of manipulating the components within the 
markup stream resolution. This worked in 6.x and 7.0-7.2, but was broken in 
7.3+ with commit: 

https://github.com/apache/wicket/commit/309fb0801a91d1c8be078767243ace384729f7f0
 

as the dequeueAutoComponents not longer was part of the process; A manual 
execution of it alone in e.g.: onInitialize also won't work as only the first 
rendering works, the following wont refresh the markup (since some parts get 
cached contrary to previuous behavior). 

While I understand that its important to enhance wicket as a framework, I 
really dont understand why this has to be done in a subversion. Why not in 
e.g.: wicket 8? This way any upgrade from wicket 7.2 to 7.3 just may break 
existing apps. 

Best, 

Korbinian 

------------------ 

example from Ingo that breaks by just moving from 7.2 to 7.3: 








@Override 

public IResourceStream getMarkupResourceStream(MarkupContainer container , 
Class<?> containerClass ) { 



// This simulates loading the template from external source 

InputStream src = HomePage. class .getResourceAsStream( "HomePageSrc.html" ); 

String srcStr = "" ; 

try { 

srcStr = Streams. readString ( src ); 



// now replacing my special markup "tag" with a real html tag 

srcStr = srcStr .replace( "${tile}" , "<div wicket:id=\"tile\"></div>" ); 



// and adding the component to the page 

HomePage. this .add( new Label( "tile" , Model. of ( "Content of dynamic 
component aka tile." ))); 



} catch (IOException e ) { 

// TODO Auto-generated catch block 

e .printStackTrace(); 

} 

StringResourceStream stringResourceStream = new StringResourceStream( srcStr , 
"text/html" ); 

return stringResourceStream ; 

} 

Reply via email to