Solved

Does anyone have any experience with quickcache?

Posted on 2014-03-11
16
405 Views
Last Modified: 2014-03-12
Hi

I'm trying to compress my website.  I have been using a MySQL implementation of quickcache but have run into problems on setup.

I have made the mysql databse called quickcache but cant configure the table.  There is a ms.sql script which is:

CREATE TABLE CACHEDATA (
   CACHEKEY varchar(255) NOT NULL,
   CACHEEXPIRATION int(11) NOT NULL,
   GZDATA blob,
   DATASIZE int(11),
   DATACRC int(11),
   PRIMARY KEY (CACHEKEY)
 );


Can some one help with the break down of this script please.  I want to create the table in mysql which it support.

Cheers

Si
0
Comment
Question by:cybersi
  • 10
  • 6
16 Comments
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39920880
I'd like to step back from the technical details a little bit and get to the business reasons for trying something like this.  Are you investigating this because the site is slow?
0
 

Author Comment

by:cybersi
ID: 39920893
Hi Ray

I can improve the load time of my site by 80% by using gzip.  I have read that search engines are now timing sites for their crawlers.

Cheers

Si
0
 

Author Comment

by:cybersi
ID: 39920917
Hi Ray

Here is a link if that helps?

http://quickcache.worxware.com/index.php?pg=manual

Also im trying to run the script as shown in the link ie

(in PHPadmin) mysql <quickcache> < script.sql but it fails.

Thanks

Si
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39920950
improve the load time of my site by 80% by using gzip
I think you can do this with a server setting; it doesn't need any MySQL involvement.  What kind of server are you using?
0
 

Author Comment

by:cybersi
ID: 39920955
its a hosted package with fasthosts.  I don't have access to the physical server.
0
 

Author Comment

by:cybersi
ID: 39920958
heres yet another link I have found which explains a bit better -good old google
0
 

Author Comment

by:cybersi
ID: 39920968
using the above sql code do you know from the script how many fields I require for my table and I will do it manually?

Thanks by the way Ray

Si
0
 

Author Comment

by:cybersi
ID: 39920971
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 

Author Comment

by:cybersi
ID: 39920986
I'm guessing 6
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39921207
I haven't read all of the betterExplained article, but what I have read looks spot on to me.  Look for the part about these topics (links):
For IIS, enable compression in the settings.  In Apache, enabling output compression is fairly straightforward.
By way of trying to explain what I think you really want to do, let me float a few ideas.

1. The objective is to make the site load faster for the client browser (including web crawlers that behave like client browsers).
2. The ways to do this include (A) send less data to the client browser and (B) make the server scripts run faster.

Thoughts on 2.A: GZIP will help with this, even without any effort to optimize the markup.  If you want to optimize the markup, you will find low-hanging fruit in putting the CSS and JS into a minimum number of linked files.  After the first load, the client browser will cache these and the server will not have to send them again.  Consider using YSlow to learn more about the behavior of the web server and the web site.  Optimize images for the web.

Thoughts on 2.B: Whenever there is a performance problem in a computer application, the solution is always found in the I/O subsystem.  In modern web applications that almost always means the data base, since the server file systems are pretty straightforward and not subject to much tuning.  My recommendation would be to examine the data base and look for tuning opportunities.

Make a Google search for the exact phrase, "Should I Normalize My Database" and read the very interesting and thoughtful arguments on the many sides of this question.  You may want to consider a redesign after you've read that! Some things that can be done immediately without restructuring include fairly simple steps.

Add a LIMIT clause to every query where you do not absolutely require a table scan.

Add indexes on every column used in WHERE, ORDER, GROUP, JOIN, HAVING and any other clause that is relational in nature.

Use EXPLAIN SELECT on every complex query.  I define complex as touching more than one table.

Never use SELECT * but instead SELECT only the columns you need.

Avoid the use of BLOB or TEXT data types; move these large data elements out of the data base and into the file system.  Store a URL in the data base instead of storing the bloated data.

Thoughts on a data base table to hold your pre-packaged web pages...

1. If your hosting company is doing things right, the GZIP can be done dynamically for each request.  And if they're not able to help you with this, consider getting another host.  This is not rocket science; it's a meets-minimum part of professional web hosting.

2. If you build and store a web page then serve the stored version, you lose something of the dynamic nature of a data base driven web site.  That's a lot to give up.

3. Compressing the web page output to store it in a data base is a lot of overhead that has to occur somewhere.  I'm not sure how you might trade that off against the savings that might or might not accrue.

So my conclusion would be to try 2A (dynamic GZIP first), then look at optimizing the markup and images.  If that gets your page loads down to an acceptable level, you're home free.  If not, look under the hood of the SQL engine and optimize the data base structure and query structure.

HTH, ~Ray
0
 

Author Comment

by:cybersi
ID: 39921243
Wow Ray that's an answer and a half!!!!  Going to take me along time to digest and understand.  I should let you now I'm not a developer just a simple end user who is trying to get our family web page working professionally.
0
 
LVL 108

Accepted Solution

by:
Ray Paseur earned 500 total points
ID: 39921281
Got it!  

My recommendation is to contact your host and ask them to verify that the server will comply with a GZIP DEFLATE request.  They should know what that is and they should be doing it already, but it's worth verifying.  Your second step would be to get Firefox, Firebug and YSlow.  You can Google those terms and find out where to get the downloads.  Installation is easy and you can get a wealth of information from YSlow.
0
 

Author Closing Comment

by:cybersi
ID: 39921285
Thanks Ray
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39921423
Thanks for the points and thanks for using EE! ~Ray
0
 

Author Comment

by:cybersi
ID: 39923091
Hi Ray

Just to give you an update.  I spoke to the hosting company and they can only do it on a Linux system.  So I have to upgrade from 2003 to 2008 and then to linux.  This will also give me access to the .htaccess file which a can chnage the config setting to allow me to be more flexablible.

Thanks for putting me in the right direction.

Simon
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39923557
Hey, Simon.  Thanks for the update.  I think you're headed in the right direction.  Good luck with it! ~Ray
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
echo button 13 48
razorCMS: Change Menu Font 4 27
Help cleaning out CSS 2 32
LOAD DATA LOCAL INFILE problem 11 22
Why do we like using grid based layouts in website design? Let's look at the live examples of websites and compare them to grid based WordPress themes.
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now