PHPackages                             mediawiki/doctrine-connection - 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. [Database &amp; ORM](/categories/database)
4. /
5. mediawiki/doctrine-connection

AbandonedArchivedLibrary[Database &amp; ORM](/categories/database)

mediawiki/doctrine-connection
=============================

Tiny library for creating a Doctrine DBAL Connection from a MediaWiki Database object

122PHP

Since Mar 16Pushed 5y ago23 watchersCompare

[ Source](https://github.com/wmde/mediawiki-doctrine-connection)[ Packagist](https://packagist.org/packages/mediawiki/doctrine-connection)[ RSS](/packages/mediawiki-doctrine-connection/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

DISCONTINUED: This library was a proof of concept created in 2019, and has never been used in production code.

MediaWiki Doctrine Connection
=============================

[](#mediawiki-doctrine-connection)

[![Build Status](https://camo.githubusercontent.com/e6c79d6faea8fb4e8568a00378ce96d7e1c229318dbe5efc2ccabbf1ebd2506e/68747470733a2f2f7472617669732d63692e6f72672f776d64652f6d6564696177696b692d646f637472696e652d636f6e6e656374696f6e2e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/wmde/mediawiki-doctrine-connection)[![Latest Stable Version](https://camo.githubusercontent.com/8a26e74f5b76987f2fc75f67f63629d74566190404286ee814761508b626bee0/68747470733a2f2f706f7365722e707567782e6f72672f6d6564696177696b692f646f637472696e652d636f6e6e656374696f6e2f76657273696f6e2e706e67)](https://packagist.org/packages/mediawiki/doctrine-connection)[![Download count](https://camo.githubusercontent.com/fa25c2aeacb7a16fcb297c2df2094ae9f272f3be92a712a2de0f3b60ffe675ee/68747470733a2f2f706f7365722e707567782e6f72672f6d6564696177696b692f646f637472696e652d636f6e6e656374696f6e2f642f746f74616c2e706e67)](https://packagist.org/packages/mediawiki/doctrine-connection)

Tiny library for creating a Doctrine DBAL Connection from a MediaWiki Database object.

Supported databases are:

- Mysqli
- SQLite (PDO)

Usage
-----

[](#usage)

Connections are constructed via the `DoctrineConnectionFactory`:

```
$factory = new DoctrineConnectionFactory();

$doctrineConnection = $factory->connectionFromDatabase( $mwDatabase );
```

Installation
------------

[](#installation)

To use the MediaWiki Doctrine Connection library in your project, simply add a dependency on mediawiki/doctrine-connection to your project's `composer.json` file. Here is a minimal example of a `composer.json`file that just defines a dependency on MediaWiki Doctrine Connection 1.x:

```
{
    "require": {
        "mediawiki/doctrine-connection": "~1.0"
    }
}
```

Development
-----------

[](#development)

Start by installing the project dependencies by executing

```
composer update

```

You can run the style checks by executing

```
make cs

```

Since the library depends on MediaWiki, you need to have a working MediaWiki installation to run the tests. You need these two steps to run the tests:

- Load `vendor/autoload.php` of this library in your MediaWiki's `LocalSettings.php` file
- Execute `maintenance/phpunit.php -c /path/to/this/lib/phpunit.xml.dist`

For an example see the TravisCI setup (`.travis.yml` and `.travis.install.sh`)

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity30

Early-stage or recently created project

 Bus Factor1

Top contributor holds 95.5% of commits — single point of failure

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/451bd4039d530fed8f9c3da91bfa519233a397d2182cdfdcad700f6cfea19b7f?d=identicon)[Jeroen De Dauw](/maintainers/Jeroen%20De%20Dauw)

![](https://www.gravatar.com/avatar/054adb441e7ee248ec924bc45fa793835c284710eb31627587fa5de21bab9e96?d=identicon)[wmde](/maintainers/wmde)

---

Top Contributors

[![JeroenDeDauw](https://avatars.githubusercontent.com/u/146040?v=4)](https://github.com/JeroenDeDauw "JeroenDeDauw (21 commits)")[![manicki](https://avatars.githubusercontent.com/u/3524114?v=4)](https://github.com/manicki "manicki (1 commits)")

### Embed Badge

![Health badge](/badges/mediawiki-doctrine-connection/health.svg)

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

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k115.1M102](/packages/jdorn-sql-formatter)[illuminate/database

The Illuminate Database package.

2.8k52.4M9.4k](/packages/illuminate-database)[mongodb/mongodb

MongoDB driver library

1.6k64.0M546](/packages/mongodb-mongodb)[ramsey/uuid-doctrine

Use ramsey/uuid as a Doctrine field type.

90340.3M211](/packages/ramsey-uuid-doctrine)[reliese/laravel

Reliese Components for Laravel Framework code generation.

1.7k3.4M16](/packages/reliese-laravel)

PHPackages © 2026

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