<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>mrkris - Latest Comments</title><link>http://mrkris.disqus.com/</link><description>RubyOnRails Programmer</description><atom:link href="https://mrkris.disqus.com/comments.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 30 Apr 2013 16:14:13 -0000</lastBuildDate><item><title>Re: A new beginning</title><link>http://www.mrkris.com/2010/09/13/a-new-beginning/#comment-880727663</link><description>&lt;p&gt;Blah&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Tue, 30 Apr 2013 16:14:13 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-55128018</link><description>&lt;p&gt;I wouldn't necessarily say memcache is outdated either, but you do have to use it the way it was intended to avoid those headaches.&lt;/p&gt;&lt;p&gt;For point 2, "good vs bad" design is relative to the scaling requirement.&lt;/p&gt;&lt;p&gt;In any case, point 3 handles the single key approach to scale the cache to millions of product ratings.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">chriswpage</dc:creator><pubDate>Mon, 07 Jun 2010 11:39:53 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-55084610</link><description>&lt;p&gt;It's poor design to have a hash store all the ratings. A single key is fantastic, the issue is that memcache is outdated. Just my honest opinion.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Mon, 07 Jun 2010 01:45:18 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-55073602</link><description>&lt;p&gt;Well, one point here is, you mention that you are caching in the view state, but the example of what you are caching is straight from the data layer.  I would first consider handling the cache logic for data closer to the data layer, far from the view.&lt;br&gt;&lt;br&gt;Secondly, since this appears to be a manual expire, for this particular example, what you are caching ( using memcache ) may be too specific to be doing such a manual expire.  Unless you have literally millions of products in the same memcache instance, you gain very little by caching each star rating in it's own key/val.  An alternative is to use one key, and put all the star ratings in a data structure under that key - or the if the value size limit is an issue, know your data, and create a handful of known key names to meet that limitation.  That way the manual expire can be easily controlled.&lt;br&gt;&lt;br&gt;Thirdly, if this is not a manual expire, consider a key name convention that matches the value.  Ie, if this is a star rating for product a product, incorporate the product SKU onto the key name.  Ie: &lt;br&gt;&lt;br&gt;KEY="rating_NIN-WII-BLACK-00001-OEM "&lt;br&gt;VALUE="5"&lt;br&gt;&lt;br&gt;The 3rd point makes manual cache and automated cache simple and is more "memcachey".&lt;br&gt;&lt;br&gt;So final point, if you choose to use memcache, implement it in a more "memcachey" way to save a lot of headache.  &lt;br&gt;&lt;br&gt;Not a sermon, just a thought.&lt;br&gt;&lt;br&gt;&lt;a href="http://www.chriswpage.com" rel="nofollow noopener" target="_blank" title="http://www.chriswpage.com"&gt;www.chriswpage.com&lt;/a&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">chriswpage</dc:creator><pubDate>Sun, 06 Jun 2010 22:50:24 -0000</pubDate></item><item><title>Re: Authlogic and rescue_from ActionController::RoutingError</title><link>http://www.mrkris.com/2009/08/21/authlogic-and-rescue_from-actioncontroller-routingerror/#comment-53288405</link><description>&lt;p&gt;Thanks for sharing the fix!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Will Jessop</dc:creator><pubDate>Mon, 31 May 2010 17:23:27 -0000</pubDate></item><item><title>Re: Authlogic and rescue_from ActionController::RoutingError</title><link>http://www.mrkris.com/2009/08/21/authlogic-and-rescue_from-actioncontroller-routingerror/#comment-52832825</link><description>&lt;p&gt;+1 this fixed it for me, thanks.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">thermistor</dc:creator><pubDate>Fri, 28 May 2010 23:42:13 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-50905753</link><description>&lt;p&gt;I've since moved to Redis for caching. It's solved virtually all my problems related to caching.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Tue, 18 May 2010 11:48:32 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-50905197</link><description>&lt;p&gt;Here's what I do when I MUST manage expiration manually.  Which is the minority of the time.&lt;br&gt;1. come up with a scheme for tracking keys.  For instance, I might generate a tracking key named "#{user.login}---movies"&lt;br&gt;2. cache an array indexed by the tracking key.&lt;br&gt;3. any time you cache data relating to a user's movies, add the key to the list of keys stored under "#{&lt;a href="http://user.id" rel="nofollow noopener" target="_blank" title="user.id"&gt;user.id&lt;/a&gt;}---movies".  When you need to expire those keys, get the list using the tracking key, and delete everything on the list.&lt;br&gt;-----&lt;br&gt;The problem is now you are performing many calls to memcached, and a really expensive call to the database might still be cheaper.&lt;br&gt;Anybody got any better ideas?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Footstrapping</dc:creator><pubDate>Tue, 18 May 2010 11:44:04 -0000</pubDate></item><item><title>Re: Paperclip before_process For Your Habitual Pornographic Needs</title><link>http://www.mrkris.com/2009/09/15/paperclip-before_process-for-your-habitual-pornographic-needs/#comment-49810698</link><description>&lt;p&gt;Great!&lt;/p&gt;&lt;p&gt;thanks&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">airy</dc:creator><pubDate>Tue, 11 May 2010 17:39:08 -0000</pubDate></item><item><title>Re: Authlogic and rescue_from ActionController::RoutingError</title><link>http://www.mrkris.com/2009/08/21/authlogic-and-rescue_from-actioncontroller-routingerror/#comment-40368056</link><description>&lt;p&gt;Just what I needed. Thanks&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Nathan Colgate</dc:creator><pubDate>Thu, 18 Mar 2010 14:30:57 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-31350588</link><description>&lt;p&gt;Would love to hear more about the analytics you're running against the data collected in redis. Thanks!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Adam</dc:creator><pubDate>Tue, 26 Jan 2010 01:27:18 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-24145616</link><description>&lt;p&gt;In the system I'm building, you just add more nodes to post-process the clicks, unlike most click tracking systems that process on click then redirect.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Thu, 26 Nov 2009 16:33:34 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-24145308</link><description>&lt;p&gt;Hi! great idea, interesting method but I guess it is a lot to work to create click tracking to work very good, although I appreaciate that you decided to post your work not everybody does that.&lt;/p&gt;&lt;p&gt;______________________&lt;br&gt;&lt;a href="http://express-press-release.net/64/IntegraClick-Tops-Inc-Magazine-Annual-Fastest-Growing-Private-Company-List.php" rel="nofollow noopener" target="_blank" title="http://express-press-release.net/64/IntegraClick-Tops-Inc-Magazine-Annual-Fastest-Growing-Private-Company-List.php"&gt;Affiliates&lt;/a&gt;&lt;br&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">BenDamond</dc:creator><pubDate>Thu, 26 Nov 2009 16:18:56 -0000</pubDate></item><item><title>Re: Authlogic and rescue_from ActionController::RoutingError</title><link>http://www.mrkris.com/2009/08/21/authlogic-and-rescue_from-actioncontroller-routingerror/#comment-22954975</link><description>&lt;p&gt;For what it's worth I had to do the same thing in my rescue method.  I was worried that it was a bit of a hack, but now that I see others doing it I feel like it's the right thing to do :-).  Thanks for the post.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jbasdf</dc:creator><pubDate>Fri, 13 Nov 2009 18:00:44 -0000</pubDate></item><item><title>Re: If You Cant Learn For Yourself Go Back To PHP</title><link>http://www.mrkris.com/2009/10/30/if-you-cant-learn-for-yourself-go-back-to-php/#comment-21854089</link><description>&lt;p&gt;Actually... I learned a lot by reply to "stupid" questions made by lazy people, and found by google obviously... and I'm still doing it...&lt;br&gt;Maybe that those lazy people (or casual programmers) will never become competitive in the rails world, but nonetheless they are quite useful, particularly avoiding me fools...&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Tyron</dc:creator><pubDate>Wed, 04 Nov 2009 08:54:17 -0000</pubDate></item><item><title>Re: If You Cant Learn For Yourself Go Back To PHP</title><link>http://www.mrkris.com/2009/10/30/if-you-cant-learn-for-yourself-go-back-to-php/#comment-21391338</link><description>&lt;p&gt;A great place for these types of questions is &lt;a href="http://stackoverflow.com" rel="nofollow noopener" target="_blank" title="http://stackoverflow.com"&gt;http://stackoverflow.com&lt;/a&gt; Good questions will be answered and add to the corpus of knowledge that is StackOverflow. Also, if the question has already been asked, there is a good chance that StackOverflow will tell the writer about it and save them some time. &lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Carl Fyffe</dc:creator><pubDate>Fri, 30 Oct 2009 17:26:19 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21293649</link><description>&lt;p&gt;I agree with you :) but the app had to be very similar to analitycs. the goal was to sell/buy banners from/to affiliated sites. so we had to calc collected data in way to give a value for ads. moreover, we had only that tools, I'd use other ways and/or technologies :P&lt;br&gt;anyway, your solution looks very interesting! getting request and repliyng with a redirect is a cool idea (and redis too) ;-)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrea Pavoni (apeacox)</dc:creator><pubDate>Thu, 29 Oct 2009 17:43:23 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-21277977</link><description>&lt;p&gt;Will look into this, thanks!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Thu, 29 Oct 2009 13:41:20 -0000</pubDate></item><item><title>Re: Why MemCache Makes Me Want To Spoon Out My Own Eyes</title><link>http://www.mrkris.com/2009/09/29/why-memcache-makes-me-want-to-spoon-out-my-own-eyes/#comment-21277034</link><description>&lt;p&gt;Have you seen the post by Tobias (from Shopify)? Essentially, he advocates versioning the fragments and letting the older fragments fall out of memcache.&lt;/p&gt;&lt;p&gt;See &lt;a href="http://blog.leetsoft.com/2007/5/22/the-secret-to-memcached" rel="nofollow noopener" target="_blank" title="http://blog.leetsoft.com/2007/5/22/the-secret-to-memcached"&gt;http://blog.leetsoft.com/20...&lt;/a&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jauder Ho</dc:creator><pubDate>Thu, 29 Oct 2009 13:28:37 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21272145</link><description>&lt;p&gt;Interesting method, though I don't think it's easily maintainable. I only say this because placing JS on each page to track it seems overkill. The way I have it working is you hit the click tracking system and it redirects you. Track from one point for clicks, track per page with analytics for site specific tracking.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Thu, 29 Oct 2009 12:18:47 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21257049</link><description>&lt;p&gt;Oh, yeah, that makes more sense.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">zaach</dc:creator><pubDate>Thu, 29 Oct 2009 08:23:50 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21256933</link><description>&lt;p&gt;hi mrkris,&lt;/p&gt;&lt;p&gt;to implement link tracking, I've used a LAMP stack (lack of choice from customer). the tracking worked in a way similar to google-analytics:&lt;br&gt;- in the affiliate page, insert a reference to a remote js, specifying  ID of the site (yes, generate a custom JS for each request related to an affiliate site). the js can eventually load an image (for example a banner) working on the page DOM (that's why there's a custom generated JS).&lt;br&gt;- the system gets the requests and save the record. if there's a cookie, then check the record on db for eventual UPDATES instead of INSERT (speacking in SQL terms). saved referer too.&lt;br&gt;- every 10-15 secs, the JS make ajax update request, so there's a track of time per page.&lt;/p&gt;&lt;p&gt;I've worked on the analisys and first core implementation of that system (&lt;a href="http://bit.ly/1c1Pk1)" rel="nofollow noopener" target="_blank" title="http://bit.ly/1c1Pk1)"&gt;http://bit.ly/1c1Pk1)&lt;/a&gt;, then I left the job to others (I was a consultant) . I know it isn't the best way of doing link tracking, but it worked very well :) (seems that the official launch will be during the next weeks).&lt;/p&gt;&lt;p&gt;if you want, we can talk about it more in detail ;)&lt;/p&gt;&lt;p&gt;cheers,&lt;br&gt;apeacox&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrea Pavoni (apeacox)</dc:creator><pubDate>Thu, 29 Oct 2009 08:20:03 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21242844</link><description>&lt;p&gt;I was more meaning, Rack on Rails -- With Sinatra, `ab' was yielding between 700~ requests/sec, whereas Rails is yielding 350~ requests/sec. &lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">mrkris</dc:creator><pubDate>Thu, 29 Oct 2009 01:19:14 -0000</pubDate></item><item><title>Re: Affiliate Click Tracking With Rack And Redis Because I Care</title><link>http://www.mrkris.com/2009/10/28/affiliate-click-tracking-with-rack-and-redis-because-i-care/#comment-21242053</link><description>&lt;p&gt;Sinatra runs on Rack, so I'm not sure how Rack could be slower. Rails also runs on Rack, so you could conceivably use this middleware with either framework, or a minimal Rack app as I believe you suggest.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">zaach</dc:creator><pubDate>Thu, 29 Oct 2009 00:56:23 -0000</pubDate></item><item><title>Re: Making Money While Pooping</title><link>http://www.mrkris.com/2009/10/12/making-money-while-pooping/#comment-20247402</link><description>&lt;p&gt;I was so afraid that this entry was going to include something like "Items needed: (1) Webcam" ... glad it didn't. Good advice. ;-)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Dom</dc:creator><pubDate>Fri, 16 Oct 2009 23:57:31 -0000</pubDate></item></channel></rss>