Questions tagged [lumen-5.2]

Lumen 5.2 uses the 5.2 family of Laravel components, as well as introduces some significant changes to Lumen's underlying philosophy and purpose. It has been released on 7th January 2016. Use it in addition to the [tag:lumen] tag in questions specific to Lumen 5.2.

Only Stateless APIs

Lumen 5.2 represents a shift on slimming Lumen to focus solely on serving stateless, JSON APIs. As such, sessions and views are no longer included with the framework. If you need access to these features, you should use the full Laravel framework. Upgrading your Lumen application to the full Laravel framework mainly involves copying your routes and classes over into a fresh installation of Laravel. Since Laravel and Lumen share many of the same components, your classes should not require any modification.

Authentication

Because sessions are no longer included with Lumen, authentication must be done statelessly using API tokens or headers. You have complete control over the authentication process in the new AuthServiceProvider.

Testing Helpers

Since sessions are no longer included with Lumen, all of the form interaction testing helpers have been removed. The testing helpers for JSON APIs remain.

From Lumen 5.2 Release Notes

92 questions
1
vote
1 answer

Cookies in Lumen

Since the last version (5.2), cookies are disabled in Lumen. I'm currently making an API in Lumen with JWT authentication. To secure my application from CSRF attacks I need to set a csrf cookie. But what is the best way to handle that now?
Jordy
  • 4,719
  • 11
  • 47
  • 81
1
vote
1 answer

How to share the files in storage directory in a laravel(main setup) & lumen(sudomain setup)

I am working on a laravel+lumen based project. I am making the main setup which will be web based in Laravel 5.2 and the subdomain (api.domain.com) for handling api requests from mobile devices. THe users will be uploading lot of files(mostly…
Pawan Kumar
  • 594
  • 4
  • 18
1
vote
0 answers

Move Lumen Application from Localhost to DigitalOcean

I am trying to move my Lumen application from my localhost to DigitalOcean. The localhost application works fine. I have uploaded my files through FileZilla and also pointed my document root to var/www/html/resources/views/index.php When I enter…
M. Datu
  • 33
  • 1
  • 5
1
vote
4 answers

using lumen 5.2 with blade template engine?

I follow the official documentation of laravel to create templates with blade.I'm trying to make my first template but doesn't work. 1)Stored in resources/views/default.blade.php ---> @include('includes.head')
Richard Ortiz
  • 29
  • 1
  • 1
  • 8
1
vote
0 answers

change Lumen Laravel log path

Following the instruction here: Laravel Lumen change log file name I am still getting the following error on a server where I cannot write to /storage/logs PHP Fatal error: Uncaught exception 'UnexpectedValueException' with message 'The stream or…
azngunit81
  • 1,574
  • 2
  • 20
  • 38
1
vote
0 answers

Lumen/Laravel 5.2 Service Container not resolving

Running Lumen 5.2.6 When I fire up a Job, if I do this: public function handle(Application $app) { dd($app); ... the dump of the $app is very different than the $app that I would get if I dump at the AppServiceProvider.php level.…
azngunit81
  • 1,574
  • 2
  • 20
  • 38
1
vote
1 answer

create model on laravel 5.2

I'm using lumen from laravel 5.2 and edit app_key and database info in .env file also uncomment $app->withFacades(); in bootstrap/app.php so now i can connect to my database. the problem is i want to use model in my project but always failed. my…
gondai yosuke
  • 599
  • 2
  • 5
  • 19
1
vote
1 answer

How to activate sessions in LUMEN 5.2

Im new to Lumen and i need to use the Session functionality, but based on the change log in the site. Sessions was excluded in the latest release, I already looked up in the documentation of Lumen 5.2, it says that i should refer to Laravel way of…
Pons Suarez
  • 83
  • 2
  • 8
1
vote
1 answer

InvalidArgumentException, "View not found", on Lumen 5.2.6

Tried clearing the app cache with php artisan cache:clear and the views' cache with baao's ClearViewCache, but it didn't work. Followed the Basic Task List tutorial from the official docs, there's an empty Task model in /app folder. The command php…
Rasshu
  • 1,764
  • 6
  • 22
  • 53
1
vote
1 answer

PHPUnit tests fails randomly when used with MariaDB Galera Cluster (read/write user)

I have a Laravel (Lumen 5.2) project that run against a MariaDB Galera Cluster. When running the app it seems to work just fine. But when I run the PHPUnit tests, they randomly fails. The problem is that I populate the database and then trying to…
emajl
  • 25
  • 5
1
vote
1 answer

How can I change session storage path in Lumen 5.2.x

I am using Lumen for API development and uses Windows box to develop them, while trying to deploy it for testing on a CentOS 7 box I am getting following error: > Lumen (5.2.5) (Laravel Components 5.2.*) Fatal error: Uncaught > exception…
deej
  • 2,536
  • 4
  • 29
  • 51
1
vote
1 answer

Using baum/baum with Lumen

I am trying to get baum/baum / etrepat/baum working with laravel/lumen-framework. I have added "baum/baum": "~1.1" into my composer.json and got baum to properly install, however when I try to create a DB migration using php artisan baum:install…
Mark
  • 113
  • 1
  • 8
1
vote
1 answer

Error in JWT authentication lumen 5.2

I am quite new in laravel/lumen framework. I am using lumen 5.2 to build a restful API. For authentication, I am trying to implement JWT authentication I am following this https://laravelista.com/json-web-token-authentication-for-lumen article for…
R.K.Saini
  • 2,678
  • 1
  • 18
  • 25
1
vote
2 answers

Lumen - Missing commands

I have a problem with running Lumen's Artisan. There are most of the commands missing. For an example if I write php artisan routes, I get following error: Command "routes" is not defined. Below is an example of output that I get by typing php…
Mansoor H
  • 594
  • 1
  • 8
  • 25
1
vote
2 answers

Database Transactions Not Found - Lumen

I've been writing tests in lumen but I need to move to a different machine so I've been trying to set it all up. I copied over my tests but I get this error on all of them when I run them [Symfony\Component\Debug\Exception\FatalErrorException] …
Niall
  • 518
  • 1
  • 6
  • 23