将应用程序升级到Grails 2后JBoss部署错误(JBoss deploy error after upgrading app to Grails 2)
我已将Grails应用程序从1.3.6升级到2.1.1。 经过一些修复和整理后,run-app可以运行(大多数情况下,还有一些已弃用的问题需要处理)。 grails war也可以毫无错误地构建。
然而,当我部署到JBoss(4.2.2)时,与grails 1.3.6战争相同,我得到了这个错误:
Caused by: javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null] at org.apache.tomcat.util.modeler.ManagedBean.getSetter(ManagedBean.java:560) at org.apache.tomcat.util.modeler.BaseModelMBean.setAttribute(BaseModelMBean.java:407) at org.jboss.mx.server.RawDynamicInvoker.setAttribute(RawDynamicInvoker.java:70) at org.jboss.mx.server.MBeanServerImpl.setAttribute(MBeanServerImpl.java:608) at org.jboss.web.tomcat.service.TomcatDeployer.performDeployInternal(TomcatDeployer.java:212) at org.jboss.web.tomcat.service.TomcatDeployer.performDeploy(TomcatDeployer.java:104) at org.jboss.web.AbstractWebDeployer.start(AbstractWebDeployer.java:375) ... 112 more Caused by: java.lang.NoSuchMethodException: org.apache.catalina.core.StandardContext.setLoader(org.apache.catalina.Loader) at java.lang.Class.getMethod(Class.java:1605) at org.apache.tomcat.util.modeler.ManagedBean.getSetter(ManagedBean.java:553) ... 118 more 2012-11-08 16:09:51,604 INFO [org.jboss.web.tomcat.service.TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/ 2012-11-08 16:09:51,664 ERROR [org.jboss.deployment.scanner.URLDeploymentScanner] Incomplete Deployment listing: --- Incompletely deployed packages --- org.jboss.deployment.DeploymentInfo@5cc18807 { url=file:/usr/local/JBoss/jboss-4.2.2.GA/server/default/deploy/xxxxx-1.0.war } deployer: MBeanProxyExt[jboss.web:service=WebServer] status: Deployment FAILED reason: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null]) state: FAILED watch: file:/usr/local/JBoss/jboss-4.2.2.GA/server/default/deploy/xxxxx-1.0.war altDD: null lastDeployed: 1352390987263 lastModified: 1352390987000 mbeans: --- MBeans waiting for other MBeans --- ObjectName: jboss.web.deployment:war=xxxxx-1.0.war,id=1556187143 State: FAILED Reason: org.jboss.deployment.DeploymentException: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null]) --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM --- ObjectName: jboss.web.deployment:war=xxxxx-1.0.war,id=1556187143 State: FAILED Reason: org.jboss.deployment.DeploymentException: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null])
所以我认为这是战争中的一个libalina类和一个已经在jboss中的catalina类之间的碰撞? 因为它在1.3.6时工作正常,是否已经添加到2.1.1 grails tomcat插件中,是否可以从grails插件中排除子依赖项?
谢谢。
I've upgraded a Grails app from 1.3.6 to 2.1.1. After some fixing and tidying up, run-app works (for the most part, still some deprecated issues to deal with). grails war also builds without error.
When I deploy into JBoss (4.2.2) however, the same as has been done for the grails 1.3.6 war, I get this error:
Caused by: javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null] at org.apache.tomcat.util.modeler.ManagedBean.getSetter(ManagedBean.java:560) at org.apache.tomcat.util.modeler.BaseModelMBean.setAttribute(BaseModelMBean.java:407) at org.jboss.mx.server.RawDynamicInvoker.setAttribute(RawDynamicInvoker.java:70) at org.jboss.mx.server.MBeanServerImpl.setAttribute(MBeanServerImpl.java:608) at org.jboss.web.tomcat.service.TomcatDeployer.performDeployInternal(TomcatDeployer.java:212) at org.jboss.web.tomcat.service.TomcatDeployer.performDeploy(TomcatDeployer.java:104) at org.jboss.web.AbstractWebDeployer.start(AbstractWebDeployer.java:375) ... 112 more Caused by: java.lang.NoSuchMethodException: org.apache.catalina.core.StandardContext.setLoader(org.apache.catalina.Loader) at java.lang.Class.getMethod(Class.java:1605) at org.apache.tomcat.util.modeler.ManagedBean.getSetter(ManagedBean.java:553) ... 118 more 2012-11-08 16:09:51,604 INFO [org.jboss.web.tomcat.service.TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/ 2012-11-08 16:09:51,664 ERROR [org.jboss.deployment.scanner.URLDeploymentScanner] Incomplete Deployment listing: --- Incompletely deployed packages --- org.jboss.deployment.DeploymentInfo@5cc18807 { url=file:/usr/local/JBoss/jboss-4.2.2.GA/server/default/deploy/xxxxx-1.0.war } deployer: MBeanProxyExt[jboss.web:service=WebServer] status: Deployment FAILED reason: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null]) state: FAILED watch: file:/usr/local/JBoss/jboss-4.2.2.GA/server/default/deploy/xxxxx-1.0.war altDD: null lastDeployed: 1352390987263 lastModified: 1352390987000 mbeans: --- MBeans waiting for other MBeans --- ObjectName: jboss.web.deployment:war=xxxxx-1.0.war,id=1556187143 State: FAILED Reason: org.jboss.deployment.DeploymentException: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null]) --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM --- ObjectName: jboss.web.deployment:war=xxxxx-1.0.war,id=1556187143 State: FAILED Reason: org.jboss.deployment.DeploymentException: Error during deploy; - nested throwable: (javax.management.ReflectionException: Cannot find setter method setLoader StandardContext[null])
So am thinking it's a collision between a catalina class in a lib in the war, and one already in jboss? As it worked ok when it was 1.3.6, is it something that's been added to the 2.1.1 grails tomcat plugin and is it possible to exclude a sub-dependency from a grails plugin?
Thanks.
原文:https://stackoverflow.com/questions/13294348
最满意答案
'0' + rem
没有按你的想法做:'0'
是char
字面值,rem
是int
值。 将它们一起添加将产生一个int
,表示ASCII值为'0'
或'1'
。更多信息: “将int转换为ASCII字符”
'0' + rem
is not doing what you think:'0'
is achar
literal andrem
is anint
value. Adding them together will result in anint
that represents the ASCII value of either'0'
or'1'
.More information: "Convert an int to ASCII character"
相关问答
更多-
十进制到二进制转换(Decimal to Binary Conversion)[2023-05-22]
当你说while (number) , number ,这是一个int ,被转换为bool类型。 如果它为零,则它变为false ,如果它不为零,则它变为true 。 当你说while (number == true) , true被转换为一个int (变成1 ),它和你在while (number == 1)所说的一样。 When you say while (number), number, which is an int, is converted to type bool. If it is zer ... -
您可以使用Math :: BigInt 。 请注意,这些函数的输入应该是字符串。 use Math::BigInt; sub bin2dec { my $bin = shift; return Math::BigInt->new("0b$bin"); } sub dec2bin { my $dec = shift; my $i = Math::BigInt->new($dec); return substr($i->as_bin(), 2); } print "Dec: " . b ...
-
Perl十进制转换为二进制(Perl decimal to binary conversion)[2022-06-27]
你的问题如下: 如何构建字符串%5b ,其中5是可变的? 使用连接。 "%".$width."b" 这也可以写成 "%${width}b" 在更复杂的情况下,您可能想要使用以下内容,但在这里过度使用。 join('', "%", $width, "b") 请注意, sprintf接受*作为要在变量中提供的值的占位符。 sprintf("%*b", $width, $num) 如果你想要前导零而不是前导空格,只需在%后面加一个0 。 Your question amounts to the follo ... -
在C ++中,最简单的方法可能是使用std::bitset : #include
#include int main() { int x = 5; std::bitset<8> bin_x(x); std::cout << bin_x; return 0; } 结果: 00000101 In C++, the easiest way is probably to use a std::bitset: #include 在没有LINQ的情况下做: var s = "101011"; // my binary "number" as a string var dec = 0; for( int i=0; ichar binary[count]; int length = strlen(binary); 这里的binary已被分配,但没有初始化任何东西。 它可以包含任何东西 - 那么你期望的长度是什么? char binary[count]; int length = strlen(binary); binary here has been allocated but not initialised to anything. It could contain anything - so what do yo ...假设二进制整数的长度不超过8位。 调用BinToDec() char Input[9]; cout << "Please enter the 8-bit binary:\n"; cin >> (Input); cout << BinToDec(Input); 你需要创建一个至少有8 + 1个元素的char数组,char数组字符串的最后一个元素总是0。 int BinToDec(char* BinIn){ int intOut = 0; intOut = intOut + (BinIn[0 ...'0' + rem没有按你的想法做: '0'是char字面值, rem是int值。 将它们一起添加将产生一个int ,表示ASCII值为'0'或'1' 。 更多信息: “将int转换为ASCII字符” '0' + rem is not doing what you think: '0' is a char literal and rem is an int value. Adding them together will result in an int that represents the ASCII ...基本二进制到十进制转换程序不起作用(Python)(Basic Binary to Decimal Conversion Program not working (Python))[2021-08-01]
首先,您使用=进行比较测试。 相反,我认为你想使用!= (不等于): while n != 1: =仅用于分配。 另外,该行: n/10 什么也没做。 相反,它应该是: n /= 10 这相当于: n = n / 10 First of all, you used = for a comparison test. Instead, I think that you want to use != (not equal): while n != 1: = is only used for assign ...是的,当然。 所以0x8000 = 8 * 16 ^ 3 = 2 ^ 15。 现在,如果再向左移动一次,则得到2 ^ 16。 while循环不断地通过所有值进行掩码: 2 ^ 15 2 ^ 14 2 ^ 13 ...... 因此while循环将mask视为常规整数中2的幂的迭代器。 现在!!(mask & num)做什么? 如果掩码指示的位被on则返回1,如果off则返回0。 表达式!!(mask & num)返回0或1并添加到字符代码0它返回0或1的字符代码。 因此,例如,如果num=12并且mask=4 ...相关文章
更多- Grails 应用的迷惑
- jboss运行程序出错
- multi-core solr deploy process(not complete)
- spring 3.0 和jpa 整合 用jboss
- eclipse里报:An internal error occurred during:
- Windows Phone 获取app在商店中的版本(检查app的版本号)
- 手机app
- App与微信WebAPP
- Twitter Storm Real-Life App 排错记
- The connection to adb is down, and a severe error has occured.
最新问答
更多- 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
- 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
- OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
- 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
- codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
- 在计算机拍照在哪里进入
- 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
- No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
- 单页应用程序:页面重新加载(Single Page Application: page reload)
- 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
- System.StackOverflow错误(System.StackOverflow error)
- KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
- 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
- android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
- TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
- 企业安全培训的各项内容
- 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
- C#类名中允许哪些字符?(What characters are allowed in C# class name?)
- NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
- 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
- 将多个行和可变行移动到列(moving multiple and variable rows to columns)
- 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
- 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
- Angular $资源不会改变方法(Angular $resource doesn't change method)
- 在Angular 5中不是一个函数(is not a function in Angular 5)
- 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
- 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
- 常见的python rpc和cli接口(Common python rpc and cli interface)
- Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
- 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)