Git Product home page Git Product logo

Comments (9)

smarques84 avatar smarques84 commented on July 26, 2024 2

@cleitonsouza and @krisanalfa sorry i didn't noticed i already had CACHE_DRIVER=memcached in the .envfile before adding CACHE_DRIVER=file replacing the old with the new one did the trick.

I also tried to install memcached on MAMP in the mean time but i always got the same error again and again after several tries i will use the file as the cache driver since it seems to work.

Thanks for all

from lumen-jwt.

krisanalfa avatar krisanalfa commented on July 26, 2024 1

It's because you don't have php_memcached installed / activated in your PHP installation. If you want to use memcached, which is I recommend for the best performance to your app, check this article, otherwise you may change in your .env file. Change:

CACHE_DRIVER=file

This changes would make your app using file as it's cache driver, thus it doesn't need any PHP extension.

from lumen-jwt.

smarques84 avatar smarques84 commented on July 26, 2024

CACHE_DRIVER=file on the .env file returns the same error maybe is some incompatibility issue? while using lumen 5.3 i have seen many things being broken in tutorials that used lumen 5.2 and are not working on lumen 5.3

Anyway I will try to install php_memcached when i arrive home.

from lumen-jwt.

krisanalfa avatar krisanalfa commented on July 26, 2024

Can you send your error log?

from lumen-jwt.

smarques84 avatar smarques84 commented on July 26, 2024

@krisanalfa i am sorry but i a newbie at PHP where can i get the the log error? I checked the php_error.log in my MAMP installation but there isn't anything there?

from lumen-jwt.

krisanalfa avatar krisanalfa commented on July 26, 2024

It should be at: storage/logs/lumen.log (relative from your root application path)

from lumen-jwt.

smarques84 avatar smarques84 commented on July 26, 2024

Here is the full log:

[2017-01-18 11:17:53] lumen.ERROR: Symfony\Component\Debug\Exception\FatalThrowableError: Class 'Memcached' not found in /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/MemcachedConnector.php:74
Stack trace:
#0 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/MemcachedConnector.php(53): Illuminate\Cache\MemcachedConnector->createMemcachedInstance(NULL)
#1 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/MemcachedConnector.php(25): Illuminate\Cache\MemcachedConnector->getMemcached(NULL, Array, Array)
#2 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/CacheManager.php(168): Illuminate\Cache\MemcachedConnector->connect(Array, NULL, Array, Array)
#3 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/CacheManager.php(102): Illuminate\Cache\CacheManager->createMemcachedDriver(Array)
#4 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/CacheManager.php(77): Illuminate\Cache\CacheManager->resolve('memcached')
#5 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/CacheManager.php(55): Illuminate\Cache\CacheManager->get('memcached')
#6 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/cache/CacheManager.php(301): Illuminate\Cache\CacheManager->store()
#7 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/tymon/jwt-auth/src/Providers/Storage/IlluminateCacheAdapter.php(57): Illuminate\Cache\CacheManager->__call('has', Array)
#8 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/tymon/jwt-auth/src/Blacklist.php(74): Tymon\JWTAuth\Providers\Storage\IlluminateCacheAdapter->has('c1add477174e7d1...')
#9 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/tymon/jwt-auth/src/JWTManager.php(83): Tymon\JWTAuth\Blacklist->has(Object(Tymon\JWTAuth\Payload))
#10 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/tymon/jwt-auth/src/JWTAuth.php(190): Tymon\JWTAuth\JWTManager->decode(Object(Tymon\JWTAuth\Token))
#11 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/tymon/jwt-auth/src/JWTAuth.php(124): Tymon\JWTAuth\JWTAuth->getPayload(false)
#12 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Auth/Provider/JWT.php(46): Tymon\JWTAuth\JWTAuth->authenticate()
#13 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Auth/Auth.php(82): Dingo\Api\Auth\Provider\JWT->authenticate(Object(Dingo\Api\Http\Request), Object(Dingo\Api\Routing\Route))
#14 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Http/Middleware/Auth.php(52): Dingo\Api\Auth\Auth->authenticate(Array)
#15 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(137): Dingo\Api\Http\Middleware\Auth->handle(Object(Dingo\Api\Http\Request), Object(Closure))
#16 [internal function]: Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Dingo\Api\Http\Request))
#17 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Routing/Pipeline.php(32): call_user_func(Object(Closure), Object(Dingo\Api\Http\Request))
#18 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Http/Middleware/PrepareController.php(45): Laravel\Lumen\Routing\Pipeline->Laravel\Lumen\Routing\{closure}(Object(Dingo\Api\Http\Request))
#19 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(137): Dingo\Api\Http\Middleware\PrepareController->handle(Object(Dingo\Api\Http\Request), Object(Closure))
#20 [internal function]: Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Dingo\Api\Http\Request))
#21 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Routing/Pipeline.php(32): call_user_func(Object(Closure), Object(Dingo\Api\Http\Request))
#22 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(104): Laravel\Lumen\Routing\Pipeline->Laravel\Lumen\Routing\{closure}(Object(Dingo\Api\Http\Request))
#23 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(647): Illuminate\Pipeline\Pipeline->then(Object(Closure))
#24 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(493): Laravel\Lumen\Application->sendThroughPipeline(Array, Object(Closure))
#25 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(467): Laravel\Lumen\Application->handleFoundRoute(Array)
#26 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(398): Laravel\Lumen\Application->handleDispatcherResponse(Array)
#27 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(650): Laravel\Lumen\Application->Laravel\Lumen\Concerns\{closure}()
#28 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(400): Laravel\Lumen\Application->sendThroughPipeline(Array, Object(Closure))
#29 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Routing/Adapter/Lumen.php(103): Laravel\Lumen\Application->dispatch(Object(Dingo\Api\Http\Request))
#30 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Routing/Router.php(513): Dingo\Api\Routing\Adapter\Lumen->dispatch(Object(Dingo\Api\Http\Request), 'v1')
#31 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Http/Middleware/Request.php(126): Dingo\Api\Routing\Router->dispatch(Object(Dingo\Api\Http\Request))
#32 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(151): Dingo\Api\Http\Middleware\Request->Dingo\Api\Http\Middleware\{closure}(Object(Dingo\Api\Http\Request))
#33 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/app/Http/Middleware/CORSMiddleware.php(20): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Dingo\Api\Http\Request))
#34 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(137): App\Http\Middleware\CORSMiddleware->handle(Object(Dingo\Api\Http\Request), Object(Closure))
#35 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(104): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Dingo\Api\Http\Request))
#36 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Http/Middleware/Request.php(127): Illuminate\Pipeline\Pipeline->then(Object(Closure))
#37 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/dingo/api/src/Http/Middleware/Request.php(103): Dingo\Api\Http\Middleware\Request->sendRequestThroughRouter(Object(Dingo\Api\Http\Request))
#38 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(137): Dingo\Api\Http\Middleware\Request->handle(Object(Dingo\Api\Http\Request), Object(Closure))
#39 [internal function]: Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Http\Request))
#40 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Routing/Pipeline.php(32): call_user_func(Object(Closure), Object(Illuminate\Http\Request))
#41 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/illuminate/pipeline/Pipeline.php(104): Laravel\Lumen\Routing\Pipeline->Laravel\Lumen\Routing\{closure}(Object(Illuminate\Http\Request))
#42 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(647): Illuminate\Pipeline\Pipeline->then(Object(Closure))
#43 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(400): Laravel\Lumen\Application->sendThroughPipeline(Array, Object(Closure))
#44 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/vendor/laravel/lumen-framework/src/Concerns/RoutesRequests.php(341): Laravel\Lumen\Application->dispatch(NULL)
#45 /Applications/MAMP/htdocs/lumen-jwt-5.3.7/public/index.php(28): Laravel\Lumen\Application->run()
#46 {main}

from lumen-jwt.

cleitonsouza avatar cleitonsouza commented on July 26, 2024

Sorry @smarques84, but, are you sure the CACHE_DRIVER=file in .env file?

from lumen-jwt.

krisanalfa avatar krisanalfa commented on July 26, 2024

@smarques84 Glad it works. About memcached problem, you can follow this instruction.

from lumen-jwt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.