open-consul/ui/packages/consul-ui/mock-api/v1/discovery-chain/virtual-admin-5
John Cowen 4ddc2b4481
ui: Amends to Routing visualization for partitions (#11747)
* Update disco fixtures now we have partitions

* Add virtual-admin-6 fixture with partition 'redirects' and failovers

* Properly cope with extra partition segment for splitters and resolvers

* Make 'redirects' and failovers look/act consistently

* Fixup some unit tests
2021-12-09 10:47:58 +00:00

157 lines
5 KiB
Plaintext

{
"Chain": {
"ServiceName": "virtual-admin-5",
"Partition": "default",
"Namespace": "default",
"Datacenter": "dc2",
"Protocol": "http",
"StartNode": "router:virtual-admin-5",
"Nodes": {
"resolver:admin.default.default.dc1": {
"Type": "resolver",
"Name": "admin.default.default.dc1",
"Resolver": {
"ConnectTimeout": "5s",
"Default": true,
"Target": "admin.default.default.dc1"
}
},
"resolver:admin.default.default.dc2": {
"Type": "resolver",
"Name": "admin.default.default.dc2",
"Resolver": {
"ConnectTimeout": "5s",
"Default": true,
"Target": "admin.default.default.dc2"
}
},
"resolver:login.default.default.dc2": {
"Type": "resolver",
"Name": "login.default.default.dc2",
"Resolver": {
"ConnectTimeout": "5s",
"Default": true,
"Target": "login.default.default.dc2"
}
},
"resolver:virtual-admin-5.default.default.dc2": {
"Type": "resolver",
"Name": "virtual-admin-5.default.default.dc2",
"Resolver": {
"ConnectTimeout": "5s",
"Default": true,
"Target": "virtual-admin-5.default.default.dc2"
}
},
"router:virtual-admin-5": {
"Type": "router",
"Name": "virtual-admin-5",
"Routes": [
{
"Definition": {
"Match": {
"HTTP": {
"PathPrefix": "/login"
}
},
"Destination": {
"Service": "login",
"PrefixRewrite": "/"
}
},
"NextNode": "resolver:login.default.default.dc2"
},
{
"Definition": {
"Match": {
"HTTP": {
"PathPrefix": "/"
}
},
"Destination": {
"Service": "global-admin"
}
},
"NextNode": "splitter:global-admin.default.default"
},
{
"Definition": {
"Match": {
"HTTP": {
"PathPrefix": "/"
}
},
"Destination": {
"Service": "virtual-admin-5"
}
},
"NextNode": "resolver:virtual-admin-5.default.default.dc2"
}
]
},
"splitter:global-admin.default.default": {
"Type": "splitter",
"Name": "global-admin.default.default",
"Splits": [
{
"Weight": 50,
"NextNode": "resolver:admin.default.default.dc1"
},
{
"Weight": 50,
"NextNode": "resolver:admin.default.default.dc2"
}
]
}
},
"Targets": {
"admin.default.default.dc1": {
"ID": "admin.default.default.dc1",
"Service": "admin",
"Partition": "default",
"Namespace": "default",
"Datacenter": "dc1",
"MeshGateway": {
"Mode": "local"
},
"Subset": {},
"SNI": "admin.default.default.dc1.internal.6818c189-1048-8114-7d9f-ae248864b349.consul",
"Name": "admin.default.default.dc1.internal.6818c189-1048-8114-7d9f-ae248864b349.consul"
},
"admin.default.default.dc2": {
"ID": "admin.default.default.dc2",
"Service": "admin",
"Partition": "default",
"Namespace": "default",
"Datacenter": "dc2",
"MeshGateway": {},
"Subset": {},
"SNI": "admin.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul",
"Name": "admin.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul"
},
"login.default.default.dc2": {
"ID": "login.default.default.dc2",
"Service": "login",
"Partition": "default",
"Namespace": "default",
"Datacenter": "dc2",
"MeshGateway": {},
"Subset": {},
"SNI": "login.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul",
"Name": "login.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul"
},
"virtual-admin-5.default.default.dc2": {
"ID": "virtual-admin-5.default.default.dc2",
"Service": "virtual-admin-5",
"Partition": "default",
"Namespace": "default",
"Datacenter": "dc2",
"MeshGateway": {},
"Subset": {},
"SNI": "virtual-admin-5.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul",
"Name": "virtual-admin-5.default.default.dc2.internal.6818c189-1048-8114-7d9f-ae248864b349.consul"
}
}
}
}