Is too many requests bad

Discussion in 'PHP' started by mcnika, Mar 19, 2010.

  1. #1
    I keep all site/form values in the database.

    Total rows of the table is about 3000, and it increases .
    All this I assign to an array, evey time the page loads.
    Does this somehow slow down the work of the web site.

    Beside this I have another tables with other values.
    And evey time when the page loads, php sends about 50 request to db.
     
    mcnika, Mar 19, 2010 IP
  2. gulamkakoo

    gulamkakoo Peon

    Messages:
    169
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I think too many requests bad because it slower your website and if your site hosted on the shared hosting may be your account suspended due to more request. So it's better to reduce the requests
     
    gulamkakoo, Mar 19, 2010 IP
  3. shallowink

    shallowink Well-Known Member

    Messages:
    1,218
    Likes Received:
    64
    Best Answers:
    2
    Trophy Points:
    150
    #3
    yes its bad. I would look to setup some type of caching for the page to reduce repeat database calls. Only updating the cache when new information has been added to the database.
     
    shallowink, Mar 19, 2010 IP
  4. ceo.ahlul

    ceo.ahlul Peon

    Messages:
    57
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Is the data came from a from or spam?
    If yes i suggest you to use captcha image so it will blog non human activity.
     
    ceo.ahlul, Mar 19, 2010 IP
  5. Izonedig

    Izonedig Member

    Messages:
    150
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    28
    #5
    That's too BAD !! It's not right to load all the database content every page load :(
    But this will not be problem if you don't have too many traffic... How is your traffic ? 10 page loads per minutes ? 1/min ? 1 per 15 min ? ....
     
    Izonedig, Mar 19, 2010 IP
  6. Wrighty

    Wrighty Peon

    Messages:
    199
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #6
    It could be down to a flaw in the coding that is sending too many requests, when they could all be merged into one (or less than 50).

    I'm happy to discuss this further if you'd like me to take a look through & try to optimize for you ... hit me PM :)
     
    Wrighty, Mar 19, 2010 IP