Weave 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

Laravel Transaction Proxy Laravel Package

astrotomic/laravel-transaction-proxy

A Laravel package that wraps your services in database transaction proxies, letting you run any method inside a DB transaction via a simple proxy—with support for savepoints, disabling transactions, and configurable behavior.

View on GitHub
Deep Wiki
Context7

Getting Started

The 0.3.0 release is primarily a compatibility release: it adds Laravel 8 and PHP 8 support. There are no advertised new features or breaking changes, so existing day-to-day usage should remain the same while the supported runtime matrix expands.

Minimal steps:

  1. Confirm your application is on Laravel 8 and PHP 8 if you intend to use the newly supported combination:
    php -v
    composer show laravel/framework
    
  2. Require the package at the new minor:
    composer require <vendor>/<package>:^0.3
    
  3. Run the package’s install surface if it provides one:
    php artisan vendor:publish --provider="<Vendor>\\<Package>\\<Package>ServiceProvider"
    php artisan migrate
    
  4. Clear Laravel’s cached package/config state:
    composer dump-autoload
    php artisan package:discover
    php artisan config:clear
    
  5. Run your application’s test suite plus any package-provided smoke test or example from the README.

Where to look first:

  • The package README for installation and the primary facade/helper/service entry point.
  • The service provider for bindings, config merging, publishable assets, and auto-discovery behavior.
  • The package config file after publishing, especially any environment-driven options.
  • The changelog and tests for the Laravel 8/PHP 8 compatibility changes.

First use case:

Install 0.3.0 into a Laravel 8/PHP 8 application, exercise the package’s main entry point from a feature test, and verify that the package’s config, migrations, and container bindings resolve correctly. This gives you a safe baseline before relying on it in production code.

Implementation Patterns

Treat 0.3.0 as the minimum version for Laravel 8/PHP 8 projects:

{
  "require": {
    "php": "^8.0",
    "laravel/framework": "^8.0",
    "<vendor>/<package>": "^0.3"
  }
}

If you support both older and newer Laravel versions, keep a CI matrix that covers the combinations you claim to support:

# Example CI matrix
php: [7.4, 8.0]
laravel: [8.*]

Common integration patterns:

  • Resolve the package through the container rather than calling helpers/facades directly in business logic. This keeps tests fast and makes it easier to swap or mock the package later.
  • Publish and commit the package config only if you need to change defaults. Otherwise, rely on the package’s merged config and environment variables.
  • If the package registers migrations, run them through the normal Laravel migration flow and include them in your deployment process.
  • If the package exposes events, jobs, or commands, wrap them behind your own application service or command where practical so the package does not leak into every layer of your codebase.
  • Use Laravel’s RefreshDatabase or DatabaseTransactions traits in tests that touch package migrations or models.
  • When upgrading from 0.2.x, update the package first, then run your application tests before making unrelated dependency changes. This isolates compatibility failures.

Upgrade workflow:

composer update <vendor>/<package> --with-dependencies
php artisan package:discover
php artisan config:clear
php artisan test

If the package has its own test suite in vendor/, you generally should not edit it. Instead, reproduce failures in your own application tests and report them upstream.

Gotchas and Tips

  • 0.3.0 is still a pre-1.0 release. Pin to ^0.3 and review changelogs before accepting 0.4.x or later, because pre-1.0 packages may change APIs in minor releases.
  • The release notes only mention Laravel 8 and PHP 8 support. Do not assume PHP 8.1, PHP 8.2, or Laravel 9+ support unless the package’s composer.json explicitly allows it.
  • Laravel 8 introduced several ecosystem changes that can surface during package upgrades: model factory namespaces,route namespace handling, and updated dependency constraints. If the package uses factories or routes, verify those paths explicitly.
  • PHP 8 can surface deprecations and type errors that PHP 7.4 tolerated. Run with E_ALL in development and check logs after the first requests and queue workers.
  • If the package is not auto-discovered, register its service provider manually in config/app.php. After adding or removing providers, run php artisan package:discover and composer dump-autoload.
  • Cached config and routes are common sources of “it works locally but not in CI/production” issues. Always clear caches after changing package versions or environment variables.
  • For debugging, inspect the package’s service provider and config first, then use Laravel’s container resolution (app()->make(...)) in tinker to confirm bindings. Enable query logging or Telescope if the package touches the database.
  • Extension points are usually the published config file, container bindings, and any package events or macros. Prefer overriding through config and bindings rather than editing vendor files.
  • If you hit a compatibility problem, capture the exact PHP version, Laravel version, package version, and a minimal reproduction. Pre-1.0 packages often need upstream fixes rather than local workarounds.
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.
socialdept/tenant-domains
tautvydasr/blade-class-names
socialdept/color-scales
maherelgamil/controller
coleus/widgets
coleus/table
coleus/users
coleus/music
coleus/health
coleus/calendar
coleus/notes
coleus/support
coleus/settings
coleus/apps
seampact/laravel
emmyconceptng/laravel-ng-postcode
jjsquady/round-robin
skyraptor/chatter
edlugz/sasapay
abbasudo/artisan-route