Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid using regex in ACL if possible. #1506

Closed
389-ds-bot opened this issue Sep 12, 2020 · 12 comments
Closed

Avoid using regex in ACL if possible. #1506

389-ds-bot opened this issue Sep 12, 2020 · 12 comments
Labels
closed: fixed Migration flag - Issue
Milestone

Comments

@389-ds-bot
Copy link

Cloned from Pagure issue: https://pagure.io/389-ds-base/issue/48175


Too expensive for the acl operation?

$ egrep _re_ acl/*.[ch]
acl/acl.c:	re = slapi_re_comp( pat, &re_result );
acl/acl.c:	/* slapi_re_exec() returns 1 if the string p1 matches the last compiled
acl/acl.c:	rc = slapi_re_exec( re, realval, -1 /* no timelimit */ );
acl/acl.c:	slapi_re_free(re);
@389-ds-bot 389-ds-bot added the closed: fixed Migration flag - Issue label Sep 12, 2020
@389-ds-bot 389-ds-bot added this to the 1.2.11.33 milestone Sep 12, 2020
@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-05-12 14:01:01

attachment
perf-top-ns-slapd.png

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-05-12 14:02:22

in a test scenario provided by qa the high cpu usage by the regex code could be confirmed [perf output attached]

@389-ds-bot
Copy link
Author

@389-ds-bot
Copy link
Author

Comment from nhosoi (@nhosoi) at 2015-05-12 21:48:06

You patch looks good!

Could you share the top result from the build which your patch is applied to? Thanks!

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-05-12 21:58:45

attachment
Screenshot from 2015-05-11 10:41:52.png

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-05-12 21:59:51

screenshot of perf top with fix attached

@389-ds-bot
Copy link
Author

Comment from nhosoi (@nhosoi) at 2015-05-12 22:45:18

Replying to [comment:5 elkris]:

screenshot of perf top with fix attached

Thank you, Ludwig!! What a beautiful result!!

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-06-18 14:06:10

master:
commit 25c3b83

1.2.11:
commit 6024a77

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2015-06-18 14:11:19

1.3.3

commit 064df7b

@389-ds-bot
Copy link
Author

Comment from nhosoi (@nhosoi) at 2015-06-26 23:42:14

Ticket has been cloned to Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1236156

@389-ds-bot
Copy link
Author

Comment from nhosoi (@nhosoi) at 2015-06-26 23:44:32

Note: 389-ds-base-1.3.4 was branched after this patch was pushed.

Closing this ticket as FIXED.

@389-ds-bot
Copy link
Author

Comment from lkrispen (@elkris) at 2017-02-11 23:04:21

Metadata Update from @elkris:

  • Issue assigned to elkris
  • Issue set to the milestone: 1.2.11.33

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed: fixed Migration flag - Issue
Projects
None yet
Development

No branches or pull requests

1 participant