Allow non-admin BDC connections to see BDC features (#12663) (#12737)

* Add handling for non-admin BDC users

* Bump STS

* Fix HDFS root node commands

* remove nested awaits

* colon
This commit is contained in:
Charles Gagnon
2020-10-05 15:55:23 -07:00
committed by GitHub
parent 93156ccf04
commit 72d48bda61
16 changed files with 229 additions and 150 deletions

View File

@@ -305,6 +305,8 @@ export class JupyterSession implements nb.ISession {
connectionProfile.options[USER] = await controller.getKnoxUsername(connectionProfile.userName);
} catch (err) {
console.log(`Unexpected error getting Knox username for Spark kernel: ${err}`);
// Optimistically use the SQL login name - that's going to normally be the case after CU5
connectionProfile.options[USER] = connectionProfile.userName;
}
}
}

View File

@@ -27,6 +27,12 @@ export class TestClusterController implements bdc.IClusterController {
getKnoxUsername(clusterUsername: string): Promise<string> {
return Promise.resolve('knoxUsername');
}
getEndPoints(promptConnect?: boolean): Promise<bdc.IEndPointsResponse> {
return Promise.resolve( {
response: undefined,
endPoints: []
});
}
}
describe('Jupyter Session Manager', function (): void {