diff options
author | randomdan <randomdan@localhost> | 2012-02-15 17:26:51 +0000 |
---|---|---|
committer | randomdan <randomdan@localhost> | 2012-02-15 17:26:51 +0000 |
commit | 9dd4bad251cc0155540284bf85969a1796620572 (patch) | |
tree | 045f9edc8ccc074eba549192ba1cd6adb9fff843 /project2/cgi | |
parent | Pull the script location back into the core and add support for caching of pa... (diff) | |
download | project2-9dd4bad251cc0155540284bf85969a1796620572.tar.bz2 project2-9dd4bad251cc0155540284bf85969a1796620572.tar.xz project2-9dd4bad251cc0155540284bf85969a1796620572.zip |
Improved script component caching, performance tweaks and related fixes for persistent objects
Diffstat (limited to 'project2/cgi')
-rw-r--r-- | project2/cgi/cgiAppEngine.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/project2/cgi/cgiAppEngine.cpp b/project2/cgi/cgiAppEngine.cpp index 07aa737..d062d87 100644 --- a/project2/cgi/cgiAppEngine.cpp +++ b/project2/cgi/cgiAppEngine.cpp @@ -7,6 +7,7 @@ #include <boost/bind.hpp> #include <boost/foreach.hpp> #include "ostreamWrapper.h" +#include "scopeObject.h" #include <boost/date_time/microsec_time_clock.hpp> const std::string SESSIONID = "sessionID"; @@ -136,6 +137,7 @@ CgiApplicationEngine::process() const } if (TransformSourcePtr ts = currentStage.get<2>()) { TransformSourcePtr final = finalTransformSource(ts); + ScopeObject emptyFinal(boost::bind(&TransformSource::clearTargets, final)); final->addTarget(new CgiResult(header, IO, rs && rs->root ? rs->root->value("encoding", _env->outputEncoding) : VariableType(_env->outputEncoding)), NULL); BOOST_FOREACH(const PresenterCachePtr & p, rs->caches) { @@ -149,6 +151,9 @@ CgiApplicationEngine::process() const } } ts->doTransforms(); + BOOST_FOREACH(const PresenterCachePtr & p, rs->caches) { + p->flushCache(); + } if (ddd) { delete ddd; } |