Weblogic 11g URL 重写
我有一个在 Windows Server 计算机上运行 WebLogic 11g 安装的客户端,该客户端希望实现类似 Apache 样式的 mod_rewrite 功能来转换 http 的请求://easyurl.com 至 http://super.complicated .com/with/this/junk?here=and_more。我在互联网上搜索建议,但我所能找到的只是其他人也在问同样的问题,但没有得到任何答案。假设无法安装第 3 方应用程序,我该如何在 WebLogic 中实现这一点?
编辑:现在我想了一下,这个问题可能属于服务器故障。我会把它移到那里。
进一步编辑:https://serverfault.com/questions/177795/url-rewrite-in-weblogic -11g 是服务器故障链接。
I have a client running a WebLogic 11g install on a Windows Server machine who wishes to implement Apache-style mod_rewrite-like functionality to translate requests for http://easyurl.com to http://super.complicated.com/with/this/junk?here=and_more. I have scoured the Internet for advice, but all I can find are other people who are asking the same question and not getting any answer. Assuming that installing 3rd-party apps is not an option, how do I implement this in WebLogic?
Edit: Now that I think about it, this question probably belongs on Server Fault. I'll move it there.
Further edit: https://serverfault.com/questions/177795/url-rewrite-in-weblogic-11g is the Server Fault link.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
如果您将 Apache HTTPD 与 Apache 一起使用HTTP 服务器插件位于 WebLogic 之前,那么应该可以在向 WebLogic 发送请求之前使用
mod_rewrite
。如果没有,那么您可以使用 Tuckey 的 Url Rewrite Filter(Java 过滤器),该过滤器允许在应用程序服务器级别以
mod_rewrite
类似的方式重写 URL。If you are using Apache HTTPD with the Apache HTTP Server Plug-In in front of WebLogic, then it should be possible to use
mod_rewrite
before to send request to WebLogic.If not, then you could use Tuckey's Url Rewrite Filter (a Java Filter) that allows to rewrite URLs in a
mod_rewrite
like manner at the application server level.使用 weblogic 无法开箱即用地执行此操作。侵入性最小的是实现 Pascal 建议的 url 重写过滤器。我有完全相同的要求(仅使用 weblogic 来实现这一点,不需要额外的代码,因为它必须被管理/记录等)并且没有办法做到这一点。
There is no way to do this out of the box with weblogic. The least invasive is to implement Pascal's suggestion of a url rewrite filter. I had the exact same requirement (implement this with just weblogic, no additional code as it would have to be managed/documented, etc) and there was no way to do this.
为此,我会使用 PrettyFaces 或 OCPsoft Rewrite。两者都是针对 URL 重写域的更新解决方案:
http://ocpsoft.com/prettyfaces/
http://ocpsoft.com/rewrite/
I would use either PrettyFaces or OCPsoft Rewrite for this. Both are more updated solutions to the URL-rewriting domain:
http://ocpsoft.com/prettyfaces/
http://ocpsoft.com/rewrite/