PHPackages                             doctrine/phpcr-odm - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. doctrine/phpcr-odm

ActiveLibrary

doctrine/phpcr-odm
==================

PHP Doctrine Content Repository Object Document Mapper (ODM) provides transparent persistence for PHP objects.

3.0.0(1mo ago)1811.5M—9.5%101[32 issues](https://github.com/doctrine/phpcr-odm/issues)[11 PRs](https://github.com/doctrine/phpcr-odm/pulls)20MITPHPPHP ^8.1CI passing

Since Jun 7Pushed 1mo ago11 watchersCompare

[ Source](https://github.com/doctrine/phpcr-odm)[ Packagist](https://packagist.org/packages/doctrine/phpcr-odm)[ Docs](https://www.doctrine-project.org/projects/phpcr-odm.html)[ Fund](https://www.doctrine-project.org/sponsorship.html)[ Patreon](https://www.patreon.com/phpdoctrine)[ RSS](/packages/doctrine-phpcr-odm/feed)WikiDiscussions 3.0.x Synced 1mo ago

READMEChangelog (10)Dependencies (30)Versions (82)Used By (20)

PHPCR ODM for Doctrine
======================

[](#phpcr-odm-for-doctrine)

[![Build Status](https://github.com/doctrine/phpcr-odm/actions/workflows/test-application.yaml/badge.svg?branch=2.x)](https://github.com/doctrine/phpcr-odm/actions/workflows/test-application.yaml)[![Latest Stable Version](https://camo.githubusercontent.com/af74f030af6ab084cfe78e380cc102ad8925536284f5c9e9dd1e94e989c9987f/68747470733a2f2f706f7365722e707567782e6f72672f646f637472696e652f70687063722d6f646d2f76657273696f6e2e706e67)](https://packagist.org/packages/doctrine/phpcr-odm)[![Total Downloads](https://camo.githubusercontent.com/2b6d7ca7bff84c4399393240c2f2d38bcc6f6ede9bdef48b6735f2181766e2a8/68747470733a2f2f706f7365722e707567782e6f72672f646f637472696e652f70687063722d6f646d2f642f746f74616c2e706e67)](https://packagist.org/packages/doctrine/phpcr-odm)

Requirements
------------

[](#requirements)

- libxml version &gt;= 2.7.0 (due to a bug in libxml )
- [composer](http://getcomposer.org/)
- See also the `require` section of [composer.json](composer.json)

Documentation
-------------

[](#documentation)

Please refer to [doctrine-project.org](http://docs.doctrine-project.org/projects/doctrine-phpcr-odm/en/latest/) for the documentation.

Contributing
------------

[](#contributing)

Pull requests are welcome. Please include tests to prevent regressions whenever possible.

Thanks to [everyone who has contributed](https://github.com/doctrine/phpcr-odm/contributors) already.

Running the tests
-----------------

[](#running-the-tests)

There are separate test setups for the `doctrine-dbal` and the `jackrabbit` PHPCR implementations. Before installing the composer dependencies, you will need to prepare the database for storage and choose a `phpcr/phpcr-implementation`. Doing so will change the `composer.json` file - please make sure you do not check in this change into version control.

### Setting up to test with Jackrabbit

[](#setting-up-to-test-with-jackrabbit)

1. Make sure you have `java` and `wget` installed, then run this script to install and start jackrabbit: ```
        tests/script_jackrabbit.sh

    ```
2. Require the PHPCR implementation: ```
         composer require jackalope/jackalope-jackrabbit --no-update

    ```
3. Now you can install all dependencies with: ```
        composer install

    ```
4. Now you can run the tests: ```
    vendor/bin/phpunit -c tests/phpunit_jackrabbit.xml.dist

    ```

    You can also copy the phpunit dist file to `./phpunit.xml` to have it selected by default, or if you need to customize any configuration options.

### Setting up to test with Doctrine-DBAL

[](#setting-up-to-test-with-doctrine-dbal)

1. For `doctrine-dbal`, make sure that MySQL is installed. If the connection parameters in `cli-config.doctrine_dbal.php.dist` are not correct, manually create `cli-config.php` and adjust the options as needed. Then run the script to initialize the repository in the database: ```
        tests/script_doctrine_dbal.sh

    ```
2. Require the PHPCR implementation ```
        composer require jackalope/jackalope-doctrine-dbal --no-update

    ```
3. Now you can install all dependencies with: ```
        composer install

    ```
4. Now you can run the tests: ```
    vendor/bin/phpunit -c tests/phpunit_doctrine_dbal.xml.dist

    ```

    You can also copy the phpunit dist file to `./phpunit.xml` to have it selected by default, or if you need to customize any configuration options.

###  Health Score

72

—

ExcellentBetter than 100% of packages

Maintenance85

Actively maintained with recent releases

Popularity58

Moderate usage in the ecosystem

Community49

Growing community involvement

Maturity87

Battle-tested with a long release history

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~60 days

Recently: every ~28 days

Total

78

Last Release

55d ago

Major Versions

1.7.1 → 2.0.0-beta12023-05-21

1.8.0 → 2.0.0-beta22024-01-15

2.1.0 → 3.x-dev2025-12-03

2.1.x-dev → 3.0.x-dev2026-03-24

PHP version history (9 changes)1.0.0-beta1PHP &gt;=5.3.3

1.3.0-rc3PHP &gt;=5.3.9

1.3.0PHP ^5.3.9|~7.0

1.4.3PHP ^5.3.9 || ^7.0

1.5.0PHP ^7.1

1.5.3PHP ^7.1 || ^8.0

2.0.0-beta1PHP ^7.4 || ^8.0

1.8.0PHP ^8.0

2.0.0-beta2PHP ^8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/76576?v=4)[David Buchmann](/maintainers/dbu)[@dbu](https://github.com/dbu)

![](https://avatars.githubusercontent.com/u/328359?v=4)[Luis Cordova](/maintainers/cordoval)[@cordoval](https://github.com/cordoval)

![](https://avatars.githubusercontent.com/u/20873?v=4)[Luke Smith](/maintainers/lsmith)[@lsmith](https://github.com/lsmith)

---

Top Contributors

[![dbu](https://avatars.githubusercontent.com/u/76576?v=4)](https://github.com/dbu "dbu (886 commits)")[![lsmith77](https://avatars.githubusercontent.com/u/300279?v=4)](https://github.com/lsmith77 "lsmith77 (817 commits)")[![dantleech](https://avatars.githubusercontent.com/u/530801?v=4)](https://github.com/dantleech "dantleech (159 commits)")[![uwej711](https://avatars.githubusercontent.com/u/648874?v=4)](https://github.com/uwej711 "uwej711 (94 commits)")[![Seldaek](https://avatars.githubusercontent.com/u/183678?v=4)](https://github.com/Seldaek "Seldaek (70 commits)")[![Ocramius](https://avatars.githubusercontent.com/u/154256?v=4)](https://github.com/Ocramius "Ocramius (61 commits)")[![bergie](https://avatars.githubusercontent.com/u/3346?v=4)](https://github.com/bergie "bergie (47 commits)")[![ElectricMaxxx](https://avatars.githubusercontent.com/u/2905834?v=4)](https://github.com/ElectricMaxxx "ElectricMaxxx (31 commits)")[![piotras](https://avatars.githubusercontent.com/u/232506?v=4)](https://github.com/piotras "piotras (27 commits)")[![nicam](https://avatars.githubusercontent.com/u/182071?v=4)](https://github.com/nicam "nicam (18 commits)")[![flojon](https://avatars.githubusercontent.com/u/52005?v=4)](https://github.com/flojon "flojon (16 commits)")[![rndstr](https://avatars.githubusercontent.com/u/32963?v=4)](https://github.com/rndstr "rndstr (14 commits)")[![simensen](https://avatars.githubusercontent.com/u/191200?v=4)](https://github.com/simensen "simensen (13 commits)")[![chregu](https://avatars.githubusercontent.com/u/47106?v=4)](https://github.com/chregu "chregu (13 commits)")[![greg0ire](https://avatars.githubusercontent.com/u/657779?v=4)](https://github.com/greg0ire "greg0ire (11 commits)")[![starkj](https://avatars.githubusercontent.com/u/655445?v=4)](https://github.com/starkj "starkj (11 commits)")[![wouterj](https://avatars.githubusercontent.com/u/749025?v=4)](https://github.com/wouterj "wouterj (11 commits)")[![sarcher](https://avatars.githubusercontent.com/u/157295?v=4)](https://github.com/sarcher "sarcher (10 commits)")[![asiragusa](https://avatars.githubusercontent.com/u/3077760?v=4)](https://github.com/asiragusa "asiragusa (9 commits)")[![jwage](https://avatars.githubusercontent.com/u/97422?v=4)](https://github.com/jwage "jwage (8 commits)")

---

Tags

phpdataobjectcontentmappingmapperodm

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/doctrine-phpcr-odm/health.svg)

```
[![Health](https://phpackages.com/badges/doctrine-phpcr-odm/health.svg)](https://phpackages.com/packages/doctrine-phpcr-odm)
```

###  Alternatives

[doctrine/mongodb-odm

PHP Doctrine MongoDB Object Document Mapper (ODM) provides transparent persistence for PHP objects to MongoDB.

1.1k23.3M302](/packages/doctrine-mongodb-odm)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[doctrine/persistence

The Doctrine Persistence project is a set of shared interfaces and functionality that the different Doctrine object mappers share.

4.1k286.5M762](/packages/doctrine-persistence)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[contao/core-bundle

Contao Open Source CMS

1231.6M2.4k](/packages/contao-core-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
