Skip to content

Unexpected behaviour when retrieving username/password from zowe config with autoStore: true #1777

Closed Answered by juleskreutzer
juleskreutzer asked this question in Q&A
Discussion options

You must be logged in to vote

To get back on this, we now explicitly store the user and password properties in the zosmf profile and this works as expected. I analyzed the log of a colleague this morning and see that when the token is expired, the user and password are retrieved from the zosmf profile and used to create a new session/login to APIML.

For clarity, the doLogin method has been extended with the following code:

// Load z/OSMF profile
const zosmfProfile = this.profileInfo.getDefaultProfile('zosmf');
if (zosmfProfile === undefined || zosmfProfile === null) {
   throw new ProfileLoadingError(`Retrieved z/OSMF profile is undefined`, MessageLocation.CORE);
}

// Store username
await this.profileInfo.updateProperty

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@juleskreutzer
Comment options

@juleskreutzer
Comment options

Answer selected by juleskreutzer
@zFernand0
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants