Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Queries Question  (Read 5010 times)

0 Members and 1 Guest are viewing this topic.

urmomma

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 31
    • GlitchSeekers
Queries Question
« on: December 13, 2005, 08:23:28 pm »

I'm curious, because I have read threads and discussions here on improving the amount of queries used on Coppermine and changing a few of those to sessions. Has this been implmented in the new stable version?

Thank you.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Queries Question
« Reply #1 on: December 14, 2005, 08:40:39 am »

do you expect an answer? How could we answer if you don't post what exactly you're refering to? The generic answer is: yes, queries have been changed from cpg1.3.x to cpg1.4.x
Logged

urmomma

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 31
    • GlitchSeekers
Re: Queries Question
« Reply #2 on: December 14, 2005, 09:57:31 pm »

Well yes I did ;) at the time.

Ok, for example. The index I believe in the 1.3.x version used way to many queries. Alot of which could of been changed to sessions so I was wondering with 1.4.x if that has been done as I have read some earlier threads discussing this.
Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Queries Question
« Reply #3 on: December 16, 2005, 06:29:21 am »

queries really don't have anything to do with sessions.  There are by far many more areas of coppermine that consume more resources than whether session information is stored in the db. (your talking mouse nuts by comparison)

Your probably confusing a thread that discussed file based session information vs sessions information stored in the database.

Coppermine does keep track of its own session information via the db that adds a couple of very minor queries. The flip side of NOT using the db is to use file based sessions which are less secure, and arguably no better performance than storing and requesting the data from a database.

The question of whether sessions should be handled by php and the webserver vs a relation database is one of security. If you can live with the security aspects of php file based sessions AND (if and only if you are using a remote sql server) you might see a performance benfiit from file based sessions.

If you are using a mysql server on localhost, I believe the difference in performance would be measured in cpu ticks, and the vulnerabilities of file based sessions would not make it worthwhile.
Logged

donnoman

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1615
  • From donovanbray.com
    • Donovan Bray
Re: Queries Question
« Reply #4 on: December 16, 2005, 06:32:20 am »

If you want to get a quick boost of performance, make sure that your mysql server has "query caching" turned on, with an appropriate amount of memory dedicated to the cache.
Logged

urmomma

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 31
    • GlitchSeekers
Re: Queries Question
« Reply #5 on: December 19, 2005, 08:46:10 pm »

I see. Thanks for the explanation. Security is not an issue as of now. I'm working with IPB SDK and having the forum's scripts (some of them) run in the background to check user info. I havn't finished that though.

For me, the speed is fine. My problem is that I have a cap of 50,000 queries per hour and I have gone over that in a hour's time twice so far so decreasing the amount of queries of all my scripts is my current goal. Right now, coppermine's index runs the most queries for regular users who visit my site.

I don't quite understand why Coppermine runs 40+ queries on index on my site when my forum's index runs 6. I was just worried. Thanks for all the info.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Queries Question
« Reply #6 on: December 20, 2005, 08:32:21 am »

post a link to your coppermine gallery, you probably have way too many details turned on (i.e. meta albums, cat thumbs, nested albums etc.)
Logged

urmomma

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 31
    • GlitchSeekers
Re: Queries Question
« Reply #7 on: December 24, 2005, 06:13:00 am »

sure.

http://www.glitchseekers.com/image_gallery/index.php

the last uploaded and random albums are turned off. I put a few thumbnails on the index and understand that they each are one query, but I think I can live with that for now.

thanks for helping out.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Queries Question
« Reply #8 on: December 24, 2005, 01:18:47 pm »

well, your index page does look ok for me, I couldn't see much room for speed improvement (except turning of the cat thumbs).
Logged
Pages: [1]   Go Up
 

Page created in 0.02 seconds with 20 queries.