primedata-ai/prime-lara

This package is not installable via Composer 1.x, please make sure you upgrade to Composer 2+. Read more about our Composer 1.x deprecation policy.

PrimeDATA sdk for Laravel

0.3.3 2020-09-14 05:09 UTC

This package is auto-updated.

Last update: 2021-10-14 07:27:33 UTC


README

// check: config/queue.php

return [

    'connections' => [
        'redis' => [
            'driver'      => 'redis',
            'connection'  => 'default',
            'queue'       => env('REDIS_QUEUE', 'default'),
            'retry_after' => 90,
            'persistent'  => env('REDIS_QUEUE_PERSISTENCE', true),
            'host'        => env('REDIS_QUEUE_SERVER_HOST'),
            'port'        => env('REDIS_QUEUE_SERVER_PORT'),
            'database'    => env('REDIS_QUEUE_SERVER_DB'),
            'password'    => env('REDIS_QUEUE_SERVER_PASSWORD'),
            'block_for'   => null,
            'cluster'     => 'predis',
        ],

    ],

];
//config/prime.php
return [
    'source_key' => 'web-1fcrwsKgV0Zk2EdpCFYIvYbNRgs',
    'write_key'  => '1fcrwstLt8g0ggTL5K87a6O6umy',
];
use Illuminate\Support\ServiceProvider;
use Prime\LaravelBuffer;
use Prime\QueueBuffer;

class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     *
     * @return void
     */
    public function register()
    {
        $this->app->singleton(QueueBuffer::class, LaravelBuffer::class);
    }

    /**
     * Bootstrap any application services.
     *
     * @return void
     */
    public function boot()
    {
        //
    }
}