Followup to #2242. Now that we have ip_pool_id on the floating IP response, we can show the IP pool name in the column. We need to resolve the ID into the name. We should use the projectIpPoolList endpoint in the loader to setQueryData for projectIpPoolView, then we can just useApiQuery for the cell as normal but it'll be instant. Like this:
|
// fetch instances and preload into RQ cache so fetches by ID in |
|
// InstanceLinkCell can be mostly instant yet gracefully fall back to |
|
// fetching individually if we don't fetch them all here |
|
apiQueryClient |
|
.fetchQuery('instanceList', { query: { project, limit: 200 } }) |
|
.then((instances) => { |
|
for (const instance of instances.items) { |
|
apiQueryClient.setQueryData( |
|
'instanceView', |
|
{ path: { instance: instance.id } }, |
|
instance |
|
) |
|
} |
|
}), |
Followup to #2242. Now that we have
ip_pool_idon the floating IP response, we can show the IP pool name in the column. We need to resolve the ID into the name. We should use theprojectIpPoolListendpoint in the loader tosetQueryDataforprojectIpPoolView, then we can justuseApiQueryfor the cell as normal but it'll be instant. Like this:console/app/pages/project/disks/DisksPage.tsx
Lines 57 to 70 in b603d2d