定制 rosalana/tracker 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rosalana/tracker

Composer 安装命令:

composer require rosalana/tracker

包简介

Rosalana tracker is a package that helps trace and log application activities in Rosalana ecosystem.

README 文档

README

This package is a part of the Rosalana eco-system. It provides tracing and logging functionalities for applications built within the Rosalana ecosystem.

Note: This package is a extension of the Rosalana Core package.

Table of Contents

Installation

To install the rosalana/traker package, you must first have the rosalana/core package installed. If you haven't installed it yet, please refer to the rosalana/core documentation.

After installing the rosalana/core package, use the rosalana:add command from the Rosalana CLI and select rosalana/tracker from the list:

php artisan rosalana:add

After installing the package, you should publish its assets using the following command:

php artisan rosalana:publish

You can specify which files to publish. Publishing the configuration files is required to set up the package properly. Other files are optional and can be published as needed. However, it is recommended to publish all files to take full advantage of the package features.

Configuration

After publishing the package, you will find a rosalana.php configuration file in the config directory of your Laravel application. You can customize these options according to your needs.

This file will grow over time as you add more Rosalana packages to your application. Each package contributes its own configuration section. The rosalana.php file serves as the central configuration hub for all Rosalana packages.

rosalana/tracker package provides configuration options for:

  • tracker: Settings related to tracing functionalities, such as enabling/disabling tracing, setting log behavior, and etc.

Features

Route Tracking

The tracker package automatically tracks incoming HTTP requests and logs relevant information, including request method, URL, headers, and response status. This helps in monitoring application performance and identifying potential bottlenecks.

Tracking is separated by route groups, allowing you to see how different sections of your application are performing.

Exception Logging

The tracker package captures and logs exceptions that occur within the application. It records details such as exception type, message, stack trace, and context information. This aids in debugging and identifying issues in the application.

Exceptions can be send to external monitoring immediately if you provide the exception class names in the configuration. Other exceptions are stored in the database and sent in batches periodically.

Service Tracking

The tracker package integrates with various services within the Rosalana ecosystem, such as Outpost and Basecamp. It tracks interactions with these services, logging request and response data, headers, and status codes. This allows you to monitor the communication between your application and external services.

Events

The tracker package dispatches Laravel events at key points in the tracking lifecycle. You can listen to these events to extend tracker behavior or react to tracking activity.

Core Events (from rosalana/core)

The tracker listens to the following core events to automatically capture service interactions:

Event Trigger
Rosalana\Core\Events\OutpostMessageSent An Outpost message was sent
Rosalana\Core\Events\OutpostMessageReceived An Outpost message was received
Rosalana\Core\Events\BasecampRequestSent A Basecamp HTTP request completed

Tracker Events (from rosalana/tracker)

The tracker dispatches its own events that you can listen to:

Event Trigger Payload
Rosalana\Tracker\Events\ReportCollected A report was stored to the local database (deferred) $event->report
Rosalana\Tracker\Events\ReportDispatchedImmediately A report was sent immediately to Basecamp $event->report
Rosalana\Tracker\Events\ReportChunkDispatched A chunk of reports was sent to Basecamp $event->reports
Rosalana\Tracker\Events\ReportsFlushed Sent reports were cleaned up from the database $event->reports

Example usage:

use Rosalana\Tracker\Events\ReportCollected;

Event::listen(function (ReportCollected $event) {
    // React to a new report being stored
    $report = $event->report;
});

License

Rosalana Accounts is open-source under the MIT license, allowing you to freely use, modify, and distribute it with minimal restrictions.

You may not be able to use our systems but you can use our code to build your own.

For details on how to contribute or how the Rosalana ecosystem is maintained, please refer to each repository’s individual guidelines.

Questions or feedback?

Feel free to open an issue or contribute with a pull request. Happy coding with Rosalana!

rosalana/tracker 适用场景与选型建议

rosalana/tracker 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 17 次下载、GitHub Stars 达 0, 最近一次更新时间为 2026 年 03 月 22 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「package」 「laravel」 「tracker」 「rosalana」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 rosalana/tracker 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 rosalana/tracker 我们能提供哪些服务?
定制开发 / 二次开发

基于 rosalana/tracker 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 17
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 28
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-22