Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Cloud plugin to handle new URLs #93436

Closed
Tracked by #94207
ryankeairns opened this issue Mar 3, 2021 · 9 comments · Fixed by #95569
Closed
Tracked by #94207

Update Cloud plugin to handle new URLs #93436

ryankeairns opened this issue Mar 3, 2021 · 9 comments · Fixed by #95569
Labels
Team:Platform-Design Team Label for Kibana Design Team. Support the Analyze group of plugins.

Comments

@ryankeairns
Copy link
Contributor

Background
There is an existing capability of the cloud plugin that adds links to the user menu and left nav. These links do not appear as they were awaiting for URLs to be provided on the Cloud side. That time has come (see this Cloud PR) and, with that change and the passing of time, the final URLs have changed.

Needed changes

  • Update the references/variable names to match the new links
  • Add logic to concatenate the baseURL + path (the current setup assumes full URLs to be passed)

Related work

  • This PR changes the label names to align with the Cloud labels and link order. While not technically a blocker, we might save some conflicts if we wait for this to be merged.

cc:/ @alexfrancoeur

@ryankeairns ryankeairns added the Team:Platform-Design Team Label for Kibana Design Team. Support the Analyze group of plugins. label Mar 3, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-design (Team:Kibana-Design)

@ryankeairns
Copy link
Contributor Author

I've labeled this with Kibana Design. I'll give it a go and reach out to Kibana Security (?) if I get stuck.

@alexfrancoeur
Copy link

alexfrancoeur commented Mar 4, 2021

As this is general Cloud / Kibana interaction as well, I don't think it could hurt to keep @joshdover and @thesmallestduck in the loop. Also @arisonl for awareness as this touches the user profile

@yspotts
Copy link

yspotts commented Mar 22, 2021

@ryankeairns
Copy link
Contributor Author

ryankeairns commented Mar 23, 2021

I've asked Yoel a question here on whether xpack.cloud.id will continue to be passed - https://github.com/elastic/cloud/pull/77420#issuecomment-804941730

If it will no longer be passed, then it's going to require more involvement from other teams to convert existing usage and ought to be handled by engineers (as opposed to me). cc:/ @alexfrancoeur

Currently, Kibana expects:

# xpack.cloud.id: 'eastus2.azure.elastic-cloud.com:9243$59ef636c6917463db140321484d63cfa$59ef636c6917463db14032148cfa'
# xpack.cloud.resetPasswordUrl: 'https://cloud.elastic.co/user/settings' # Cloud profile link
# xpack.cloud.accountUrl: 'https://cloud.elastic.co/account/activity' # Account link
# xpack.cloud.deploymentUrl: 'https://cloud.elastic.co/deployments/resolve/cluster/eastus2/9243$59ef636c6917463db14032148cfa/'

The new Cloud implementation is designed to send:

xpack.cloud.profile_url: "/user/settings/"
xpack.cloud.organization_url: "/account/"
xpack.cloud.cname: "192.168.44.10.ip.es.io"
xpack.cloud.base_url: "https://adminconsole.192.168.44.10.ip.es.io:12443"
xpack.cloud.deployment_url: "/deployments/bfdad4ef99a24212387593686d63"

Things map as follows:
resetPasswordUrl becomes profile_url
accountUrl becomes organization_url
deploymentUrl becomes base_url + deployment_url

The outliers:
id used in many places in Kibana but is no longer provided by Cloud (?)
cname is provided by Cloud but unused in Kibana (?)

@ryankeairns
Copy link
Contributor Author

ryankeairns commented Mar 23, 2021

Good news :)

@ryankeairns we are not removing any fields here, cloudid will be available until The End Of Time :)

@yuliacech
Copy link
Contributor

Hey @ryankeairns, I was just wondering what the target for this work is? I'd like to use xpack.cloud.base_url to link to Deployments overview page from Remote clusters (#94450).

@ryankeairns
Copy link
Contributor Author

Hey @ryankeairns, I was just wondering what the target for this work is? I'd like to use xpack.cloud.base_url to link to Deployments overview page from Remote clusters (#94450).

Hey Yulia, 7.13, generally speaking. I have a draft PR started that I'll need some assistance on to get merged, but it's in the works.

@yuliacech
Copy link
Contributor

Thanks a lot for doing this, Ryan @ryankeairns! I'll follow the issue for updates, really looking forward to those additions to Cloud plugin. Let me know if I can help with the PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Platform-Design Team Label for Kibana Design Team. Support the Analyze group of plugins.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants