Increase first load speed in laravel project - laravel

i am new in laravel. I did worked in codeigniter for more than 40 projects but did not faced any load issue. Now in new project we are working in laravel, where i just setup and checked laravel then it founds that it load some time in first load. Once load then it works ok, but each time when new session is start after open browser then it takes some time approx 2 seconds evenif there is simple hello page. Any suggestion to improve this ?

1- check the console for any errors , maybe there is a loop not closed.
2- second : you can install some debugging packages like
https://github.com/barryvdh/laravel-debugbar

Related

Jekyll serve on Mac - slow loading

when I try to run Jekyll (C(base) cXXX-macpro:website cXXX$ jekyll serve) on my MAC via the terminal, I receive the following output:
Configuration file: /xxx/website/_config.yml
Source: /xxx/website
Destination: /xxx/website/_site
Incremental build: disabled. Enable with --incremental
Generating...
AutoPages: Disabled/Not configured in site.config.
Pagination: Complete, processed 1 pagination page(s)
done in 3.629 seconds.
Auto-regeneration: enabled for '/xxx/website'
Server address: http://127.0.0.1:4000
Server running... press ctrl-c to stop.
Then, when I try to load the Website via the Browser, it takes up to 2-3 minutes (sic!) to load the site. Finally, when the site is loaded and I try to click on the links on this site, it takes again 2-3 minutes to load the respective page.
Can anyone tell me why this is the case and how to solve this problem?
I finally solved the problem, after two weeks of searching for a solution and posting this question yesterday.
I found the solution here: Page loading suddenly super slow #372.
There seems to be a problem with https://gitcdn.xyz/... in the file head.html in the _include folder. Just change the URL to https://gitcdn.link/ and it works!

Laravel app is very slow - over 3 seconds to boot and 2 seconds to load

The app is not even big,but it takes over 5 seconds to reload some pages,i don't think that is normal eventhough I read that laravel is pretty slow,but this is unusable,I've installed debugbar and it is showing that booting takes over 3.5 seconds while loading of the app is over 2.5 seconds,I've been following a course and instructor's app loads instantly,can someone tell me what effects the booting and load time?
Since this is a general question without specific detail here's a general answer:
Your first step should be to install the Laravel debug bar (which you say you have) and then look at the query time or controller time and narrow down the culprit. Based on that, you can ask more pointed questions on StackOverflow with the details of the specific queries that are slow, or if it's a controller that's slow, you can post the contents of that controller file. From there we can make recommendations in terms of what changes you can make.
One other thing to try is on the same machine try out a vanilla Laravel app and see what the baseline load times are. Maybe there's nothing wrong with your app at all and instead it has something to do with whatever is serving it.
Alright,I think I've got it fixed,was using XDebug for PHP lectures for collage and that is why app was running so slowly,so I've disabled it.
If anyone else will have similar problem here is the solution,but be aware that this will disable your xDebug:
Open XAMMP -> Click on config button for Apache -> Open PHP (php.ini).
Inside of that file look for "[xDebug]" and comment out all the commands that enable it ( in front of commands put ";" and space (" ") ) . It should look like this:
; [xDebug]
; zend_extension = C:\xampp\php\ext\php_xdebug-2.9.8-7.2-vc15-x86_64.dll
; xdebug.remote_enable = 1
; xdebug.remote_autostart=on
And then restart the server
If you need xDebug,then check out this post - PHP on Windows with XAMPP running 100 times too slow

Very long "Router Dispatch" in Clockwork with Laravel 4 on localhost

I've got a Laravel app setup locally with (what seems to me) very poor performance as you can see below:
My setup:
W8 on a pretty fast laptop with SSD
XAMPP 3.2.1
Laravel 4.1.*
Clockwork 1.* (only added the controller event as desribed in the docs)
Debug mode true
The scenario described:
A logged in user access a page with a list of prospects : 1216ms
Then the user logs out : 1164ms
Finally the user is redirected to the login page : 1165ms
As you can see in every single request the bottleneck is the "Router Dispatch" event. What can I do to dig further, and most importantly what can I do to improve its duration?
Or maybe because this is a dev environnment these are expected numbers? (I don't believe so, but I might be wrong).
After updating my XAMPP to the latest and Laravel to 4.2, this just got fixed by itself.

Cant upload an app- stack on uploading

I guess that question have been asked yet , but i wonder if there is something else .
I have archived my app , check validate , than hit distribute .
It usually takes time, but today, i am trying of 8 (!!) hours to upload an update to an app.
iTunes connect is ready for upload binary .
I have tried to start again many times (after 1-2 hour stack in the window :
Your application is being uploaded //status bar have not even started
I just cant figure out why every time you are trying to upload an app,it takes so much time,
and today , its just not working .
Could be a problem with my app that the validation have not seen ?
The app is just 12M size.
What else can you do ?

DB-Toolkit Plugin - on save redirects to wp-admin/admin-ajax.php and returns only a 0

So I aquired a project that is using DB-Toolkit to make a section of the site but the section hadn't been updated in a while ( as in added new content too ) but recently I went to add new content to it and when I click save on the modal window in DB-Toolkit it just redirects me to admin-ajax.php and returns only 0. I looked around in the admin-ajax.php for a die('0') and well theres a lot of them.
I have never used this plugin before and since this is now breaking the production site I need to fix it asap but after a day of trying on my own I have gotten no where..
any ideas / help is appreciated.
the version of wordpress I'm using is 3.2.1 and the version of the db-toolkit plugin is 0.2.6.9 ( i know this is old but when I updated it got even worse, loss of Applications as well as interfaces and it fails to import the backups I have from db-toolkit. so until I fix this issue I don't want to update )
the site was working about 3 weeks ago according to the db records ( last inserted record to the table being used by db-toolkit)
another Plugin removed the dt_start action on the admin and front end, once I just disabled it on the front end everything was fine.

Resources