# HG changeset patch # User Nicolas Chauvat # Date 1248818156 -7200 # Node ID df456fa1b053dd9202930de805861be2c40c3ed5 # Parent f8246ed962f64c2b618983140cdd68b8ef5f845a [doc] more improvements diff -r f8246ed962f6 -r df456fa1b053 doc/book/en/development/entityclasses/load-sort.rst --- a/doc/book/en/development/entityclasses/load-sort.rst Tue Jul 28 23:49:47 2009 +0200 +++ b/doc/book/en/development/entityclasses/load-sort.rst Tue Jul 28 23:55:56 2009 +0200 @@ -1,3 +1,5 @@ + +.. _FetchAttrs: Loaded attributes and default sorting management ```````````````````````````````````````````````` diff -r f8246ed962f6 -r df456fa1b053 doc/book/en/development/profiling/index.rst --- a/doc/book/en/development/profiling/index.rst Tue Jul 28 23:49:47 2009 +0200 +++ b/doc/book/en/development/profiling/index.rst Tue Jul 28 23:55:56 2009 +0200 @@ -23,7 +23,9 @@ CubicWeb also provides the **exlog** command to examine and summarize data found in such a file: -:: + +.. sourcecode:: sh + $ cubicweb-ctl exlog < ~/myapp-rql.log 0.07 50 Any A WHERE X eid %(x)s, X firstname A {} 0.05 50 Any A WHERE X eid %(x)s, X lastname A {} @@ -35,9 +37,9 @@ This command sorts and uniquifies queries so that it's easy to see where is the hot spot that needs optimization. -Having said all this, it would probably be worth talking about the **fetch_attrs** attribute -you can define in your entity classes because it can greatly reduce the -number of queries executed. XXX say more about it XXX +Do not neglect to set the **fetch_attrs** attribute you can define in your +entity classes because it can greatly reduce the number of queries executed (see +:ref:`FetchAttrs`). You should also know about the **profile** option in the ``all-in-on.conf``. If set, this option will make your application run in an `hotshot`_ session and