We are happy to announce the immediate availability of Doctrine MongoDB ODM 1.0.0-BETA13.
What is new in 1.0.0-BETA13?
All issues and pull requests in this release may be found under the 1.0.0-BETA13 milestone on github. Here is the highlight of most important features:
atomicSet and atomicSetArray strategies for top-level collections
two new collection update strategies,
Unlike existing strategies (e.g.
set), which update
collections in a separate query after the parent document, the atomic
strategy ensures that the collection and its parent are updated in the
same query. Any nested collections (within embedded documents) will also
be included in the atomic update, irrespective of their update
Currently, atomic strategies may only be specified for collections mapped directly in a document class (i.e. not collections within embedded documents). This strategy may be especially useful for highly concurrent applications and/or versioned document classes (see: #1094).
Reference priming improvements
#1068 moves the handling of primed references to the Cursor object, which allows ODM to take the skip and limit options into account and avoid priming more references than are necessary.
#970 now allows references within embedded documents to be primed by fixing a previous parsing limitation with dot syntax in field names.
New defaultDiscriminatorValue mapping
defaultDiscriminatorValue mapping, which may be used to specify a
default discriminator value if a document or association has no
New Integer and Bool annotation aliases
Bool annotations, which are aliases of
Add millisecond precision to DateType
#1063 adds millisecond precision to ODM's DateType class (note: although PHP supports microsecond precision, dates in MongoDB are limited to millisecond precision). This should now allow ODM to roundtrip dates from the database without a loss of precision.
New Hydrator generation modes
autoGenerateHydratorClasses ODM configuration option
was a boolean denoting whether to always or never create Hydrator
classes. As of
#953, this option
now supports four modes:
AUTOGENERATE_NEVER = 0(same as
AUTOGENERATE_ALWAYS = 1(same as
AUTOGENERATE_FILE_NOT_EXISTS = 2
AUTOGENERATE_EVAL = 3
Support for custom DocumentRepository factory
#892 allows users
to define a custom repository class via the
configuration option. Alternatively, a custom factory class may also be
configured, which allows users complete control over how repository
classes are instantiated.
Custom repository and factory classes must implement