Intellij IDEA + JBoss不会在运行时编译时更新LESS文件 [英] Intellij IDEA + JBoss doesn't update LESS files on runtime compilation

查看:140
本文介绍了Intellij IDEA + JBoss不会在运行时编译时更新LESS文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

不幸的是,谷歌搜索没有帮助:( 我已经在集成在Intellij IDEA中的JBoss5.x上部署了一个简单的项目. 我在JSP页面上使用了一些mvc框架. 因此,我运行我的项目,并使用它,当我编辑任何JSP时,我只需单击运行" >>更新JBoss" >>更新资源",我对JSP所做的所有更改都将应用,而无需重新部署服务器. 但这不适用于LESS文件(LESS用于动态CSS).我不知道为什么?有提示吗?

unfortunately googling didn't help :( I have deployed a simple project on JBoss5.x integrated in my Intellij IDEA. I use some mvc frameworks with JSP pages. So I run my project, works with it and when I edit any JSP I can just click "Run" >> "Update JBoss" >> "Update resources" and all my changes to JSPs will be applied without redeploying the server. But this doesn't work with LESS files (LESS is for dynamic css). I cannot figured out why? Any hints?

PS:在JSP上正确提及的文件较少,因此可以正常应用,但是如果不重新部署就无法应用对其所做的更改.

PS: less file is mentioned on JSP correctly, so it is applied normally, but changes to it cannot be applied without redeploying.

推荐答案

尝试直接部署文件(而不是通过IDEA),以查看这是您的IDE配置问题还是服务器端问题.

Try deploying the files directly, not through IDEA, to see if it's a problem of your IDE configuration or a server-side issue.

如果是服务器端问题(即使直接部署也无法部署文件),请尝试检查诸如文件权限之类的内容,部署程序是否正常工作以及是否正在侦听新文件等.如果不实际重新部署应用程序的整个模块,则无法热部署"某些文件.

If it's a server-side problem (the files don't get deployed even with the direct deploy), then try checking stuff like permissions on files, if the deployer works and if it's listening for new files, etc.. Also some files cannot be "hot-deployed" without actual redeploying of the whole module of your application.

如果您的IDE有问题,请尝试检查您的配置.以下是一些可以帮助您入门的链接:

If it's a problem with your IDE then try checking your configuration. Here are some links which should help you get started:

http://www.jetbrains.com/idea/training/demos /JBoss_server.html

https://community.jboss.org/thread/202446 ?start = 0& tstart = 0

Intellij如何部署到JBoss?

如果还有其他问题,请在评论中提问.干杯!

If you have any further questions, please ask in the comments. Cheers!

我不是热部署专家,也不能确切指定可以或不能热部署哪些文件,但是AFAIK可以热部署对类的更改,而不会更改类的结构.大多数情况下,这意味着您可以更改方法的主体并进行热部署,而不会出现任何问题,但是,如果重命名或完全添加新方法,将无法进行热交换.另一件事是文件发现-在服务器启动阶段发现的文件如果不重新启动或以其他方式通知服务器重新加载它们,则无法进行热部署.这可能是您的情况..我希望有人会更好地指定这些热部署限制.

I am not an expert on hot deployment, nor can I specify exactly which files can or cannot be hot-deployed, but AFAIK you can hot-deploy changes to your classes which do not change the structure of your class. This most of the time means that you can change the body of a method and hotdeploy it without any problems, however if you rename it or add new methods completely you won't be able to hot-swap them. Another thing is file discovery - files which are discovered during the startup phase of the server cannot be hotdeployed without a restart or some other way which tells the server to reload them. This might be your case.. I hope that someone will specify these hot-deploying limits better.

这篇关于Intellij IDEA + JBoss不会在运行时编译时更新LESS文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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