21
redheadedrod
Re: Configuration settings impacting speed

Why do you need a persistent connection?

I ask because the library 2.6 is using does not support persistent connections without losing much of the functionality so unless there is a good reason to use it I wouldn't suggest it. Otherwise I would like to hear of why you would need it.

Thanks!

Rodney


22
Cifug
Re: Configuration settings impacting speed
  • 2014/3/23 2:25

  • Cifug

  • Quite a regular

  • Posts: 208

  • Since: 2007/12/13


Quote:
redheadedrod wrote:
Why do you need a persistent connection?

I ask because the library 2.6 is using does not support persistent connections without losing much of the functionality so unless there is a good reason to use it I wouldn't suggest it. Otherwise I would like to hear of why you would need it.

Thanks!

Rodney

I don't need it, I was just asking where these configuration settings are? You don't know where they are? Me either lol

If you do know where this configuration settings file is, you could just tell me. So then I could have a look at it.

Marty.

23
Cifug
Re: Configuration settings impacting speed
  • 2014/3/24 2:29

  • Cifug

  • Quite a regular

  • Posts: 208

  • Since: 2007/12/13


I noticed that DiggerSS mentioned in post #8 that it is located in the makefile.php.

I can't seem to find this file. I had a look through mainfile.php it's not in there.

Any ideas?

Cheers,
Marty.

24
Mamba
Re: Configuration settings impacting speed
  • 2014/3/24 3:44

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


You cannot find it in mainfile.php because the DB part has been moved to
/xoops_data/data/secure.dist.php

which during installation is then copied to:

/xoops_data/data/secure.php
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

25
Cifug
Re: Configuration settings impacting speed
  • 2014/3/24 10:53

  • Cifug

  • Quite a regular

  • Posts: 208

  • Since: 2007/12/13


Thanks Mamba, what does the "Persistant Connection" actually do, and if we shouldn't use it why is it an option in set up?

Cheers,
Marty.

26
Mamba
Re: Configuration settings impacting speed
  • 2014/3/24 11:02

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


Marty, there have been countless blog posts about this topic by real experts in this area, so it's best if you read it directly from them.

Just google for:

mysql persistent connection vs non-persistent

and you'll find tons of articles about it...
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

27
Cifug
Re: Configuration settings impacting speed
  • 2014/3/24 11:11

  • Cifug

  • Quite a regular

  • Posts: 208

  • Since: 2007/12/13


Oh sorry, I thought it was a xoops thing... My bad, I should have thought to google first then come here for answers lol

28
redheadedrod
Re: Configuration settings impacting speed

When I looked at what they were in the past they didn't seem to be worth using. It IS currently a selection you can make with 2.5.7 as far as I know in the installation program but is removed in 2.6.0. You can always go back and toggle it on in your secure.php file as mentioned by Mamba.

When I converted Doctrine to work with Xoops for 2.6 the persistent connection stuff did not work and when I looked through the support forums for Doctrine it appeared that the PDO library has a much more efficient way of doing things so a persistent connection is not necessary and will actually prevent some functions of Doctrine to work if you try to use it so support for it is non existent for 2.6 but again it is not needed.

In short my understanding is that is creates a connection to the database that never gets closed. The intent is that the performance is boosted with this because you do not need to keep opening and closing the connection. My understanding is that in reality it creates little if any actual performance boost and because you are opening connections you never close it can create a bunch of open threads to the database server. Most hosts limit the number of open threads to the database so you could potentially cause problems on the server so most hosting companies discourage or openly ban use of persistent connections. This is as I understand it when I researched this a few months back so if my memory is accurate this information should be accurate.

29
Yage6
Re: Configuration settings impacting speed
  • 2014/8/2 1:32

  • Yage6

  • Just popping in

  • Posts: 2

  • Since: 2014/7/15


Thanks for this link to best practices for speeding up your website...found it helpful not just re gzip but also for understanding why you should make javascript and css files external.

30
redheadedrod
Re: Configuration settings impacting speed

For 99.99% of the users of Xoops, using CSS or JS files that are external to your site is a waste of time.

The ONLY times I would worry about this is if:
#1, your host is slow and anything offloaded from your host makes a difference.
#2, You are being charged for bandwidth and you are looking to save anywhere you can.

For most of us the time savings would be barely measurable and by no means noticeable. Unless of course you have a very busy site and lots of users at the same time.

It is hard to use externally hosted CSS file unless you are using a standard one that hasn't been modified. You might be able to use something like Google code or something to post it but I have not done this.

If you are using a standard JS library such as Jquery you could use the library from Google or another host. The point of this is that Google is generally much faster than your host and the bandwidth would be used from Google instead of your host.

Realistically, CSS and JS files are cached in your browser and generally never change so the savings really is only for those members that clear their cache all the time.

Rodney


Login

Who's Online

249 user(s) are online (149 user(s) are browsing Support Forums)


Members: 0


Guests: 249


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Mar 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits