Changeset 248


Ignore:
Timestamp:
Nov 27, 2007, 2:11:03 AM (11 years ago)
Author:
quentin
Message:

Make the profiling depend on an environment variable "SIPB_XEN_PROFILE" being set, else don't profile.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/web/main.py

    r247 r248  
    641641        operation = 'list'
    642642
    643     main(operation, u, fields)
    644     #import profile
    645     #profile.run('main(operation, u, fields)', 'log-'+operation)
    646 
     643    if os.getenv("SIPB_XEN_PROFILE"):
     644        import profile
     645        profile.run('main(operation, u, fields)', 'log-'+operation)
     646    else:
     647        main(operation, u, fields)
Note: See TracChangeset for help on using the changeset viewer.