Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Log Laravel Package

draw/log

Lightweight Laravel logging helper package providing a simple API to write structured log entries and streamline application debugging. Integrates with Laravel’s logger, supports common log levels, and keeps logging consistent across your services.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Structured Logging for Compliance: Justify investment in structured logging (e.g., JSON format) to meet GDPR, HIPAA, or internal audit requirements, reducing manual log parsing and improving traceability.
  • Developer Experience (DX) Improvements: Align with roadmap items like "Reduce Debugging Time" by enabling contextual, enriched logs (e.g., user IDs, request metadata) without custom boilerplate.
  • Build vs. Buy for Monolog Extensions: Replace ad-hoc logging middleware or custom handlers with a standardized, maintainable solution, reducing technical debt and improving code reuse.
  • Event-Driven Architecture: Integrate logging with business events (e.g., user actions, payment failures) using Symfony’s EventDispatcher, enabling features like real-time alerts or A/B testing analytics.
  • Microservices Standardization: Standardize logging across a polyglot microservices architecture by leveraging PSR-3 compliance and draw/dependency-injection for consistent configuration.
  • Security Observability: Enhance security monitoring by logging sensitive operations (e.g., authentication attempts, role changes) with structured metadata for SIEM integration.

When to Consider This Package

  • Adopt if:

    • Your team uses Monolog and needs custom handlers, formatters, or event-driven logging without heavy dependencies (e.g., no Elasticsearch/Sentry).
    • You’re building a modular Laravel app and want to decouple logging logic from business code using Symfony events.
    • You need structured logging (JSON) with minimal overhead and are already using the draw/ ecosystem (e.g., draw/dependency-injection).
    • Your roadmap includes compliance-heavy features (e.g., audit trails, PII masking) that require enriched log context.
    • You’re on Laravel 10+ (PHP 8.5+) and can tolerate Symfony 6.4+ dependencies.
  • Avoid if:

    • Your logging needs are simple (e.g., basic file/console logs) or already met by Laravel’s built-in logger or Monolog’s default handlers.
    • You’re constrained by older PHP versions (e.g., Laravel 9.x on PHP 8.1) or Symfony <6.4.
    • You require enterprise-grade features (e.g., log aggregation, retention policies, or SIEM integration) and need a battle-tested solution.
    • Your team lacks experience with Symfony components or the draw/ ecosystem, as this package introduces non-standard dependencies.
    • You prioritize low-risk adoption and prefer packages with active maintenance (e.g., >100 stars, recent commits).

How to Pitch It (Stakeholders)

For Executives

*"This package helps us reduce debugging time and compliance risk by standardizing structured logging in our PHP/Laravel apps. Key benefits:

  • Cut costs: Replace custom logging code with a maintainable, MIT-licensed solution (build vs. buy).
  • Future-proof compliance: Enable audit-ready logs for security-sensitive features (e.g., payments, auth) without reinventing the wheel.
  • Low risk: Lightweight and PSR-3 compliant—integrates seamlessly with Laravel’s existing logger. It’s a targeted investment for observability, with minimal operational overhead."

For Engineers

*"The draw/log package lets us:

  • Extend Monolog with Symfony events: Log context for HTTP requests, security events, or business actions (e.g., user.created).
  • Decouple logging logic: Use draw/dependency-injection to configure loggers cleanly in service containers.
  • Avoid vendor lock-in: PSR-3 compliant, so we can swap it out later if needed. Downsides: Early-stage (0 stars), PHP 8.5+ requirement, and draw/* dependencies. Ideal if we’re already using draw/ bundles or need event-driven logging."*

For Developers

*"Tired of Log::debug(var_export($var, true))? This package lets you:

  • Log with metadata: Attach user IDs, IPs, or custom data to every log entry.
  • React to events: Dispatch logs when users sign up, fail auth, or trigger payments.
  • Keep it simple: No AWS/Sentry lock-in—just Monolog under the hood. Tradeoff: Requires PHP 8.5+. Perfect if you want structured logs without heavy dependencies."*

For Security/Compliance Teams

*"This package helps us:

  • Automate audit trails: Log sensitive operations (e.g., role changes, API access) with immutable metadata.
  • Reduce manual log analysis: Structured JSON logs integrate cleanly with SIEM tools (e.g., Splunk, Datadog).
  • Meet regulatory requirements: GDPR/HIPAA-ready logging with minimal effort. We recommend piloting it for high-risk features (e.g., payments) before full rollout."
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky