davispeixoto / php-batch
A framework for PHP batch processing
Installs: 9
Dependents: 0
Suggesters: 0
Security: 0
Stars: 42
Watchers: 6
Forks: 3
Open Issues: 7
Language:HTML
Requires
- php: >=5.4.0
- psr/log: ~1.0
- symfony/config: 2.8.x-dev
- symfony/console: 2.8.x-dev
- symfony/process: 2.8.x-dev
- symfony/validator: 2.8.x-dev
Requires (Dev)
- phpunit/phpunit: ~4.0
Suggests
- aws/aws-sdk-php: Allow sending log messages to AWS services like DynamoDB
- monolog/monolog: For logging utilities
This package is auto-updated.
Last update: 2024-10-24 04:18:03 UTC
README
A framework for PHP batch processing
Motivation
- scalability for medium to large applications (let the servers to serve, and keep heavy processing in another offline place)
- PHP is popular and is getting better every day, in tools and community. And there is no such tool yet for PHP.
- Aside mainframe and big data worlds, apparently there is only Spring Batch, a Java framework for this sort of processing, and yes, this work is highly inspirated by it.
Use cases
- images processing (resizing, watermarks, upload to CDN servers)
- processing credit cards payments
- weekly, end of month, quarters, etc, reports generation
- sending transactional notifications
- data sync between systems (ERP to CRM, for example)
- enterprise partners files transfer and processing
Be Warned!
More than other common software artifacts, heavy processes must be thought and architected way more thoroughly
Features
- Parallelization
- StopWatcher (for time-boxed batches)
- Manual Stop for Business Reasons
- Retry
- Skip
- Logging
- Events
- Chaining
Installation
Configuration
Usage
License
This software is licensed under the MIT license
Versioning
This project follows the Semantic Versioning
Thanks
An amazing "Thank you, guys!" for Jetbrains folks, who kindly empower this project with a free open-source license for PhpStorm which can bring a whole new level of joy for coding.