12.4. 通过路由公开数据网格
使用 OpenShift Route 和 passthrough 加密使 Data Grid 集群在网络上可用。
流程
-
在
InfinispanCR 中包含spec.expose。 -
使用
spec.expose.type字段将Route指定为服务类型。 (可选)添加带有
spec.expose.host字段的主机名。spec: expose: type: Route host: www.example.orgspec: expose: type: Route host: www.example.orgCopy to Clipboard Copied! Toggle word wrap Toggle overflow - 应用更改。
验证路由是否可用。
oc get routes
oc get routesCopy to Clipboard Copied! Toggle word wrap Toggle overflow
路由 端口
创建路由时,它会在网络上公开一个端口,该端口接受客户端连接,并将流量重定向到侦听端口 11222 的 Data Grid 服务。
可用的 路由 端口取决于您是否使用加密。
| 端口 | 描述 |
|---|---|
|
| 禁用加密。 |
|
| 启用加密。 |