如何使用OSGI HttpService支持虚拟主机 [英] How to support virtual hosts with OSGI HttpService

查看:84
本文介绍了如何使用OSGI HttpService支持虚拟主机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用osgi HttpService 的所有示例都展示了如何注册servlet,资源等 - 但是所有这些都在同一个服务实例上,并且在同一个命名空间中。

All examples of using an osgi HttpService show how to register servlets, resources, etc -- but all on the same service instance, and in the same namespace.

如何在osgi(最好是嵌入式)中运行 HttpService 的多个实例,每个实例都有自己的命名空间,基于收到的特定IP地址或主机名的HTTP请求?

How can I run multiple instances of the HttpService in osgi (preferably embedded), each with its own namespace, based on HTTP requests received for a specific IP address or hostname?

推荐答案

有一个 Google Code上的项目,声称允许启动多个 HTTP服务

There is a project on Google Code that purports to allow starting multiple HTTP Service.

我没有使用它,但它可能至少解决了部分查询。

I've not used it but it might solve at least part of your query.

这篇关于如何使用OSGI HttpService支持虚拟主机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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