[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-09-16 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
* `master`
* 399b2a656f71ce9c82b65beebdeae368b38f3301 - sss_cache: invalidate also 
autofs entries
* e016ada3b593a64f1787096f826bf656aa999d02 - sysdb: invalidate also autofs 
entries
* 09781a3374f09962c984a96908b27454bbc47581 - autofs: always refresh 
auto.master
* e050872d11071a167a99b5fddd97fd140709ecd2 - autofs: allow to run only 
setent without enumeration in test tool
* f3aaaca4b4596ecc98e870788273f33f82a7 - ldap: implement autofs get 
entry
* 66e1eda6d384a823681ade3eb1a962bad848f892 - ldap: implement autofs get map
* f3f223202f526ce2b3129faa2ea77a3e1ddeda9d - ldap: rename 
sdap_autofs_get_map to sdap_autofs_enumerate
* d096eeb181fc19e94ee3ab56782da725fdaab4b3 - ldap: add base_dn to 
sdap_search_bases
* 2a0b74a56997d6c7703bc6f272e3e7957cf4eb47 - dp: replace autofs handler 
with enumerate method
* 0e7298639a692872eaad18fe2af3feb5483df37f - dp: add additional autofs 
methods
* 0d56c1aa4f4f2f2153412cb6141137441fd0ac13 - dp: add dp_no_output type to 
be used in dp_set_method
* ad8b4c16de01a6e5267c6ee3499a1dd4cacade96 - dp: add dp_error_to_ret
* 29b1ffd01f58bf6c67e4b3e27fc2014b8d0a9d21 - autofs: use cache_req to 
obtain map in setent
* e5165199c4067f4ad88f38d29dd3a2a94d88db4a - autofs: use cache_req to 
obtain single entry in getentrybyname
* 7726093e778e2706ee81d8516130ec5c6c4b3767 - autofs: convert code to 
cache_req
* 85c86687b9f991ea9ebc9b5e70ae47a735fd3240 - cache_req: add autofs entry by 
name plugin
* 1fc3e4a14eaec7bdaec5901f8bb213a718fc7bc1 - cache_req: add autofs map by 
name plugin
* 8b2ab48871758acbd5ab5675b3965a776d0c5457 - cache_req: add autofs map 
entries plugin
* 4efe83c27acfe663e83899fe38cf69258c298221 - sysdb: add 
sysdb_del_autofsentry_by_key
* e9fc00999bb7a536df0fff9a954237eb1f9b6589 - sysdb: store original dn in 
autofs map
* d01ddb06d15f336d403430021822c1385a4bc819 - sysdb: store enumeration 
expiration time in autofs map
* fb83d820575e2f3c32cd891a84a793071d1c2e60 - sysdb: add 
enumerationExpireTimestamp
* eadfba5c6967f022af2c7898bcf70043be74e0e1 - sysdb: add 
sysdb_get_autofsentry
* 5097684dc146c84379f1fbd6821b01e4621a848c - sysdb: add expiration time to 
autofs entries
* 0d477763dc60a818f3ea269ac047320ec7dcd9b0 - autofs: fix typo in test tool
* 65de0d36cdd328cbbea6b748c0e0495cf192b17c - sss_ptr_hash: keep value 
pointer when destroying spy

"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-531686691
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-09-10 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
Dowstream tests pass now. I squashed this diff to `autofs: always refresh 
auto.master` so the expiration time is set to 1 only when master map is 
requested not when `clear cache` signal comes from `sss_cache` tool.

```diff
From d849398f6d630ce72f20c7b40a147c68cf0d79f9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pavel=20B=C5=99ezina?= 
Date: Tue, 10 Sep 2019 11:02:27 +0200
Subject: [PATCH] b

---
 src/responder/autofs/autofssrv_cmd.c | 28 ++--
 1 file changed, 14 insertions(+), 14 deletions(-)

diff --git a/src/responder/autofs/autofssrv_cmd.c 
b/src/responder/autofs/autofssrv_cmd.c
index 
77c1c0921acea2c68c292be179a8d5aba988d0e6..6d51e75acf53a70acaad50bf54095e54d5a145f4
 100644
--- a/src/responder/autofs/autofssrv_cmd.c
+++ b/src/responder/autofs/autofssrv_cmd.c
@@ -135,23 +135,9 @@ autofs_fill_entry(struct ldb_message *entry, struct 
sss_packet *packet, size_t *
 void
 autofs_orphan_maps(struct autofs_ctx *autofs_ctx)
 {
-struct sss_domain_info *dom;
-errno_t ret;
-
 /* It will automatically decrease the refcount of enum_ctx through
  * delete callback. */
 sss_ptr_hash_delete_all(autofs_ctx->maps, false);
-
-DEBUG(SSSDBG_TRACE_FUNC, "Invalidating autofs maps\n");
-for (dom = autofs_ctx->rctx->domains;
- dom != NULL;
- dom = get_next_domain(dom, SSS_GND_DESCEND)) {
-ret = sysdb_invalidate_autofs_maps(dom);
-if (ret != EOK) {
-DEBUG(SSSDBG_MINOR_FAILURE, "Unable to invalidate maps in "
-  "%s [%d]: %s\n", dom->name, ret, sss_strerror(ret));
-}
-}
 }
 
 static void
@@ -222,6 +208,9 @@ static void
 autofs_orphan_master_map(struct autofs_ctx *autofs_ctx,
  const char *mapname)
 {
+struct sss_domain_info *dom;
+errno_t ret;
+
 if (strcmp(mapname, "auto.master") != 0) {
 return;
 }
@@ -230,6 +219,17 @@ autofs_orphan_master_map(struct autofs_ctx *autofs_ctx,
 
 /* Remove and invalidate all maps. */
 autofs_orphan_maps(autofs_ctx);
+
+DEBUG(SSSDBG_TRACE_FUNC, "Invalidating autofs maps\n");
+for (dom = autofs_ctx->rctx->domains;
+ dom != NULL;
+ dom = get_next_domain(dom, SSS_GND_DESCEND)) {
+ret = sysdb_invalidate_autofs_maps(dom);
+if (ret != EOK) {
+DEBUG(SSSDBG_MINOR_FAILURE, "Unable to invalidate maps in "
+  "%s [%d]: %s\n", dom->name, ret, sss_strerror(ret));
+}
+}
 }
 
 struct autofs_setent_state {
-- 
2.20.1
```
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-529916366
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-09-02 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
Added two more patches:
* sss_ptr_hash: keep value pointer when destroying spy 
* autofs: always refresh auto.master

The last one can be merged to cache_req conversion, but I'm including it as a 
separate patch to simplify the review.

It should fix issues found by downstream tests, I'm waiting for new test 
results.

I also fixed issue created during fixing review issues which made autofs to not 
refresh rules:
```diff
if (ret != EAGAIN) {
tevent_req_error(req, ret);
+tevent_req_post(req, params->ev);
}
-tevent_req_post(req, params->ev);
```
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-527126270
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-08-28 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
I opened https://github.com/SSSD/sssd/pull/875 for 1.16 backport. It took few 
hours to finish but main changes were only in setting up sbus methods. 
Otherwise, the patches are intact.
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-525700857
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-08-28 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
Fixed Tomas' comments.
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-525693877
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-08-22 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
There would be some conflict in cache_req conversion and then in data provider 
where we now use sbus2. But in general, I think it is possible. Given the 
amount of change required, I think we can leave it as 2.* feature only.
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-523837002
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-08-22 Thread jhrozek
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

jhrozek commented:
"""
@pbrezina do you think this patchset is backportable to sssd-1-16 at all?
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-523820577
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org


[SSSD] [sssd PR#866][comment] autofs: do not enumerate when only single entry is requested

2019-08-15 Thread pbrezina
  URL: https://github.com/SSSD/sssd/pull/866
Title: #866: autofs: do not enumerate when only single entry is requested

pbrezina commented:
"""
There are lots of commits but I tried to keep them as small as possible so 
really each commit implements only one change, so the review process should be 
easier.
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/866#issuecomment-521629437
___
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/sssd-devel@lists.fedorahosted.org