Lazy Tables, a major performance boost
web2py models are executed before controllers, so all tables are defined at every request. Not all tables are needed to handle each request, so it is possible that some of the time spent defining tables is wasted. Conditional models (conditional models, chapter 4) can help, but web2py offers a big performance boost via lazy_tables. This feature means that table creation is deferred until the table is actually referenced. Enabling lazy tables requires setting the DAL(...,lazy_tables=True) parameter. This is one of the most significant response-time performance boosts in web2py.