You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by Matthias Wessendorf <ma...@apache.org> on 2009/08/27 13:08:23 UTC

Re: Scripting Extensions, java!!! reloading now working (with limitations)

pretty cool!

thanks!
Matthias

On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
> Hello everyone, here is a small bomb I am dropping, some might have
> noticed already by the Jira entries.
>
> This minute I committed a first preliminary working version of the
> Java!!! reloading code.
> It still is rough and has limitations, but it works already for expanded
> webapps.
>
> Ok here is how it goes: I basically just dynamically recompile the
> objects on the fly and try to save attributes of the old instance
> in the new one. Since JSF has introspection left and right, this works
> out pretty well.
>
> If you check out the web.xml of the provided example you can find two
> config entries which you can use to point towards your real source
> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
> path.
>
> You can run after adjusting your web.xml the example via
> mvn:jetty-run:exploded and you can edit the provided java classes
> of the example (TestBean under WEB-INF/java and its dependencies)
> on the fly and what the code being recompiled on the fly
> and new adjustments being applied without server restarts!
>
> Following limitations are present for now
>
> a) Statically compiled java code can only call the dynamic one either by
> using introspection or by using interfaces, otherwise you will
> get class cast exceptions even if the classname of the dynamic class
> does not change (the engine sees two classes both having the same name
> but are different)
>
> b) You can run currently only in webapp environments (EAR for now is not
>  fully supported) and exploded, I will work out those limitations in the
> long run, but for now I am happy that it even works!
>
>
> Happy hacking
>
> Werner
>
>
>



-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf

Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Werner Punz <we...@gmail.com>.
Also Bruno feel free to contact me privately via gmail if you have
problems setting it up.

Werner


Werner Punz schrieb:
> Could be that the maven repos dont have it yet,
> Get the latest trunk from myfaces 1.2 and compile it.
> 
> Werner
> 
> 
> Bruno Aranda schrieb:
>> Hi, I am having compilation problems when compiling the extensions
>> core. Do these missing symbols come from a version of the MyFaces
>> 1.2.8-SNAPSHOT that is not yet present in the maven repositories?
>>
>> Cheers,
>>
>> Bruno
>>
>> [INFO] Compilation failure
>>
>> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[25,42]
>> cannot find symbol
>> symbol  : class ClassLoaderExtension
>> location: package org.apache.myfaces.shared_impl.util
>>
>> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[37,39]
>> cannot find symbol
>> symbol: class ClassLoaderExtension
>> public class CustomChainLoader extends ClassLoaderExtension {
>>
>> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[25,32]
>> cannot find symbol
>> symbol  : class StartupListener
>> location: package org.apache.myfaces.webapp
>>
>> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[36,63]
>> cannot find symbol
>> symbol: class StartupListener
>> public class StartupServletContextPluginChainLoader implements StartupListener {
>>
>> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[48,18]
>> cannot find symbol
>> symbol  : method
>> addClassLoadingExtension(org.apache.myfaces.scripting.servlet.CustomChainLoader,boolean)
>> location: class org.apache.myfaces.shared_impl.util.ClassUtils
>>
>>
>>
>> 2009/8/27 Bruno Aranda <br...@gmail.com>:
>>> That is really excellent news! Thanks!
>>>
>>> Bruno
>>>
>>> 2009/8/27 Matthias Wessendorf <ma...@apache.org>:
>>>> pretty cool!
>>>>
>>>> thanks!
>>>> Matthias
>>>>
>>>> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>>>>> Hello everyone, here is a small bomb I am dropping, some might have
>>>>> noticed already by the Jira entries.
>>>>>
>>>>> This minute I committed a first preliminary working version of the
>>>>> Java!!! reloading code.
>>>>> It still is rough and has limitations, but it works already for expanded
>>>>> webapps.
>>>>>
>>>>> Ok here is how it goes: I basically just dynamically recompile the
>>>>> objects on the fly and try to save attributes of the old instance
>>>>> in the new one. Since JSF has introspection left and right, this works
>>>>> out pretty well.
>>>>>
>>>>> If you check out the web.xml of the provided example you can find two
>>>>> config entries which you can use to point towards your real source
>>>>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>>>>> path.
>>>>>
>>>>> You can run after adjusting your web.xml the example via
>>>>> mvn:jetty-run:exploded and you can edit the provided java classes
>>>>> of the example (TestBean under WEB-INF/java and its dependencies)
>>>>> on the fly and what the code being recompiled on the fly
>>>>> and new adjustments being applied without server restarts!
>>>>>
>>>>> Following limitations are present for now
>>>>>
>>>>> a) Statically compiled java code can only call the dynamic one either by
>>>>> using introspection or by using interfaces, otherwise you will
>>>>> get class cast exceptions even if the classname of the dynamic class
>>>>> does not change (the engine sees two classes both having the same name
>>>>> but are different)
>>>>>
>>>>> b) You can run currently only in webapp environments (EAR for now is not
>>>>>  fully supported) and exploded, I will work out those limitations in the
>>>>> long run, but for now I am happy that it even works!
>>>>>
>>>>>
>>>>> Happy hacking
>>>>>
>>>>> Werner
>>>>>
>>>>>
>>>>>
>>>>
>>>> --
>>>> Matthias Wessendorf
>>>>
>>>> blog: http://matthiaswessendorf.wordpress.com/
>>>> sessions: http://www.slideshare.net/mwessendorf
>>>> twitter: http://twitter.com/mwessendorf
>>>>
> 
> 


Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Werner Punz <we...@gmail.com>.
Could be that the maven repos dont have it yet,
Get the latest trunk from myfaces 1.2 and compile it.

Werner


Bruno Aranda schrieb:
> Hi, I am having compilation problems when compiling the extensions
> core. Do these missing symbols come from a version of the MyFaces
> 1.2.8-SNAPSHOT that is not yet present in the maven repositories?
> 
> Cheers,
> 
> Bruno
> 
> [INFO] Compilation failure
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[25,42]
> cannot find symbol
> symbol  : class ClassLoaderExtension
> location: package org.apache.myfaces.shared_impl.util
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[37,39]
> cannot find symbol
> symbol: class ClassLoaderExtension
> public class CustomChainLoader extends ClassLoaderExtension {
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[25,32]
> cannot find symbol
> symbol  : class StartupListener
> location: package org.apache.myfaces.webapp
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[36,63]
> cannot find symbol
> symbol: class StartupListener
> public class StartupServletContextPluginChainLoader implements StartupListener {
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[48,18]
> cannot find symbol
> symbol  : method
> addClassLoadingExtension(org.apache.myfaces.scripting.servlet.CustomChainLoader,boolean)
> location: class org.apache.myfaces.shared_impl.util.ClassUtils
> 
> 
> 
> 2009/8/27 Bruno Aranda <br...@gmail.com>:
>> That is really excellent news! Thanks!
>>
>> Bruno
>>
>> 2009/8/27 Matthias Wessendorf <ma...@apache.org>:
>>> pretty cool!
>>>
>>> thanks!
>>> Matthias
>>>
>>> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>>>> Hello everyone, here is a small bomb I am dropping, some might have
>>>> noticed already by the Jira entries.
>>>>
>>>> This minute I committed a first preliminary working version of the
>>>> Java!!! reloading code.
>>>> It still is rough and has limitations, but it works already for expanded
>>>> webapps.
>>>>
>>>> Ok here is how it goes: I basically just dynamically recompile the
>>>> objects on the fly and try to save attributes of the old instance
>>>> in the new one. Since JSF has introspection left and right, this works
>>>> out pretty well.
>>>>
>>>> If you check out the web.xml of the provided example you can find two
>>>> config entries which you can use to point towards your real source
>>>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>>>> path.
>>>>
>>>> You can run after adjusting your web.xml the example via
>>>> mvn:jetty-run:exploded and you can edit the provided java classes
>>>> of the example (TestBean under WEB-INF/java and its dependencies)
>>>> on the fly and what the code being recompiled on the fly
>>>> and new adjustments being applied without server restarts!
>>>>
>>>> Following limitations are present for now
>>>>
>>>> a) Statically compiled java code can only call the dynamic one either by
>>>> using introspection or by using interfaces, otherwise you will
>>>> get class cast exceptions even if the classname of the dynamic class
>>>> does not change (the engine sees two classes both having the same name
>>>> but are different)
>>>>
>>>> b) You can run currently only in webapp environments (EAR for now is not
>>>>  fully supported) and exploded, I will work out those limitations in the
>>>> long run, but for now I am happy that it even works!
>>>>
>>>>
>>>> Happy hacking
>>>>
>>>> Werner
>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Matthias Wessendorf
>>>
>>> blog: http://matthiaswessendorf.wordpress.com/
>>> sessions: http://www.slideshare.net/mwessendorf
>>> twitter: http://twitter.com/mwessendorf
>>>
> 


Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Matthias Wessendorf <ma...@apache.org>.
On Thu, Sep 3, 2009 at 2:20 PM, Werner Punz<we...@gmail.com> wrote:
> Ok... another scripting extension question.
>
> I probably will work the last things out I have to deal with on friday,
> or monday next week.
> (Some classpath issues are still pending in the java area)
>
> So far we have covered groovy and java but currently under JDK 1.2
>
> What should we do next
>
> a) Either integrate more scripting languages, probably jruby could be a
> possible candidate due to being able to handle dynamic compilation, jython I
> am not sure for now I have to check out what it can do)
>
> b) Integrate JCI for java dynamic recompilation to handle pre jdk6 jdks
>
> c) Start with the myfaces 2.0 integration
>
> d) Start with the documentation on the wiki
>
> I would prefer c) to get things going for 2.0

+1

>
> But I wanted to ask the community first.
>
>
> Werner
>
>
> Werner Punz schrieb:
>>
>> Ok the current1.2 branch currently is not in the nightly builds.
>> This will be fixed soon  in the meanwhile do a manual checkout of the
>> current1.2 branch that should resolve the problem.
>> I committed the changes to the startup infrastructure about a week ago.
>> So checking out should work.
>>
>
>



-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf

Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Werner Punz <we...@gmail.com>.
Ok... another scripting extension question.

I probably will work the last things out I have to deal with on friday,
or monday next week.
(Some classpath issues are still pending in the java area)

So far we have covered groovy and java but currently under JDK 1.2

What should we do next

a) Either integrate more scripting languages, probably jruby could be a 
possible candidate due to being able to handle dynamic compilation, 
jython I am not sure for now I have to check out what it can do)

b) Integrate JCI for java dynamic recompilation to handle pre jdk6 jdks

c) Start with the myfaces 2.0 integration

d) Start with the documentation on the wiki

I would prefer c) to get things going for 2.0

But I wanted to ask the community first.


Werner


Werner Punz schrieb:
> Ok the current1.2 branch currently is not in the nightly builds.
> This will be fixed soon  in the meanwhile do a manual checkout of the
> current1.2 branch that should resolve the problem.
> I committed the changes to the startup infrastructure about a week ago.
> So checking out should work.
> 


Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Werner Punz <we...@gmail.com>.
Ok the current1.2 branch currently is not in the nightly builds.
This will be fixed soon  in the meanwhile do a manual checkout of the
current1.2 branch that should resolve the problem.
I committed the changes to the startup infrastructure about a week ago.
So checking out should work.

Werner


Bruno Aranda schrieb:
> Hi, I am having compilation problems when compiling the extensions
> core. Do these missing symbols come from a version of the MyFaces
> 1.2.8-SNAPSHOT that is not yet present in the maven repositories?
> 
> Cheers,
> 
> Bruno
> 
> [INFO] Compilation failure
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[25,42]
> cannot find symbol
> symbol  : class ClassLoaderExtension
> location: package org.apache.myfaces.shared_impl.util
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[37,39]
> cannot find symbol
> symbol: class ClassLoaderExtension
> public class CustomChainLoader extends ClassLoaderExtension {
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[25,32]
> cannot find symbol
> symbol  : class StartupListener
> location: package org.apache.myfaces.webapp
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[36,63]
> cannot find symbol
> symbol: class StartupListener
> public class StartupServletContextPluginChainLoader implements StartupListener {
> 
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[48,18]
> cannot find symbol
> symbol  : method
> addClassLoadingExtension(org.apache.myfaces.scripting.servlet.CustomChainLoader,boolean)
> location: class org.apache.myfaces.shared_impl.util.ClassUtils
> 
> 
> 
> 2009/8/27 Bruno Aranda <br...@gmail.com>:
>> That is really excellent news! Thanks!
>>
>> Bruno
>>
>> 2009/8/27 Matthias Wessendorf <ma...@apache.org>:
>>> pretty cool!
>>>
>>> thanks!
>>> Matthias
>>>
>>> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>>>> Hello everyone, here is a small bomb I am dropping, some might have
>>>> noticed already by the Jira entries.
>>>>
>>>> This minute I committed a first preliminary working version of the
>>>> Java!!! reloading code.
>>>> It still is rough and has limitations, but it works already for expanded
>>>> webapps.
>>>>
>>>> Ok here is how it goes: I basically just dynamically recompile the
>>>> objects on the fly and try to save attributes of the old instance
>>>> in the new one. Since JSF has introspection left and right, this works
>>>> out pretty well.
>>>>
>>>> If you check out the web.xml of the provided example you can find two
>>>> config entries which you can use to point towards your real source
>>>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>>>> path.
>>>>
>>>> You can run after adjusting your web.xml the example via
>>>> mvn:jetty-run:exploded and you can edit the provided java classes
>>>> of the example (TestBean under WEB-INF/java and its dependencies)
>>>> on the fly and what the code being recompiled on the fly
>>>> and new adjustments being applied without server restarts!
>>>>
>>>> Following limitations are present for now
>>>>
>>>> a) Statically compiled java code can only call the dynamic one either by
>>>> using introspection or by using interfaces, otherwise you will
>>>> get class cast exceptions even if the classname of the dynamic class
>>>> does not change (the engine sees two classes both having the same name
>>>> but are different)
>>>>
>>>> b) You can run currently only in webapp environments (EAR for now is not
>>>>  fully supported) and exploded, I will work out those limitations in the
>>>> long run, but for now I am happy that it even works!
>>>>
>>>>
>>>> Happy hacking
>>>>
>>>> Werner
>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Matthias Wessendorf
>>>
>>> blog: http://matthiaswessendorf.wordpress.com/
>>> sessions: http://www.slideshare.net/mwessendorf
>>> twitter: http://twitter.com/mwessendorf
>>>
> 


Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Matthias Wessendorf <ma...@apache.org>.
On Thu, Aug 27, 2009 at 2:09 PM, Bruno Aranda<br...@gmail.com> wrote:
> Hi, I am having compilation problems when compiling the extensions
> core. Do these missing symbols come from a version of the MyFaces
> 1.2.8-SNAPSHOT that is not yet present in the maven repositories?

Nope. There is no ci on the 1.2.8 stuff. That happened when we
switched the trunk
(and made 1.2 a branch). Let me ping Leo

-Matthias

>
> Cheers,
>
> Bruno
>
> [INFO] Compilation failure
>
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[25,42]
> cannot find symbol
> symbol  : class ClassLoaderExtension
> location: package org.apache.myfaces.shared_impl.util
>
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[37,39]
> cannot find symbol
> symbol: class ClassLoaderExtension
> public class CustomChainLoader extends ClassLoaderExtension {
>
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[25,32]
> cannot find symbol
> symbol  : class StartupListener
> location: package org.apache.myfaces.webapp
>
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[36,63]
> cannot find symbol
> symbol: class StartupListener
> public class StartupServletContextPluginChainLoader implements StartupListener {
>
> /scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[48,18]
> cannot find symbol
> symbol  : method
> addClassLoadingExtension(org.apache.myfaces.scripting.servlet.CustomChainLoader,boolean)
> location: class org.apache.myfaces.shared_impl.util.ClassUtils
>
>
>
> 2009/8/27 Bruno Aranda <br...@gmail.com>:
>> That is really excellent news! Thanks!
>>
>> Bruno
>>
>> 2009/8/27 Matthias Wessendorf <ma...@apache.org>:
>>> pretty cool!
>>>
>>> thanks!
>>> Matthias
>>>
>>> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>>>> Hello everyone, here is a small bomb I am dropping, some might have
>>>> noticed already by the Jira entries.
>>>>
>>>> This minute I committed a first preliminary working version of the
>>>> Java!!! reloading code.
>>>> It still is rough and has limitations, but it works already for expanded
>>>> webapps.
>>>>
>>>> Ok here is how it goes: I basically just dynamically recompile the
>>>> objects on the fly and try to save attributes of the old instance
>>>> in the new one. Since JSF has introspection left and right, this works
>>>> out pretty well.
>>>>
>>>> If you check out the web.xml of the provided example you can find two
>>>> config entries which you can use to point towards your real source
>>>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>>>> path.
>>>>
>>>> You can run after adjusting your web.xml the example via
>>>> mvn:jetty-run:exploded and you can edit the provided java classes
>>>> of the example (TestBean under WEB-INF/java and its dependencies)
>>>> on the fly and what the code being recompiled on the fly
>>>> and new adjustments being applied without server restarts!
>>>>
>>>> Following limitations are present for now
>>>>
>>>> a) Statically compiled java code can only call the dynamic one either by
>>>> using introspection or by using interfaces, otherwise you will
>>>> get class cast exceptions even if the classname of the dynamic class
>>>> does not change (the engine sees two classes both having the same name
>>>> but are different)
>>>>
>>>> b) You can run currently only in webapp environments (EAR for now is not
>>>>  fully supported) and exploded, I will work out those limitations in the
>>>> long run, but for now I am happy that it even works!
>>>>
>>>>
>>>> Happy hacking
>>>>
>>>> Werner
>>>>
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Matthias Wessendorf
>>>
>>> blog: http://matthiaswessendorf.wordpress.com/
>>> sessions: http://www.slideshare.net/mwessendorf
>>> twitter: http://twitter.com/mwessendorf
>>>
>>
>



-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf

Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Bruno Aranda <br...@gmail.com>.
Hi, I am having compilation problems when compiling the extensions
core. Do these missing symbols come from a version of the MyFaces
1.2.8-SNAPSHOT that is not yet present in the maven repositories?

Cheers,

Bruno

[INFO] Compilation failure

/scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[25,42]
cannot find symbol
symbol  : class ClassLoaderExtension
location: package org.apache.myfaces.shared_impl.util

/scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/CustomChainLoader.java:[37,39]
cannot find symbol
symbol: class ClassLoaderExtension
public class CustomChainLoader extends ClassLoaderExtension {

/scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[25,32]
cannot find symbol
symbol  : class StartupListener
location: package org.apache.myfaces.webapp

/scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[36,63]
cannot find symbol
symbol: class StartupListener
public class StartupServletContextPluginChainLoader implements StartupListener {

/scratch/projects/myfaces-extensions-scripting/core/src/main/java/org/apache/myfaces/scripting/servlet/StartupServletContextPluginChainLoader.java:[48,18]
cannot find symbol
symbol  : method
addClassLoadingExtension(org.apache.myfaces.scripting.servlet.CustomChainLoader,boolean)
location: class org.apache.myfaces.shared_impl.util.ClassUtils



2009/8/27 Bruno Aranda <br...@gmail.com>:
> That is really excellent news! Thanks!
>
> Bruno
>
> 2009/8/27 Matthias Wessendorf <ma...@apache.org>:
>> pretty cool!
>>
>> thanks!
>> Matthias
>>
>> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>>> Hello everyone, here is a small bomb I am dropping, some might have
>>> noticed already by the Jira entries.
>>>
>>> This minute I committed a first preliminary working version of the
>>> Java!!! reloading code.
>>> It still is rough and has limitations, but it works already for expanded
>>> webapps.
>>>
>>> Ok here is how it goes: I basically just dynamically recompile the
>>> objects on the fly and try to save attributes of the old instance
>>> in the new one. Since JSF has introspection left and right, this works
>>> out pretty well.
>>>
>>> If you check out the web.xml of the provided example you can find two
>>> config entries which you can use to point towards your real source
>>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>>> path.
>>>
>>> You can run after adjusting your web.xml the example via
>>> mvn:jetty-run:exploded and you can edit the provided java classes
>>> of the example (TestBean under WEB-INF/java and its dependencies)
>>> on the fly and what the code being recompiled on the fly
>>> and new adjustments being applied without server restarts!
>>>
>>> Following limitations are present for now
>>>
>>> a) Statically compiled java code can only call the dynamic one either by
>>> using introspection or by using interfaces, otherwise you will
>>> get class cast exceptions even if the classname of the dynamic class
>>> does not change (the engine sees two classes both having the same name
>>> but are different)
>>>
>>> b) You can run currently only in webapp environments (EAR for now is not
>>>  fully supported) and exploded, I will work out those limitations in the
>>> long run, but for now I am happy that it even works!
>>>
>>>
>>> Happy hacking
>>>
>>> Werner
>>>
>>>
>>>
>>
>>
>>
>> --
>> Matthias Wessendorf
>>
>> blog: http://matthiaswessendorf.wordpress.com/
>> sessions: http://www.slideshare.net/mwessendorf
>> twitter: http://twitter.com/mwessendorf
>>
>

Re: Scripting Extensions, java!!! reloading now working (with limitations)

Posted by Bruno Aranda <br...@gmail.com>.
That is really excellent news! Thanks!

Bruno

2009/8/27 Matthias Wessendorf <ma...@apache.org>:
> pretty cool!
>
> thanks!
> Matthias
>
> On Thu, Aug 27, 2009 at 12:57 PM, Werner Punz<we...@gmail.com> wrote:
>> Hello everyone, here is a small bomb I am dropping, some might have
>> noticed already by the Jira entries.
>>
>> This minute I committed a first preliminary working version of the
>> Java!!! reloading code.
>> It still is rough and has limitations, but it works already for expanded
>> webapps.
>>
>> Ok here is how it goes: I basically just dynamically recompile the
>> objects on the fly and try to save attributes of the old instance
>> in the new one. Since JSF has introspection left and right, this works
>> out pretty well.
>>
>> If you check out the web.xml of the provided example you can find two
>> config entries which you can use to point towards your real source
>> paths, otherwise WEB-INF/groovy and WEB-INF/java is picked up as source
>> path.
>>
>> You can run after adjusting your web.xml the example via
>> mvn:jetty-run:exploded and you can edit the provided java classes
>> of the example (TestBean under WEB-INF/java and its dependencies)
>> on the fly and what the code being recompiled on the fly
>> and new adjustments being applied without server restarts!
>>
>> Following limitations are present for now
>>
>> a) Statically compiled java code can only call the dynamic one either by
>> using introspection or by using interfaces, otherwise you will
>> get class cast exceptions even if the classname of the dynamic class
>> does not change (the engine sees two classes both having the same name
>> but are different)
>>
>> b) You can run currently only in webapp environments (EAR for now is not
>>  fully supported) and exploded, I will work out those limitations in the
>> long run, but for now I am happy that it even works!
>>
>>
>> Happy hacking
>>
>> Werner
>>
>>
>>
>
>
>
> --
> Matthias Wessendorf
>
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> twitter: http://twitter.com/mwessendorf
>