akasurde / freeipa

Forked from freeipa 7 years ago
Clone

332dbab Speed up client schema cache

1 file Authored by cheimes 7 years ago, Committed by mbasti 7 years ago,
    Speed up client schema cache
    
    It's inefficient to open a zip file over and over again. By loading all
    members of the schema cache file at once, the ipa CLI script starts
    about 25 to 30% faster for simple cases like help and ping.
    
    Before:
    
    $ time for i in {1..20}; do ./ipa ping >/dev/null; done
    
    real    0m13.608s
    user    0m10.316s
    sys     0m1.121s
    
    After:
    
    $ time for i in {1..20}; do ./ipa ping >/dev/null; done
    
    real    0m9.330s
    user    0m7.635s
    sys     0m1.146s
    
    https://fedorahosted.org/freeipa/ticket/6690
    
    Signed-off-by: Christian Heimes <cheimes@redhat.com>
    Reviewed-By: David Kupka <dkupka@redhat.com>