基于代理的重装 [英] Agent Based Reloading

查看:71
本文介绍了基于代理的重装的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在grails 1.4路线图中,它提到了基于代理的重新加载,任何人都可以给出一些解释或资源指针吗?

In grails 1.4 roadmap it mentions about Agent Based Reloading , can anyone give some explanations or resource pointers?

谢谢

推荐答案

它作为JVM代理实现-请参见 http://java.sun.com/developer/technicalArticles/J2SE/jvm_ti/了解详细信息.

It's implemented as a JVM agent - see http://java.sun.com/developer/technicalArticles/J2SE/jvm_ti/ for the gory details.

实际上,这意味着在开发人员模式下,该代理现在不使用自定义类加载器来重新加载控制器,服务等,而是热交换重新编译的类.这意味着它不再局限于Groovy中编写的grails-app工件.现在,它适用于所有类,包括src/java和src/groovy,它们在当前版本中会在更改后触发应用程序重新启动.

In practice what it means is that in dev mode, instead of using custom classloaders to reload controllers, services, etc., the agent now hot-swaps the recompiled classes. This means that it's no longer limited to grails-app artifacts writen in Groovy. It now works with all classes including src/java and src/groovy which in current versions trigger app restarts when changed.

还-您现在可以即时编辑域类.当前,这还会触发应用程序重新启动,但是在1.4版本中,它将重新构建Hibernate SessionFactory并继续运行.

Also - you can now edit domain classes on the fly. This currently also triggers an app restart but in 1.4 will rebuild the Hibernate SessionFactory and keep running.

这篇关于基于代理的重装的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆