Drop org_hierarchy_depth in user queries (#1322)

Update MCE schema
This commit is contained in:
Mars Lan 2018-08-14 08:56:01 -07:00 committed by GitHub
parent d4ce45a90c
commit 8270b89422
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 4 deletions

View File

@ -4,6 +4,15 @@
"namespace": "com.linkedin.events.metadata",
"doc": "Compliance metadata suggested by algorithms.",
"fields": [
{
"name": "modelId",
"type": [
"null",
"string"
],
"default": null,
"doc": "The ID of the model used to generate the suggestion."
},
{
"name": "suggestedFieldClassifications",
"type": {
@ -71,4 +80,4 @@
"doc": "A map of suggested dataset-level compliance metadata, where the key is the field name of DatasetClassification, and the value is the corresponding suggestion for that field."
}
]
}
}

View File

@ -48,14 +48,13 @@ public class UserDAO extends AbstractMySQLOpenSourceDAO
"authentication_type FROM users WHERE username = ? and authentication_type = 'default'";
private final static String GET_ALL_COMPANY_USERS = "SELECT DISTINCT user_id as id, display_name as name " +
"FROM dir_external_user_info WHERE is_active = 'Y' and org_hierarchy_depth > 0 ";
"FROM dir_external_user_info WHERE is_active = 'Y'";
private final static String GET_ALL_GROUPS = "SELECT DISTINCT group_id as name FROM dir_external_group_user_map " +
"WHERE group_id is not null and group_id != ''";
private final static String GET_ALL_COMPANY_USERS_AND_GROUPS = "SELECT DISTINCT user_id as id, " +
"display_name as name, 'person' as category FROM dir_external_user_info " +
"WHERE is_active = 'Y' and org_hierarchy_depth > 1 " +
"display_name as name, 'person' as category FROM dir_external_user_info WHERE is_active = 'Y' " +
"UNION SELECT DISTINCT group_id as id, NULL as name, 'group' as category " +
"FROM dir_external_group_user_map WHERE group_id > ''";