From 33d77a9d4adb974a61af80ec19db1c9ebf692683 Mon Sep 17 00:00:00 2001 From: Jeremy Mikola Date: Mon, 30 Oct 2017 21:15:03 +0000 Subject: [PATCH] Unsupported BSON types are ignored again, but log warnings https://jira.mongodb.org/browse/PHPC-1026 git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343352 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/mongodb/functions/bson/tophp.xml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/reference/mongodb/functions/bson/tophp.xml b/reference/mongodb/functions/bson/tophp.xml index f600175012..7398d6a309 100644 --- a/reference/mongodb/functions/bson/tophp.xml +++ b/reference/mongodb/functions/bson/tophp.xml @@ -19,6 +19,14 @@ The typeMap paramater may be used to control the PHP types used for converting BSON arrays and documents (both root and embedded). + + + Fields containing deprecated BSON types (i.e. undefined, symbol, DBPointer) + are ignored when converting BSON to PHP. This can result in a loss of data + when round-tripping BSON documents through PHP, as any fields containing a + deprecated type will be silently dropped. + + @@ -75,6 +83,18 @@ + + 1.3.2 + + + MongoDB\Driver\Exception\UnexpectedValueException + is no longer thrown if the input contains an unsupported, deprecated + BSON type. Such types will be ignored (as they were in versions before + 1.3.0), although the driver will now log a warning to the debug log + (see: mongodb.debug). + + + 1.3.0