Login to download the latest version of Mint and your favorite Pepper, purchase additional licenses, or post in the Forum. Don't have an account? Create one!

In Partnership with Media Temple

Mint Forum

Speeding up Mint, fixing the cookiejar

Below follows a copy of an email I sent Shaun Inman three days ago. No reply yet.

Remember me? I told you off some months ago for having poorly designed cookies in Mint. I criticised that you did not set the cookie path to Mint‘s installation path instead of doing it site wide. You have later fixed this, and I appreciate that.

Well, I want to criticise you some more. (Lucky you.) This time I want you to speed up the cookies sent to and from the server/Mint and the user.

Look at the MintUnique-line of cookies:

MintUnique=#
MintUniqueHour=#
MintUniqueDay=#
MintUniqueMonth=#

Each with a complete cookie instruction set (expires date, path, domain, secured, …)

Why have you not combined these into one cookie? That would speedup things considerably. You would need to redo how cookies are processed, but that is as easy as regular expressions. Imagine this cookie instead:

MintAnalysis=visits:1#hour:#;day:#;month:#;add-ons:value;

That would reduce the number of instruction sets to one, and shave of quite a few bytes on every request. The naming also makes it clearer for users who are inspecting incoming and outgoing cookies what the cookie is for (usage analysis).

You could reduce the cookie even more by combining hour day, and month key/value pairs into one unique number or a date. Or simply use one unique number for the first hour and set a plus sign and a number to add to get more unique numbers. (say hour:4567;day:+1;month:+2; which would be equals of hour:4567;day:4568;month:4569;)

This improved cookie handling would speed up Mint, and you could slap out a new and faster release. (Version 3, which you could charge for.)

I can offer cheap coding help if needed.

Want some speedier Mints? Fix the cookies!

Sam Brown
Third-Party Pepper Developer
Posted on Apr 25, '08 at 03:40 am

I’m all for a single Mint cookie with combined values, but let’s be honest here, we are not talking about significant speed increases, they will be so small that 99% of Mints users aren’t going to notice a damn bit of difference.

Do note that I have Mint installed on many sites, some with a little traffic and some with a lot of traffic and I have no complaints about Mint’s speed or performance across any of them.

Shaun Inman
Mint/Pepper Developer
Posted on Apr 25, '08 at 02:48 pm

Remember me? I told you off some months ago…

And that’s where I stopped reading. You told me off, I wrote you off.

A single cookie sounds great when campaigning for re-election but when you actually examine the problem you find that a single cookie would still need to deliver the same amount of data plus a means of tracking when each individual piece of data expires. You’d be sending less cookies but that single cookie would be almost double the bytes (and we are talking bytes) of the multiple cookie alternative.

Additionally, the Mint cookies must be available to all directories or things like the Bird Feeder and custom code would not be able to access their data.

I can just imagine the people lining up for a “cheaply-coded, single-cookie Mint 3.”

Well, the tracking process could be done by examining IDs instead of having multiple IDs that expire at various intervals. Mint could instead keep track of when that particular user ID revisits the site.
MintAnalytics=visitor:some-id-that-are-checked-against-last-visit-in-database;

You must be logged in to reply. Login above or create an account

Hey there, I have officially suspended sales and support of Mint. The Create Account, Add License, Transfer License, and Contact forms have been disabled. Existing customers may continue to login and download Mint.

More info Continue