Built‑in Capabilities
Powerful built-in features for modern applications
Glueful ships production-ready features with sensible defaults. Many work out of the box in development; for production, configure drivers (cache, queues, storage) via config.
Core Features
- Caching - Speed up your application with file, Redis, Memcached, or in-memory stores
- Queues & Jobs - Process tasks in the background with reliable job queues
- Events & Listeners - Build decoupled systems with PSR-14 events
- Notifications - Send notifications through pluggable channels (email via the
email-notificationextension) - File Uploads - Handle uploads and blob storage with local or cloud disks
- Rate Limiting - Per-route, tiered limits with standard rate limit headers
- CORS & CSRF - Secure cross-origin requests and browser sessions
- Task Scheduling - Run tasks on a schedule with cron-like syntax
- Distributed Locks - Coordinate tasks across servers
- Field Selection - GraphQL-style field selection and projection for REST
- API Keys - Scoped, rotatable API keys (
ApiKeyService,#[RequireScope],apikey:*commands) - Browser Sessions - Cookie session transport for first-party SPAs, paired with CSRF protection
- Webhooks - Signed outbound webhooks with subscriptions, delivery retries and a management API (
Glueful\Api\Webhooks)
Also in core, without a dedicated page yet:
- Encryption - AES-256-GCM string, binary and file encryption with key rotation (
EncryptionService,encryption:*commands)
See the CLI reference for the related commands.
Quick Example
use Glueful\Events\EventService;
use Glueful\Helpers\CacheHelper;
use Glueful\Queue\QueueManager;
// Cache expensive operations (with stampede protection when enabled)
$cache = CacheHelper::createCacheInstance($context);
$users = CacheHelper::remember($cache, 'users:active', function () use ($context) {
return db($context)->table('users')
->where('status', 'active')
->get();
}, 3600);
// Queue background jobs
$queue = app($context, QueueManager::class);
$queue->push(SendWelcomeEmail::class, [
'user_uuid' => $user->uuid,
]);
// Dispatch events (PSR-14 compatible)
app($context, EventService::class)->dispatch(new UserRegistered($user));
Defaults and Configuration
Each feature has defaults that work in development (file cache, database queue, local disk). For production, pick drivers and limits in the matching config file, such as config/cache.php, config/queue.php, config/storage.php or the rate_limiting block of config/api.php.
Next Steps
Start with the feature you need:
- New to background jobs? Start with Queues & Jobs
- Need to send emails? Check out Notifications
- Want to speed things up? Try Caching