PHPackages                             mattdanger/phalcon-semaphore - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. mattdanger/phalcon-semaphore

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

mattdanger/phalcon-semaphore
============================

Simple semaphore component for Phalcon v1.4.x

v1.1.0(10y ago)0518MITPHPPHP &gt;=5.4.0

Since Apr 21Pushed 10y ago2 watchersCompare

[ Source](https://github.com/mattdanger/phalcon-semaphore)[ Packagist](https://packagist.org/packages/mattdanger/phalcon-semaphore)[ Docs](https://github.com/mattdanger/phalcon-semaphore)[ RSS](/packages/mattdanger-phalcon-semaphore/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (4)Used By (0)

phalcon-semaphore
=================

[](#phalcon-semaphore)

Simple semaphore component for Phalcon PHP

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

[](#requirements)

- Phalcon v1.4.x

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

[](#installation)

Install using Composer:

```
{
	"require": {
		"mattdanger/phalcon-semaphore": "1.*"
	}
}
```

Create a database table `semaphore` with this schema:

```
CREATE TABLE `semaphore` (
  `name` varchar(255) NOT NULL DEFAULT '',
  `value` varchar(255) DEFAULT NULL,
  `timestamp` datetime DEFAULT NULL,
  PRIMARY KEY (`name`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
```

Then add the service:

```
$di->set('semaphore', '\PhalconSemaphore\Semaphore');
```

If you want to use a different database table name you can initialize the service like this:

```
$di->set('semaphore', function() use ($config){
  return new \PhalconSemaphore\Semaphore('my_table_name');
}, true);
```

Usage
-----

[](#usage)

```
$this->semaphore->run(string $class, $string method, int $expiration_hours, array $args);

// Example without method parameters
$this->semaphore->run('MyNamespace\Models\Stat', 'calculate', 1);

// Example with method parameters
$this->semaphore->run('MyNamespace\Models\Stat', 'calculate', 1, array($arg1, $arg2, ...));
```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% 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.

###  Release Activity

Cadence

Every ~41 days

Total

2

Last Release

3659d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/609890?v=4)[Matt West](/maintainers/mattdanger)[@mattdanger](https://github.com/mattdanger)

---

Top Contributors

[![mattdanger](https://avatars.githubusercontent.com/u/609890?v=4)](https://github.com/mattdanger "mattdanger (5 commits)")

---

Tags

phalcon

### Embed Badge

![Health badge](/badges/mattdanger-phalcon-semaphore/health.svg)

```
[![Health](https://phpackages.com/badges/mattdanger-phalcon-semaphore/health.svg)](https://phpackages.com/packages/mattdanger-phalcon-semaphore)
```

###  Alternatives

[phalcon/zephir

Zephir is a compiled high level language aimed to the creation of C-extensions for PHP

3.4k435.9k19](/packages/phalcon-zephir)[phalcon/ide-stubs

The most complete Phalcon Framework IDE stubs library which enables autocompletion in modern IDEs.

1693.2M128](/packages/phalcon-ide-stubs)[phalcongelist/php-diff

A comprehensive library for generating differences between two hashable objects (strings or arrays).

12435.6k2](/packages/phalcongelist-php-diff)[izica/phalcon-meta-tags

Phalcon PHP Meta tags service

1216.2k](/packages/izica-phalcon-meta-tags)[sergeyklay/breadcrumbs

Powerful and flexible component for building site breadcrumbs in Phalcon 2+.

391.1k1](/packages/sergeyklay-breadcrumbs)[stanislav-web/phalcon-sms-factory

Multiple gateway SMS Sender factory. Provide any SMS services inside your Phalcon's projects

321.6k](/packages/stanislav-web-phalcon-sms-factory)

PHPackages © 2026

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