String applicationName = connProps.getProperty(TeiidURL.CONNECTION.APP_NAME);
// user may be null if using trustedToken to log on
String user = connProps.getProperty(TeiidURL.CONNECTION.USER_NAME, CoreConstants.DEFAULT_ANON_USERNAME);
// password may be null if using trustedToken to log on
String password = connProps.getProperty(TeiidURL.CONNECTION.PASSWORD);
Credentials credential = null;
if (password != null) {
credential = new Credentials(password.toCharArray());
}
boolean adminConnection = Boolean.parseBoolean(connProps.getProperty(TeiidURL.CONNECTION.ADMIN));
try {
SessionMetadata sessionInfo = service.createSession(user,credential, applicationName, connProps, adminConnection, true);