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

Support logging in to multiple APIML instances per config file #2264

Closed
Tracked by #2252 ...
t1m0thyj opened this issue Apr 28, 2023 · 4 comments · Fixed by #3019
Closed
Tracked by #2252 ...

Support logging in to multiple APIML instances per config file #2264

t1m0thyj opened this issue Apr 28, 2023 · 4 comments · Fixed by #3019
Labels
enhancement New feature or request priority-low Legit issue but cosmetic or nice-to-have

Comments

@t1m0thyj
Copy link
Member

t1m0thyj commented Apr 28, 2023

Currently we only support logging in to the APIML for base profiles, and there can only be one active base profile per team config file.
If nested profiles like the example below are defined, users may want to log in to multiple APIML instances per team config file.
Either Zowe Explorer should also support this scenario, or we should document it as a known limitation.

{
    "$schema": "./zowe.schema.json",
    "profiles": {
        "lpar1": {
            "profiles": {
                "zosmf": {
                    "type": "zosmf",
                    "properties": {
                        "basePath": "/ibmzosmf/api/v1"
                    }
                }
            },
            "properties": {
                "host": "example1.com",
                "port": 7554,
                "rejectUnauthorized": true,
                "tokenType": "apimlAuthenticationToken"
            },
            "secure": [
                "tokenValue"
            ]
        },
        "lpar2": {
            "profiles": {
                "zosmf": {
                    "type": "zosmf",
                    "properties": {
                        "basePath": "/ibmzosmf/api/v1"
                    }
                }
            },
            "properties": {
                "host": "example2.com",
                "port": 7554,
                "rejectUnauthorized": true,
                "tokenType": "apimlAuthenticationToken"
            },
            "secure": [
                "tokenValue"
            ]
        }
    },
    "defaults": {
        "zosmf": "lpar1.zosmf"
    },
    "autoStore": true
}
@t1m0thyj t1m0thyj added enhancement New feature or request priority-low Legit issue but cosmetic or nice-to-have labels Apr 28, 2023
@github-actions
Copy link

Thank you for raising this issue.
The community has 90 days to upvote 👍 the issue.
If it receives 10 upvotes, we will move it to our backlog. If not, we will close it.

@t1m0thyj
Copy link
Member Author

Related to zowe/zowe-cli#1705

@adam-wolfe
Copy link
Contributor

Should this be added to the V3 GA milestone? I'm just wondering if the changes to how Zowe Explorer handles nested APIML profiles would be considered to be a breaking change that we would need to get in before V3 is released.

@t1m0thyj t1m0thyj added this to the v3.0.0 GA milestone Jul 18, 2024
@t1m0thyj
Copy link
Member Author

t1m0thyj commented Jul 18, 2024

I've added it to the milestone. Based on offline discussion, I think we determined this should be implemented in V3 to avoid the risk of potential breaking changes.

Here is the planned flow for logging in to API ML for a z/OSMF profile:

graph TD;
    baseExists{{Does base profile exist?}};
    nestedExists1{{Is zosmf profile nested?}};
    nestedExists2{{Is zosmf profile nested?}};
    baseTokenized{{Does base profile have\ntokenValue in secure array?}};
    storeBase[Store token in BASE profile];
    storeParent[Store token in PARENT profile];
    cantStore[Cancel operation:\nno profile to store token];

    baseExists--Yes-->baseTokenized;
    baseExists--No -->nestedExists1;
    baseTokenized--Yes-->storeBase;
    baseTokenized--No -->nestedExists2;
    nestedExists2--Yes-->storeParent;
    nestedExists2--No -->storeBase;
    nestedExists1--Yes-->storeParent;
    nestedExists1--No -->cantStore;
Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request priority-low Legit issue but cosmetic or nice-to-have
Projects
Status: Closed
Development

Successfully merging a pull request may close this issue.

3 participants