Some Poker Copilot users have been having sporadic hangs or really slow refreshes. I suspect this is happening for users with loads of hands in their database. Like 1 million+. So I've been doing some profiling of Poker Copilot's database queries.
I've stumbled upon a couple of full table scans taking place. To translate into English "full table scan" is database-speak for "dog slow". A simple tweak or two fixed this, and reduced the time it takes to import a million hands by about 10%.
More aggressive caching has given a further 10% improvement. I knocked another 2-3% off the import time by removing some columns that were being populated but never used.
I've also created a new denormalised table for Position Summary and Stake Level Summary. To translate again, "denormalised table" is database-speak for "table that has unnecessary redundant information but goes at light-speed". For big databases, this reduces the time taken for Position Summary and Stake Level Summary updates by two orders of magnitude. Two orders of magnitude? That's right, what was taking 25 seconds now takes 0.25 seconds. I suspect this is mostly happening because the denormalised table is small enough to be entirely held in memory.
The downside of the new denormalised table is that it adds about 10% to the time taken to import a million hands. But I think it is a good trade-off. On my iMac, importing a million hands takes a little under two hours.
These changes have not been straight forward. I find a problem. I implement a trial solution. I run a full import of all my test data, which takes about two hours. I then measure the results, not just for the import but also for the various summaries and filters. Sometimes I find the trial solution has made things worse. So I have to undo the trial solution and go to plan B. Then I repeat the whole escapade.
This takes time. Mostly spent waiting. Which is why I've been spending time on the Mac Poker Software mini-site experiment. I hope that the database profiling pays off to give all users a smoother, faster experience.
Last night, while letting a million hands load, I played two tables simultaneously. The HUD continued to update within a couple of seconds after each hand for the full duration.
I hope to release a test version of this update for you to try out within a few days.
The Poker Copilot Blog
Tracking the development of Poker Copilot, Mac OS X software for poker analysis and statistics.
Saturday, 16 January 2010
Poker Copilot Database Improvements
Subscribe to:
Post Comments (Atom)
Poker Copilot Translation Project
Want to use Poker Copilot in your language? Then help with the Poker Copilot Translation Project.
About This Blog
In May 2008 I started working on Poker Copilot, initially as a product to help me with my own poker playing. Soon I joined a "30-day Challenge", where the participants each aimed to launch a software product in 30 days. As a result of this challenge, Poker Copilot version 1.0 was launched in July 2008.
This blog tracks the ongoing development of Poker Copilot. Who would find this blog interesting? People interested in 1-person software development, in Poker, or in both.
Contact me via email at steve at pokercopilot dot com.
This blog tracks the ongoing development of Poker Copilot. Who would find this blog interesting? People interested in 1-person software development, in Poker, or in both.
Contact me via email at steve at pokercopilot dot com.
Blog Archive
-
►
2012
(38)
-
►
February
(9)
- Coming in the next Update: "Continuation Bet on Tu...
- Quote of the Day
- Poker Copilot 3.01 Now Available
- Making Poker Copilot easier to use for new users
- Poker Copilot 3 Available Now
- Poker Copilot 3 Final Release Candidate
- What's Holding up Poker Copilot 3
- How Not to Use Poker Tracking Software
- Poker Copilot Russian Translation Updated
-
►
January
(29)
- Coming in the Next Update: Ignore Old Hand History...
- Coming in the Next Update: Poker Copilot can forma...
- From the "It's About Time, Too" Department
- Poker Copilot Business Cards
- Playing on Entraction Network?
- Unofficial Update for Ongame Players
- One Person with Two Accounts Playing on Ongame?
- Small Tweaks in Poker Copilot Preferences
- Ongame Network and Poker Copilot
- Buy Poker Copilot via Bank Transfer
- Improvement to Appearance of HUD Popup
- Improvement for Poker Copilot Translators
- Coming in the Next Update: HUD Layout has an extra...
- Unofficial Poker Copilot Update for Ongame Network...
- Poker Copilot Demo Video in French
- Reason I Like My Mac #17,823
- Updated Poker Copilot Demo Video
- Poker Copilot 3 Coming...
- News for Poker Copilot Translators
- Updated Poker Copilot Translations
- New Poker Copilot Screenshots Reveal How Version 2...
- Poker Copilot Translation Project: Update
- PokerStars now has built-in Auto-Hotkeys
- Reflection on the PokerStars Update that Broke Pok...
- Poker Copilot 2.101 Now Available
- Poker Copilot Website in French
- Spanish Website Translation
- Poker Copilot Website in Spanish
- Update for PokerStars Denmark Users (PokerStarsDK)...
-
►
February
(9)
-
►
2011
(154)
-
►
December
(10)
- New Unofficial Update
- Poker Copilot Discussion Forum in French
- Coming in the next update: multiple HUD layouts
- Poker Copilot Fact of the Day
- Unofficial Poker Copilot Update for the Brave
- Coming in the next update: All-in Equity in $ or B...
- Who uses BarrierePoker.fr?
- Coming in the next update: Filter tournaments by t...
- Help Wanted: BlazingStars or AHK for Merge Network...
- Coming in the next update: choose a language for P...
-
►
December
(10)
-
▼
2010
(247)
-
▼
January
(35)
- Poker Copilot vs Poker Tracker
- So _THIS_ is why I can't advertise on Google or Ya...
- Rush Poker "HUD" Available
- 16 Days to First Page of Google Results
- Cool Animation from Google Analytics
- Rush Poker HUD is Almost Here
- Poker Copilot 2.29 Now Official Release
- Rush Poker HUD Mockup
- PokerStars Update Breaks Poker Copilot: Fix is Rea...
- Yahoo Doesn't Like MacPokerSoftware.com
- A Breakthrough in Poker Copilot Performance
- Modified HUD for Full Tilt Rush Tables?
- Why No Absolute Poker Tournament Support in Poker ...
- Another Experimental Poker Copilot Release
- Update on "Mac Poker Software" experiment
- Thought of the Day
- Not a Poker Copilot Update
- Sentence of the Day
- The Next Poker Copilot Update will be Faster
- Outsourcing Testing
- "Rush Poker" on Full Tilt
- Amsterdam, Documentation, and Mac Poker Software
- Coping with Apple's Java Policy
- Poker Copilot Database Improvements
- Paid Search Listings?
- Mac Poker Software
- If All Support Emails Could Be Like This
- Starring Hands for Later Review
- 92.2% Borrowed Code
- Amazon Mystery of the Day
- Write the Poker Copilot Docs - for $$?
- Poker Copilot Roadmap for 2010
- Poker Copilot 2009: The Year in Review
- Poker Copilot 2.23 Ready to Download
- Improved Handling of PokerStars Tournament Rebuys ...
-
▼
January
(35)


4 comments:
The database improvements sound great, I look forward to seeing them soon. Import time is almost meaningless to me, once the DB is set up I never have to worry about it. So I'd suggest you always make the import time vs. HUD / stats refresh time tradeoff in favor of the actual playing elements.
As for Mac Poker Software, it's off to a good start. Why not have it be a full-featured blog with comments, and then make all your posts that aren't specific to Poker Copilot over there instead of here? You could focus this site on selling and customer service and that one on linkbait. Wordpress is so easy, it wouldn't take much effort to get things humming over there.
I think you should leave the whole blog here! I chose Copilot over PT3 because I saw how active you are (and how much effort you put into this) on this blog and that really set my decision.
@Keith and Frailty: Thanks for the comments. I'm very attached to this blog, so there's not much chance of me diminishing my writings here, no matter where I go with "Mac Poker Software".
@Keith, you are right, WordPress is crazily easy. I should have been using it long ago.
on a completely different note, the search Gmail feature is beyond amazing. this has made my record keeping so much easier now that i dont have to copy and paste every single result! keep up the fantastic work
Post a Comment