Vscode-extension-for-zowe: Allow for optional elements in host field when creating a new connection

Created on 2 Mar 2020  路  12Comments  路  Source: zowe/vscode-extension-for-zowe

The host field requires the user to type the value in strict syntax.

  • https is required. I can't type http. I can't leave it out. But, in the CLI, the user doesn't type this value at all. It isn't stored with the underlying profile. I think it should be optional.
  • the port value is required. This value is not required when creating a CLI profile. The CLI has a default value of 443. I think it should be optional and the default value entered.

image

image

UX

All 12 comments

z/OSMF does not allow http that why we forbid typing http and restricted it to https. And the current behaviour is that you don't have to put the port in the URL. it will default to 443.

This is working as expected.

@jellypuno I think John's point is that we know that the protocol is https so why have the user enter this information?

@jelaplan what do you think of this proposal?
hostname:port
Enter a z/OSMF URL in the format 'hostname:port'

Do you think we need to mention the default port is 443 in the description?
hostname:port
Enter a z/OSMF URL in the format 'hostname:port' (Default port is 443)

Note that in the current description url should be hostname

@MikeBauerCA Well, when we are creating this before, the argument that we received about the URL is to include the https:// because the user will just copy and paste it from APIML Catalog or the z/OSMF URL. We initially wanted just the host and port and it was mentioned that the user needs to select the host and port specifically instead of just select all + copy + paste

We should handle both cases. If https is provided, that is fine. If not, we know what it is so we should be able to accommodate just as a web browser does.

But for the specific use case you mentioned, I believe the z/OSMF URL has a path as well (/zosmf) so it would be select all + copy + paste + delete path.

ok. so to summarize, the request is this:

URL should allow the following values:

Does this mean we will still actively prevent http:// ?
It's fine either way. just want to confirm

@zFernand0 yes, I believe so.

Jelly, your summary is good. I would add one more. If they type http then substitute https. The intent of this story is to provide a more forgiving interface so if people type an error situation that we can easily detect and correct then we should. We can't detect all errors so se la vie.

ok. so to summarize, the request is this:

URL should allow the following values:

* https://hostname:port

* hostname:port

* hostname _(port default to 443)_

* https://hostname _(port default to 443)_

If they type http then substitute https.

I don't know if it would be misleading to the user if we substitute http for https. I know we aren't using the protocol (at least in the zosmf case), but what about the port? What if someone has zosmf configured on port 80?

Please disregard this comment if id doesn't make sense (or if we don't think people will have such configuration)

This should be implemented now (v1.5.2).

This should be implemented now (v1.5.2).

@jellypuno @crawr, ok to close then?

@zFernand0 yep. 馃槃

Was this page helpful?
0 / 5 - 0 ratings