What's new in CppCMS 1.2.0
- Major Changes in this version
- Minor Changes
- API Improvements
- Templates Compiler
- Configuration Changes
- Performance Improvements
- Internal Modifications
- New Contrib (External) Modules
Note: CppCMS 1.2.0 is future stable version of CppCMS 1.1 beta.
Major Changes in this version
- Redesigned applications pool and its API, now it wouldn't create more synchronous applications than threads available.
- New non-blocking I/O mode
- On-the-fly input content processing support
- Improved url-dispatching for better support of RESTful services
- Improved plugin support
- Independent of context use of cache and session interfaces
- Support of non-cookies based session handling
- Integration of session handling with 3rd part technologies: PHP, Java Servlet, Aps.Net and so on and contributed modules.
- Major performance and memory use improvements.
- New <% filter ... %> block specifying default escape filter.
- Headers and Source separation by templates compiler. Special thanks to Lee Elenbaas for the major contribution.
Minor Changes
- New options to internal file server: disable symbolic links changes and asynchronous operation mode.
API Improvements
CppCMS Library
<a name="Major-API-Changes-in-CppCMS:"></a>Major API Changes in CppCMS:
cppcms::http::response
- Flushing of
std::ostream &out()
now delegates to all underlying filters including gzip compression allowing to flush output in reliable way. - Added non-blocking AIO operation API
- Added API to modify output buffer size
- Flushing of
cppcms::http::request
- Added an option to install custom content filters for asynchronous applications that would validate input on the fly
- Added an option to modify various security limits for filters on per request basis,
cppcms::cache_interface
- added an option to use it outsidecppcms::http::context
scope.cppcms::session_interface
- added an option to use outside of
cppcms::http::context
scope to enable external - added
session_interface_cookie_adapter
class to simulate cookies operation for non-cookies based session handling - added API to retrieve session keys
- added an option to use outside of
Introduced C API for access of CppCMS session for direct library access by other languages/platforms
cppcms::applications_pool
- major API changes- Added an API that allows asynchronous applications to behave as uploaded content filters
- Added
application_specific_pool
to handle generation of applications, mounting and unmounting them - New API for mounting applications with operation mode flags: asynchronous, synchronous, filtering and more.
- Added different pool management strategies
- Older style of application mounting isn't recommented to use any more, it will be deprecated in future versions
cppcms::http::context
- Added an "official" method to "resubmit" context to a different pool or asynchrouns application
- Added a context-specific storage API to attach generic data to the storage (for example for passing it between applications)
New Major CppCMS Classes:
cppcms
session_interface_cookie_adapter
- a bridge to treat any storage as cookiesapplication_specific_pool
- new applications factory
cppcms::http
content_limits
- security limits for input databasic_content_filter
,raw_content_filter
,multipart_content_filter
- filters to handle uploaded content via POST or PUT methods.
- C API Classes:
cppcms_capi_session_pool
,cppcms_capi_session
,cppcms_capi_cookie
;
Minor API Changes in CppCMS:
cppcms::http::content_type
- added queries for multipart/form-data and url-encoded content types.cppcms::http::response
- Addedadd_header()
functioncppcms::http::file
- added API to modify various parameters
- added API to get file size as 64 bit on systems std::streampos is 32 bit
- now
data()
file pointer is independent of writing to file. - added option to specify specific output file rather than a random one.
cppcms::http::cookie
- added API to get expiration timescppcms::widgets::base_widget
- added readonly attributecppcms::url_dispatcher
- extended API to support up to 6 parameters.cppcms::application
- added option to attach unownedcppcms::http::context
cppcms::view::generator
- addedenumerate()
functioncppcms::json
- Added API to load data from
[char const *,char const *)
range - Added
to_json
API to convert strings directly
- Added API to load data from
cppcms::session_pool
- added an option to create one independently ofcppcms::service
for use in plugins.
Booster API Changes
ptime
added operator+=
/-=
- Added
pointer_type
tocallback
- Added support of
ate
forbooster::nowide::fstream
Booster.AIO
- Added
bind
call tobasic_socket
to enable IP binding for both client and server ends. *_buffer
- addedsize()
andbytes_count()
functionsstream_socket
- addedbytes_readable()
functionbasic_io_device
- addedset_non_blocking_if_needed
member functionio_service
- additionalpost()
options
Templates Compiler
- Added option to generate separate API headers and C++ sources for both plugin management and optional compilation time improvements
- Added jsescape filter
- Added
filter
block to modify default filter in its scope.
Configuration Changes
service.async_output_buffer_size
- default size of output buffer for asynchronous/non-blocking operationsservice.input_buffer_size
- default size of input buffer for multipart/form-data or raw content filter processing.service.disable_xpowered_by_version
- disable setting of version of CppCMS library in response headers.session.disable_automatic_load
- disable automatic load of CppCMS session - for non-cookies custom session storage for examplefile_server.check_symlink
- enable/disable symbolic links tracking by file server.file_server.async
- run file-server in asynchronous mode
Performance Improvements
- Improved memory use and reduced memory copying in internal HTTP/FastCGI/SCGI APIs.
- Switched to reactor rather than proactor IO model when possible
- Improved parsing speed of JSON in about 2 times by using
std::streambuf
directly - Non-blocking operation mode option provides major performance improvements for asynchronous applications
- Boost.RB-Shared memory allocator replaced with faster, simpler and well known Buddy memory allocator.
Internal Modifications
- Redesigned internal IO models for performance improvements and non-blocking API support.
- Removed dependency on local version of
cppcms_boost
New Contrib (External) Modules
- Google Recaptcha module
- Server Sent-Events module
- Session Interface Access from Java, PHP, Asp.Net and Python