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

Maker Bundle Laravel Package

atournayre/maker-bundle

View on GitHub
Deep Wiki
Context7

Getting Started

Install via Composer:

composer require atournayre/maker-bundle

Publish the bundle's configuration (if needed):

php artisan vendor:publish --provider="MakerBundle\MakerBundleServiceProvider"

The package now includes logging for command and query services, making debugging easier. Start by leveraging the built-in logging to inspect service execution flow:

// Example: Query service logging
$response = $this->queryService->execute($query);

Check logs at storage/logs/laravel.log for detailed execution traces.


Implementation Patterns

Logging Integration

Use the logging feature to:

  1. Debug Commands: Log command execution steps for debugging workflows.
    $this->commandService->execute(new MyCommand());
    // Check logs for step-by-step execution.
    
  2. Query Inspection: Log query execution for performance tuning.
    $result = $this->queryService->execute($query, ['log' => true]);
    
  3. Custom Logging: Extend logging by binding your own logger to the service container:
    $this->app->bind(MakerBundle\Logging\LoggerInterface::class, function () {
        return new MonologLogger();
    });
    

Workflow Tips

  • Enable Logging Dynamically: Pass ['log' => true] to service methods to toggle logging per request.
  • Log Levels: Use debug, info, or error levels in your custom loggers for granular control.

Gotchas and Tips

Debugging

  • Log Location: Ensure storage/logs/ is writable. Logs may not appear if permissions are restricted.
  • Performance Impact: Logging adds overhead. Disable in production unless critical:
    $this->queryService->execute($query, ['log' => env('APP_DEBUG')]);
    

Extension Points

  • Custom Loggers: Override the default logger by binding MakerBundle\Logging\LoggerInterface in your service provider.
  • Log Formatting: Extend the MakerBundle\Logging\LogFormatter to customize log output structure.

Common Pitfalls

  • Missing Logs: If logs aren’t appearing, verify the APP_DEBUG environment variable is true or explicitly enable logging.
  • Configuration Overrides: Published config (config/maker.php) may override default logging behavior. Review settings after publishing.
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.
calmfox/watch-sylius
damienfern/grpc-symfony-bundle
atoolo/index-bundle
atoolo/genai-bundle
coprotoai/laravel-ticket
davidjln/llm-carbon-bundle
cryonighter/valid-request-bundle
coolms/taxonomy-bundle
coolms/field-bundle
articulate-orm/symfony
aaix/laravel-tall-architect
ephoto/akeneo-connector
emmanuelballery/eb-plantumlbundle
emielburgman/symfony-visitor-beacon
emielburgman/symfony-visit-storage
emielburgman/symfony-security-headers
emielburgman/symfony-log-viewer
emarref/xdebug-bundle
emarref/pubnub-bundle
elriseio/finance-money-bundle