You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@ambari.apache.org by Oliver Szabo <os...@hortonworks.com> on 2016/03/23 12:45:36 UTC
Review Request 45208: Cleanup LDAP sync process
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing
-------
Testing is in progress...
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Sebastian Toader <st...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review125231
-----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 508)
<https://reviews.apache.org/r/45208/#comment188019>
Why not use regexp here? Regexp may just provide the functionallity and flexibilty needed here out of the box.
- Sebastian Toader
On March 23, 2016, 2:28 p.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 23, 2016, 2:28 p.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing done.
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 1:02:31.664s
> [INFO] Finished at: Wed Mar 23 13:45:38 CET 2016
> [INFO] Final Memory: 38M/607M
> [INFO] ------------------------------------------------------------------------
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Robert Levas <rl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review126120
-----------------------------------------------------------
Ship it!
Ship It!
- Robert Levas
On March 30, 2016, 11:25 a.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 30, 2016, 11:25 a.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
> - check that user/group DN (which is processed) is out of the scope or not based on the base DN
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress.
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 30, 2016, 3:25 p.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
- added null check
- update tests
- fixed typo
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
- check that user/group DN (which is processed) is out of the scope or not based on the base DN
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing (updated)
-------
Testing is in progress.
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
> On March 30, 2016, 2:05 p.m., Robert Levas wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java, line 62
> > <https://reviews.apache.org/r/45208/diff/6/?file=1318881#file1318881line62>
> >
> > `full` is never `null`?
No, during creation of DistinguishedName its handled, when the object/string in DistinguishedName is empty or null (with StringUtils.isBlank), because of that it will be enough to check: adapter has a DN attribute or not. (it's safe because we use a cast on that)
> On March 30, 2016, 2:05 p.m., Robert Levas wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java, line 60
> > <https://reviews.apache.org/r/45208/diff/6/?file=1318881#file1318881line60>
> >
> > There seems to be a lot of room for NPEs to be thrown. DO we know null's aren't returned from the various calls?
see comment below
- Oliver
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review126103
-----------------------------------------------------------
On March 30, 2016, 3:25 p.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 30, 2016, 3:25 p.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
> - check that user/group DN (which is processed) is out of the scope or not based on the base DN
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress.
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Robert Levas <rl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review126103
-----------------------------------------------------------
Fix it, then Ship it!
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java (line 60)
<https://reviews.apache.org/r/45208/#comment189007>
There seems to be a lot of room for NPEs to be thrown. DO we know null's aren't returned from the various calls?
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java (line 62)
<https://reviews.apache.org/r/45208/#comment189008>
`full` is never `null`?
- Robert Levas
On March 30, 2016, 5:28 a.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 30, 2016, 5:28 a.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
> - check that user/group DN (which is processed) is out of the scope or not based on the base DN
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing done. (Everything is green on apache jenkins)
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Sebastian Toader <st...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review126068
-----------------------------------------------------------
Ship it!
Ship It!
- Sebastian Toader
On March 30, 2016, 11:28 a.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 30, 2016, 11:28 a.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
> - check that user/group DN (which is processed) is out of the scope or not based on the base DN
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing done. (Everything is green on apache jenkins)
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 30, 2016, 9:28 a.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
fixed issues
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
- check that user/group DN (which is processed) is out of the scope or not based on the base DN
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing (updated)
-------
Testing done. (Everything is green on apache jenkins)
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Sebastian Toader <st...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review126041
-----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 746)
<https://reviews.apache.org/r/45208/#comment188948>
I think it should be logged somewhere that this group will be ignored.
Use 'out of scope of' instead 'out of scope from'
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 780)
<https://reviews.apache.org/r/45208/#comment188949>
I think it should be logged somewhere that this user will be ignored.
Use 'out of scope of' instead 'out of scope from'
- Sebastian Toader
On March 29, 2016, 6:06 p.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 29, 2016, 6:06 p.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
> - check that user/group DN (which is processed) is out of the scope or not based on the base DN
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 29, 2016, 4:06 p.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
- check base DN scope for ldap user/group sync
- added/updated tests
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description (updated)
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
- check that user/group DN (which is processed) is out of the scope or not based on the base DN
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/AmbariLdapUtils.java ffebd45
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/AmbariLdapUtilsTest.java b2778ae
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing
-------
Testing is in progress
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 29, 2016, 10:03 a.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
- fixed issues
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing
-------
Testing is in progress
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Sebastian Toader <st...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review125834
-----------------------------------------------------------
ambari-server/conf/unix/log4j.properties (line 79)
<https://reviews.apache.org/r/45208/#comment188706>
Why is this needed? The root logger already runs with INFO level.
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 93)
<https://reviews.apache.org/r/45208/#comment188707>
Document what us this regexp used for.
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 519)
<https://reviews.apache.org/r/45208/#comment188711>
Can we just make the regexp to be case insensitive instead of using StringUtils.lowerCase?
- Sebastian Toader
On March 28, 2016, 10:23 p.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 28, 2016, 10:23 p.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
>
>
> Diffs
> -----
>
> ambari-server/conf/unix/log4j.properties ab3ea0b
> ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 28, 2016, 8:23 p.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
- added additional TRACE logging
- added regexp
- added unit tests
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
Diffs (updated)
-----
ambari-server/conf/unix/log4j.properties ab3ea0b
ambari-server/src/main/java/org/apache/ambari/server/security/authorization/Users.java c2bc22f
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing (updated)
-------
Testing is in progress
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Oliver Szabo <os...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/
-----------------------------------------------------------
(Updated March 23, 2016, 1:28 p.m.)
Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
Changes
-------
fixed issues & testing done (new changes tested manually with AmbariLdapDataPopulatorTest class)
Bugs: AMBARI-15383
https://issues.apache.org/jira/browse/AMBARI-15383
Repository: ambari
Description
-------
Cleanup LDAP sync process:
- speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
- fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
Diffs (updated)
-----
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
Diff: https://reviews.apache.org/r/45208/diff/
Testing (updated)
-------
Testing done.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:02:31.664s
[INFO] Finished at: Wed Mar 23 13:45:38 CET 2016
[INFO] Final Memory: 38M/607M
[INFO] ------------------------------------------------------------------------
Thanks,
Oliver Szabo
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Robert Levas <rl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review125019
-----------------------------------------------------------
Fix it, then Ship it!
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 347)
<https://reviews.apache.org/r/45208/#comment187769>
Could `allMode` be renamed to something more self explanitory. Maybe `recursive` and then reverse the logic as needed.
ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java (line 361)
<https://reviews.apache.org/r/45208/#comment187770>
You might want to reverse the clauses here since the boolean check is faster than the `contains` check and mail fail first.
- Robert Levas
On March 23, 2016, 7:45 a.m., Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated March 23, 2016, 7:45 a.m.)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress...
>
>
> Thanks,
>
> Oliver Szabo
>
>
Re: Review Request 45208: Cleanup LDAP sync process
Posted by Daniel Gergely <dg...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/45208/#review125008
-----------------------------------------------------------
Ship it!
Ship It!
- Daniel Gergely
On márc. 23, 2016, 11:45 de, Oliver Szabo wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45208/
> -----------------------------------------------------------
>
> (Updated márc. 23, 2016, 11:45 de)
>
>
> Review request for Ambari, Daniel Gergely, Robert Levas, and Sebastian Toader.
>
>
> Bugs: AMBARI-15383
> https://issues.apache.org/jira/browse/AMBARI-15383
>
>
> Repository: ambari
>
>
> Description
> -------
>
> Cleanup LDAP sync process:
> - speedup sync with "--all" (do not check nested groups recursively...ambari gather all of the groups first, and it's enough to just process them sequentially)
> - fixing issue: uppercase member attributes (in ambari.properties) don't work well with the queries
>
>
> Diffs
> -----
>
> ambari-server/src/main/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulator.java 75df9cc
> ambari-server/src/test/java/org/apache/ambari/server/security/ldap/AmbariLdapDataPopulatorTest.java ffff3ea
>
> Diff: https://reviews.apache.org/r/45208/diff/
>
>
> Testing
> -------
>
> Testing is in progress...
>
>
> Thanks,
>
> Oliver Szabo
>
>