| 
 | 1 | +<?php  | 
 | 2 | + | 
 | 3 | +return [  | 
 | 4 | + | 
 | 5 | +    /*  | 
 | 6 | +    |--------------------------------------------------------------------------  | 
 | 7 | +    | Default Search Engine  | 
 | 8 | +    |--------------------------------------------------------------------------  | 
 | 9 | +    |  | 
 | 10 | +    | This option controls the default search connection that gets used while  | 
 | 11 | +    | using Laravel Scout. This connection is used when syncing all models  | 
 | 12 | +    | to the search service. You should adjust this based on your needs.  | 
 | 13 | +    |  | 
 | 14 | +    | Supported: "algolia", "meilisearch", "database", "collection", "null"  | 
 | 15 | +    |  | 
 | 16 | +    */  | 
 | 17 | + | 
 | 18 | +    'driver' => env('SCOUT_DRIVER', 'typesense'),  | 
 | 19 | + | 
 | 20 | +    /*  | 
 | 21 | +    |--------------------------------------------------------------------------  | 
 | 22 | +    | Index Prefix  | 
 | 23 | +    |--------------------------------------------------------------------------  | 
 | 24 | +    |  | 
 | 25 | +    | Here you may specify a prefix that will be applied to all search index  | 
 | 26 | +    | names used by Scout. This prefix may be useful if you have multiple  | 
 | 27 | +    | "tenants" or applications sharing the same search infrastructure.  | 
 | 28 | +    |  | 
 | 29 | +    */  | 
 | 30 | + | 
 | 31 | +    'prefix' => env('SCOUT_PREFIX', ''),  | 
 | 32 | + | 
 | 33 | +    /*  | 
 | 34 | +    |--------------------------------------------------------------------------  | 
 | 35 | +    | Queue Data Syncing  | 
 | 36 | +    |--------------------------------------------------------------------------  | 
 | 37 | +    |  | 
 | 38 | +    | This option allows you to control if the operations that sync your data  | 
 | 39 | +    | with your search engines are queued. When this is set to "true" then  | 
 | 40 | +    | all automatic data syncing will get queued for better performance.  | 
 | 41 | +    |  | 
 | 42 | +    */  | 
 | 43 | + | 
 | 44 | +    'queue' => env('SCOUT_QUEUE', false),  | 
 | 45 | + | 
 | 46 | +    /*  | 
 | 47 | +    |--------------------------------------------------------------------------  | 
 | 48 | +    | Database Transactions  | 
 | 49 | +    |--------------------------------------------------------------------------  | 
 | 50 | +    |  | 
 | 51 | +    | This configuration option determines if your data will only be synced  | 
 | 52 | +    | with your search indexes after every open database transaction has  | 
 | 53 | +    | been committed, thus preventing any discarded data from syncing.  | 
 | 54 | +    |  | 
 | 55 | +    */  | 
 | 56 | + | 
 | 57 | +    'after_commit' => false,  | 
 | 58 | + | 
 | 59 | +    /*  | 
 | 60 | +    |--------------------------------------------------------------------------  | 
 | 61 | +    | Chunk Sizes  | 
 | 62 | +    |--------------------------------------------------------------------------  | 
 | 63 | +    |  | 
 | 64 | +    | These options allow you to control the maximum chunk size when you are  | 
 | 65 | +    | mass importing data into the search engine. This allows you to fine  | 
 | 66 | +    | tune each of these chunk sizes based on the power of the servers.  | 
 | 67 | +    |  | 
 | 68 | +    */  | 
 | 69 | + | 
 | 70 | +    'chunk' => [  | 
 | 71 | +        'searchable' => 500,  | 
 | 72 | +        'unsearchable' => 500,  | 
 | 73 | +    ],  | 
 | 74 | + | 
 | 75 | +    /*  | 
 | 76 | +    |--------------------------------------------------------------------------  | 
 | 77 | +    | Soft Deletes  | 
 | 78 | +    |--------------------------------------------------------------------------  | 
 | 79 | +    |  | 
 | 80 | +    | This option allows to control whether to keep soft deleted records in  | 
 | 81 | +    | the search indexes. Maintaining soft deleted records can be useful  | 
 | 82 | +    | if your application still needs to search for the records later.  | 
 | 83 | +    |  | 
 | 84 | +    */  | 
 | 85 | + | 
 | 86 | +    'soft_delete' => false,  | 
 | 87 | + | 
 | 88 | +    /*  | 
 | 89 | +    |--------------------------------------------------------------------------  | 
 | 90 | +    | Identify User  | 
 | 91 | +    |--------------------------------------------------------------------------  | 
 | 92 | +    |  | 
 | 93 | +    | This option allows you to control whether to notify the search engine  | 
 | 94 | +    | of the user performing the search. This is sometimes useful if the  | 
 | 95 | +    | engine supports any analytics based on this application's users.  | 
 | 96 | +    |  | 
 | 97 | +    | Supported engines: "algolia"  | 
 | 98 | +    |  | 
 | 99 | +    */  | 
 | 100 | + | 
 | 101 | +    'identify' => env('SCOUT_IDENTIFY', false),  | 
 | 102 | + | 
 | 103 | +    /*  | 
 | 104 | +    |--------------------------------------------------------------------------  | 
 | 105 | +    | Algolia Configuration  | 
 | 106 | +    |--------------------------------------------------------------------------  | 
 | 107 | +    |  | 
 | 108 | +    | Here you may configure your Algolia settings. Algolia is a cloud hosted  | 
 | 109 | +    | search engine which works great with Scout out of the box. Just plug  | 
 | 110 | +    | in your application ID and admin API key to get started searching.  | 
 | 111 | +    |  | 
 | 112 | +    */  | 
 | 113 | + | 
 | 114 | +    'algolia' => [  | 
 | 115 | +        'id' => env('ALGOLIA_APP_ID', ''),  | 
 | 116 | +        'secret' => env('ALGOLIA_SECRET', ''),  | 
 | 117 | +    ],  | 
 | 118 | + | 
 | 119 | +    /*  | 
 | 120 | +    |--------------------------------------------------------------------------  | 
 | 121 | +    | MeiliSearch Configuration  | 
 | 122 | +    |--------------------------------------------------------------------------  | 
 | 123 | +    |  | 
 | 124 | +    | Here you may configure your MeiliSearch settings. MeiliSearch is an open  | 
 | 125 | +    | source search engine with minimal configuration. Below, you can state  | 
 | 126 | +    | the host and key information for your own MeiliSearch installation.  | 
 | 127 | +    |  | 
 | 128 | +    | See: https://docs.meilisearch.com/guides/advanced_guides/configuration.html  | 
 | 129 | +    |  | 
 | 130 | +    */  | 
 | 131 | + | 
 | 132 | +    'meilisearch' => [  | 
 | 133 | +        'host' => env('MEILISEARCH_HOST', 'http://localhost:7700'),  | 
 | 134 | +        'key' => env('MEILISEARCH_KEY', null),  | 
 | 135 | +        'index-settings' => [  | 
 | 136 | +            // 'users' => [  | 
 | 137 | +            //     'filterableAttributes'=> ['id', 'name', 'email'],  | 
 | 138 | +            // ],  | 
 | 139 | +        ],  | 
 | 140 | +    ],  | 
 | 141 | + | 
 | 142 | +    'typesense' => [  | 
 | 143 | +        'api_key'         => 'xyz',  | 
 | 144 | +        'nodes'           => [  | 
 | 145 | +            [  | 
 | 146 | +                'host'     => 'localhost',  | 
 | 147 | +                'port'     => '8108',  | 
 | 148 | +                'path'     => '',  | 
 | 149 | +                'protocol' => 'http',  | 
 | 150 | +            ],  | 
 | 151 | +        ],  | 
 | 152 | +        'nearest_node'    => [  | 
 | 153 | +            'host'     => 'localhost',  | 
 | 154 | +            'port'     => '8108',  | 
 | 155 | +            'path'     => '',  | 
 | 156 | +            'protocol' => 'http',  | 
 | 157 | +        ],  | 
 | 158 | +        'connection_timeout_seconds'   => 2,  | 
 | 159 | +        'healthcheck_interval_seconds' => 30,  | 
 | 160 | +        'num_retries'                  => 3,  | 
 | 161 | +        'retry_interval_seconds'       => 1,  | 
 | 162 | +    ],  | 
 | 163 | +];  | 
0 commit comments