PHPackages                             fpfgithub/cmq - 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. fpfgithub/cmq

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

fpfgithub/cmq
=============

腾讯云CMQ

v1.1(4y ago)02.9k↓76.9%1PHPPHP &gt;=5.6.0CI failing

Since May 27Pushed 4y ago1 watchersCompare

[ Source](https://github.com/fpfgithub/cmq)[ Packagist](https://packagist.org/packages/fpfgithub/cmq)[ RSS](/packages/fpfgithub-cmq/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependencies (2)Versions (3)Used By (0)

cmq
===

[](#cmq)

腾讯云CMQ

使用
--

[](#使用)

```
require 'vendor/autoload.php';

define('APP_ENV', 'test');//根据不同的环境 区分同名队列
$isenv = true; //是否需要拼接环境后缀APP_ENV,默认true
$secretId = ""; //"云 API 密钥 SecretId";
$secretKey = ""; //"云 API 密钥 SecretKey";
$endPoint = 'https://cmq-queue-gz.api.qcloud.com';//endPoint
$cmq =  new  Qcloud\Cmq($secretId, $secretKey, $endPoint, $isenv);

$queueName = 'test-queue';

//入队列
for ($i=0; $i < 10; $i++) {
	$f = $cmq->set($queueName, $i);
	echo $f.PHP_EOL;
}

//读队列
do {
	$msg = $cmq->get($queueName);
	if ($msg) {
		$body = $msg->msgBody;
		$cmq->ack($queueName, $msg->receiptHandle);//应答 从队列中删除消息
		echo $body.PHP_EOL;
	}
} while ($msg);

//count
$count = $cmq->count($queueName);
echo 'count=>'.$count.PHP_EOL;

//删除队列
$cmq->set_queue_name($queueName.APP_ENV);
$cmq->delete_queue($queueName.APP_ENV);

```

###  Health Score

25

—

LowBetter than 36% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 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 ~0 days

Total

2

Last Release

1488d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/11733551?v=4)[fpfgithub](/maintainers/fpfgithub)[@fpfgithub](https://github.com/fpfgithub)

---

Top Contributors

[![fpfgithub](https://avatars.githubusercontent.com/u/11733551?v=4)](https://github.com/fpfgithub "fpfgithub (6 commits)")

---

Tags

cmq

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/fpfgithub-cmq/health.svg)

```
[![Health](https://phpackages.com/badges/fpfgithub-cmq/health.svg)](https://phpackages.com/packages/fpfgithub-cmq)
```

PHPackages © 2026

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