buildr antwrap OutOfMemoryError PermGen 空间
# 我使用 Buildr 作为我的构建工具。我的构建过程的一部分是使用 JAX-WS 从 WSDL 生成 Java 源代码。我有一个 ANT 构建脚本,可以通过 wsimport ant 任务执行此操作。使用 Buildr 中的 AntWrap Ruby 模块我可以做同样的事情。
我的问题是在尝试为许多 WSDL 生成源代码时遇到 OutOfMemoryError PermGen space。我在单独运行 Ant 时遇到了同样的问题,但通过将 ANT_OPTS 环境变量设置为解决了该问题:
set ANT_OPTS=-Xmx512m -XX:PermSize=64m -XX:MaxPermSize=128m
但是当我使用 Buildr 运行构建时,即使设置了此环境变量,我仍然收到错误。我什至尝试在我的构建文件中设置此变量,但这没有帮助。
我的环境如下:
- windows XP
- JRuby 1.6.3
- Buildr 1.4.6
- AntWrap 0.7.0
#
I am using Buildr as my build tool. Part of my build process generates Java source from a WSDL using JAX-WS. I have an ANT build script that does this with the wsimport ant task. Using the AntWrap Ruby module in Buildr I can do the same thing.
My problem is I am getting the OutOfMemoryError PermGen space when trying to generate source for many WSDL's. I got the same problem when running Ant by itself but resolved it by setting the ANT_OPTS environment variable to:
set ANT_OPTS=-Xmx512m -XX:PermSize=64m -XX:MaxPermSize=128m
But when I run my build using Buildr I still get the error even though this environment variable is set. I have even tried setting this variable in my build file but this hasn't helped.
My environment is as follows:
- windows XP
- JRuby 1.6.3
- Buildr 1.4.6
- AntWrap 0.7.0
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您是否尝试在构建文件中设置 JAVA_OPTS ,我不确定 buildr/antwrap 是否选择了 ANT_OPS 环境变量。
Did you try setting JAVA_OPTS in the buildfile, I am not sure if buildr/antwrap picks up the ANT_OPS environment variables.