It’s been a while since I’ve posted on this blog. Mostly because I’ve been busy on zillion projects. I’ll soon write an update to my cascades queuing post. For a recent project of mine, flexivo.tv, I’ve been researching an efficient way to get rid of Amazon’s Simple Queue Service (SQS) service for one main reason, I needed simultaneous queueing capabilities. One message being in multiple queues at once, that is. My experiments with file system and MySQL queues, even when cascaded with memcached wheren’t performant enough. I found my answer in NoSQL. But now, enough for the intro, now the rant
I’m writing this while watching Stephen Graham making a statement as Al Capone in Boardwalk Empire. So I shall make one too. Now about that fellah’, the INFAMOUS Internet Explorer 6. A friend of mine recently showed me a site of his making where he directs the IE6 users to a deadend page where he encourages them to upgrade. Sweet. I totally agree. Then he tells me that IE6 is a plague. It sure is, still agreeing. Then that it’s been alive that long because of all the conciliatory developers like him and me that worked, harder an harder as new standards like transparent PNGs came along, to ensure IE6 compatibility. And that’s where I disagree.
HTML, Usability, Web development
Wednesday 16 February 2011
I would guess every programmer knows what queueing is. For those who don’t, well, it’s some sort of waiting line for messages: they get in, they wait, and they get dispatched for processing.
I used queues many times in the past. First in first out (FIFO) queues for for mass email programs, last in first out (LIFO) queues for MicroBlogBuzz, and prioritized queues for a video compression platform, among other things.
After a lot of trial and error, storage engine changes, code optimization, benchmarking and swearing, I came up with this idea of cascaded queueing. In a nutshell, cascaded queueing is putting two queues back to back: a master queue that will act as a warehouse, and one or many slave queues that will act as distributors or brokers.
Tuesday 8 December 2009
You might have read my post about my FLV meta data and cue point reader/writer. You might also know that the F4V format (which really is simple MP4+H264+AAC) succeeded to the FLV format, and is supported by Flash 9.0.115 and up.
The MP4Info class is a simple extensible PHP class reading the MP4 container’s frames (called boxes) to get various information, namely the video duration, the video/audio codecs, the width and the height, as well as the embedded XMP meta data.
The F4V format is better than the FLV format in many aspects:
- Better compression ratio
- Better quality at similar bit rates
- Open source compressors available, through ffmpeg and libh264 (Flash 8 On2 VP6 codec is proprietary)
- Decoding H.264 is a lot less CPU intensive on the host computer than decoding On2 VP6
Thursday 11 June 2009
And voila, you can toggle your JPEG overlay, move it around, change it’s alpha transparency and reset it to its default position.
A small demo is available here.
Tuesday 13 January 2009
At the beginning of the week, I officially launched a little project named MicroBlogBuzz. The concept is simple: find URLs on micro-blogging platforms, and present the top blogged ones.
For those not familiar with micro-blogging, it’s pretty much like blogging, but smaller — hence the micro prefix. Micro-blogging posts are very short, 140-160 characters that is. The most popular platform is Twitter, but new platforms are appearing, such as Pownce, Jaiku and Identica. Also, this year’s TechCrunch50 winner is the project oriented micro-blogging platform Yammer (which I didn’t get to try yet).
Back to MicroBlogBuzz, I started this little project part time while testing various APIs, and when stumbled on TwitterBuzz, which presents the most popular links on Twitter. However, TwitterBuzz only present the domain name, which isn’t really meaningful since most micro-bloggers use TinyURL or similar services to shorten their URL. TinyURL was presented as the Top Twitter link. And I thought it was kind of stupid. So I decided to do the same thing, but to follow the HTTP redirections to get to the final URL.
Categories and sub categories. Directories and sub directories. Building a tree of nodes that have parents is a common problem these days.
There are two solutions to this problem, but unfortunately, the inefficient one is often used by programmers, due to the lack of time, or to inexperience.
Wednesday 10 September 2008
The HTTP protocol is quite simple. But many of us under-use it, programmatically speaking. There are many very simple performance mechanisms that are often forgotten. Many developers go for disabling HTTP caching completely, as they often don’t understand how to use it, and because it can cause weird bugs when used incorrectly.
Efficiently using caching translates into:
- Better response and loading time
- Decreased load on the server
- Better user experience
This article aims to present a simple explanation of the HTTP protocol and proper use of HTTP caching.
Thursday 17 July 2008
If you played with the pretty cool Amazon Web Services, you probably started off fetching a sample off the Developer’s Connection pages. At least, I did.
One cool sample for Simple Queue Service is the one by Justin@AWS. But (you saw it coming, I suppose), being anti-PEAR (for many reason, such as dependencies, weight, version conflicts, non-catchiness of the name, fructose intolerance, etc.), I just couldn’t leave the sample like that. Yes, this is me again reinventing the wheel.
The original library depended on two PEAR components:
Friday 11 July 2008
Update (Dec 20, 2008): The AMF0Parser library has been updated to better handle broken AMF0 packets. The FLVInfo2 library PHPDoc has been updated.
Update (Aug 15, 2008): The AMF0Parser library has been updated to support the Date type in the metas, added among others by the “inlet media FLVTool2″ tool.
Update (Jun 11, 2009): The project has been moved to Google Code. MP4Info, an F4V file (or more genericaly MP4 file) class is also available: check out blog post and project at Google Code.
If you’ve done Flash banners or micro-sites that embed video with cue points for synchronization before, you know that it’s a pain in the arse. There doesn’t seem to be any tool around to modify the damn points once the file is encoded, so you’ve got to re-encode the file over and over to have your things synced correctly.
If you’ve tried to reverse engineer the FLV format before, you know that it’s a pain in the arse as well. The AMF0 format is anything but intuitive, and the documentation has been lacking for a long long time — although there’s apparently an SDK now. Luckily, there was OSFlash, and SabreAMF and AMFPHP that could be used as a documentation source.
If you recognize yourself, this might be your lucky day. After many hours of trial and error, I’ve finally been able to reverse engineer it, and to build a library that extract essential FLV information, reads the Meta, and allows you to write them back — including the cue points.
Friday 4 July 2008
I got no IPod. I got no IPhone. But I’ve got an OpenID. I’m like a low class geek. But whatever. I’ve read a bit lately about OpenID and wanted to give it a try on one of my personal projects (CodeIgniter based, you bet).
I’ve stumbled upon Rémi Prévost — who’s blog a follow more or less consistently due to the lack of time — CIOpenID module. It’s basically a CI embed of Janrain’s PHP_OpenID.
His code is great and works well. But one thing I don’t like about it is that it requires a different bootstrap file (a modified version of
index.php) and a somewhat hacked version of your typical
.htaccess file. The reason is, CodeIgniter annihilates the
$_GET variable during initialization, because GET queries aren’t secure (ok, this is overly simplified, but you get the idea).
Being who I am, and somewhat liking to reinvent the wheel during my free time, I used a different approach. Rather than using a different bootstrap file, I rather chose to use the
PHP, Social networks
Wednesday 25 June 2008