pixie icon indicating copy to clipboard operation
pixie copied to clipboard

px.service_id_to_external_ips and px.service_id_to_cluster_ip return empty results in PxL

Open sync-by-unito[bot] opened this issue 3 years ago • 0 comments

See example script, we never see any cluster IP or external IP even though we should

import px

  1. Use this scratch pad to write and run one-off scripts.
  2. If you switch to another script, refresh, or close this browser tab, this script will disappear.
df = px.DataFrame(table='process_stats', start_time='-5m')
df.pod = df.ctx['pod']
df.service_id = df.ctx['service_id']
pods = df.groupby('pod').agg()
pods.pod_ip = px.pod_name_to_pod_ip(pods.pod)
px.display(pods['pod', 'pod_ip'])
df.service = px.service_id_to_service_name(df.service_id)
df.cluster_ip = px.service_id_to_cluster_ip(df.service_id)
df.external_ips = px.service_id_to_external_ips(df.service_id)
df = df[df.cluster_ip != '']
px.display(df[['service', 'cluster_ip', 'external_ips']])
services = df.groupby(['service_id', 'service']).agg()
services.cluster_ip = px.service_id_to_cluster_ip(services.service_id)
services.external_ips = px.service_id_to_external_ips(services.service_id)
px.display(services['service', 'cluster_ip', 'external_ips'])

┆Issue is synchronized with this Jira Bug by Unito

sync-by-unito[bot] avatar Jul 12 '22 05:07 sync-by-unito[bot]