Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.1] Add server timing response header in debug mode #36231

Merged
merged 8 commits into from Jan 25, 2022

Conversation

laoneo
Copy link
Member

@laoneo laoneo commented Dec 6, 2021

Summary of Changes

Browsers do support a server timing header field which adds information what happens on the server side. This basically gives the developer insight what happens in the "Time to First Byte".
This pr adds the missing header in the debug plugin, as this header should not be added when in production mode because of performance reasons.

Would be nice to get some feedback about spicing up the values of the header as currently I'm just logging them as they are.

The view looks like in the following picture:
image

Testing Instructions

  • When testing in Firefox, make sure you open the page with HTTPS
  • Put joomla in debug mode
  • In the debug plugin with make sure that the Profile collector is enabled (is by default)
  • Open any page
  • Open the dev tools and check the Network tab
  • Select the first entry and then click on the timings tab of the specific request

Actual result BEFORE applying this Pull Request

Only the request timing information is shown.

Expected result AFTER applying this Pull Request

Beside the request timing is the server timing information shown.

@dgrammatiko
Copy link
Contributor

I have tested this item ✅ successfully on cf42d70

@bembelimen this would be great Dev DX if could land in 4.1


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36231.

@Quy
Copy link
Contributor

Quy commented Jan 20, 2022

Maybe add a colon after each description for consistency.

@laoneo
Copy link
Member Author

laoneo commented Jan 20, 2022

@Quy that's how it comes from the profiler. How would you do it then, can you make a suggestion?

plugins/system/debug/debug.php Outdated Show resolved Hide resolved
Co-authored-by: Quy <quy@fluxbb.org>
@Quy
Copy link
Contributor

Quy commented Jan 20, 2022

I have tested this item ✅ successfully on 27300cf


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36231.

@Quy
Copy link
Contributor

Quy commented Jan 20, 2022

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36231.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label Jan 20, 2022
@bembelimen bembelimen merged commit 360409f into joomla:4.1-dev Jan 25, 2022
@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label Jan 25, 2022
@bembelimen
Copy link
Contributor

Thx

@bembelimen bembelimen added this to the Joomla 4.1.0 milestone Jan 25, 2022
@laoneo laoneo deleted the j4/server/timing branch January 25, 2022 06:32
bembelimen added a commit to bembelimen/joomla-cms that referenced this pull request Jan 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants