C++ REST SDK 2.0.0

Rating:        Based on 3 ratings
Reviewed:  1 review
Downloads: 0
Released: Mar 20, 2014
Updated: Mar 24, 2014 by stevetgates
Dev status: Stable Help Icon

Available Downloads

There are no downloads associated with this release.

Release Notes

Starting with 2.0.0 we are only distributing Windows binaries through our NuGet package. This allows us to be more efficient and not maintain an MSI. We also feel it gives users a better experience not having to mess with include paths, libs, and dlls.

Here is a summary of the changes for this release, please note for the first time we made a couple of breaking API changes in our JSON library. We take breaking changes very seriously and believe these are valuable improvements that allow us to continue to expand and improve the API moving forward.

Misc

  • General bug fixes – including many reported on CodePlex
  • Removed MSIs – now only distributing Windows binaries through NuGet
  • Added Visual Studio debugger natvis file to NuGet package
  • Added support for cmake for non-Windows platforms

WebSockets

  • Added initial Beta implementation for WebSockets on Windows store, other platforms will come in future releases

Platform Support

  • Added support for OS X
  • Added support for iOS

Http Client

  • Added support for request cancellation through cancellation_tokens for Windows platforms, others will be added in the future

Json

  • Added 64 bit integer support. There is a new class json::number that can be retrieved with the json::value::as_number() API. It contains methods for testing and getting a number as int32, uint32, int64, and uint64.
  • Changed the underlying storage for arrays and added a new class json::array for operations specific to arrays. Can be obtained from the json::value::as_array() API.
  • Changed the underlying storage for objects and added a new class json::object for operations specific to objects. Can be obtained from the json::value::as_object() API.
  • Breaking Change - Changed how iteration over json arrays and objects is performed. No longer is an iterator of std::pair<json::value, json::value> returned. Instead there is a separate iterator for arrays and objects on the json::array and json::object class respectively. This allows us to make performance improvements and continue to adjust accordingly. The array iterator returns json::values, and the object iterator now returns std::pair<string_t, json::value>.
  • 25% to 30% improvement for parsing and traversing the object model
  • Breaking Change - Const overload of index operator[] on json::value – in prior releases the behavior of the const/non-const overloads where different. This is inconsistent and confusing. The operator[] now can always end up modifying the underlying internal storage so is never const. If you want true const semantics, the json::value::at(…) API can be used.
  • Deprecated a couple of inconsistent/confusing or bad performance APIs, all have functional replacements
    • json::value::tostring() – this API really performance serialization and is easy to confuse with json::value::asstring(). The replacement is json::value::serialize().
    • json::value::get(…) – this API had bad performance since it returned a json::value with value semantics. It also can be confusing to use if you think you are modifying the underlying internal data. Instead use operator[] or json::value::at(…).

Uris

  • Performance improvement avoiding std::isalnum’s global lock
  • Moved URI functionality from web::http namespace to just under web. For backwards compatibility using statements have been inserted for customers directly using from http_client.h.

Http Listener

  • Breaking Change - Removed pipeline staging feature. It was fundamentally broken and didn’t work at all for processing responses.
  • Fixed issues with the close semantics of shutting down a listener.

Streams

  • Deprecated ‘blittable’ versions of stream read/write. This API is dangerous and only works for trivial types on single byte character streams. It also has bad performance. The functionality can easily be accomplished with the other read/write overloads or getn/putn directly on the stream buffer.

VS solution files and samples

  • Cleaned up our solution files and build instructions for all the platforms a bit
  • Made sure project files exist for both Visual Studio 2012 and 2013, when appropriate

Reviews for this release

     
very much.
by zhouchuanxiang on Mar 28 at 5:54 AM