The Microprenuer Academy and my experience so far

December 23rd, 2009

So it has been quite a while since I have written but things have been kind of hectic. Not really much of an excuse but at least now you know. So today I want to discuss something new to the blog which is basically the Micropreneur Academy. Now I am not sure if you have heard about it so let me start with a little introduction.

The Micropreneur Academy is an on-line community that teaches and helps micropreneur to understands the hassles and insides of the world they are venturing into. To be clear a micropreneur is someone who is running a one-man startup company and is not interested in growing it into an employee house. Now this does not mean you should work alone but that is a lesson I will leave to the academy to teach.

What I want to say is that the academy has loads of information that I am finding very useful and the founder, Rob, really goes out of his way to help people see the inside of his academy by offering money back guarantee even though you can see the material (well a very good part of it). I also want to point out that Rob is one of the few people in the on-line business world he is not married to the technology he is using and maybe that is what makes him successful. When I wanted to join, I found myself unable due to PayPal refusing cards from my country. Unlike every other on-line experience I have had, Rob was willing to try other means of payment such as Amazon payment services if I was willing to try. Needless to say I took up Rob on his offer and boy am I glad I did it.

So until next time hopefully much sooner.

Running Multiple hunchentoot instances

September 6th, 2009

So if you are someone like me and interested in developing  web applications in Common Lisp then you have probably come across hunchentoot by Dr Edi Weitz. Now hunchentoot is not the only common lisp web-server out there and there are those who argue against its design concepts but it is one that I have found to well suit my need. Now I will be writing a list of posts about how to go around setting up things to work for a web application, but for this post i want to talk about multiple hunchentoot instances.

As you might know lisp hosting is not abundant so must of the time you need your own server instance to run your lisp on. However instances are relatively expensive when compare to other hosting options so it might be useful if you could run multiple websites of the same server. And it turns out you can do exactly that with hunchentoot and you do not need multiple instances of your common lisp running (I use SBCL).

Your first option is to visit Cyrus Harmon website and get his hunchentoot vhost code and run it on top of your hunchentoot. The code is clean and understandable and last i checked Cyrus uploaded a new version on 12 June 2009.

Your second option is to use hunchentoot built in capabilities and separate your websites on different ports (you could use a webproxy in front but that is another post). Start by creating your hunchentoot instance in the following manner:

(hunchentoot:start (make-instance ‘hunchentoot:acceptor
:port port
:request-dispatcher dispatcher))

Now the important part is that we started by telling this particular instance that we need hunchentoot to listen to the designated port. The key thing you need to take care of however is the parameter request-dispatcher. It turns out creating a hunchentoot acceptor this way you can no longer use any of hunchentoot built in dispatcher functionality (Which is the price you have to pay). So how to deal with that is to make sure that the dispatcher is actually a function that return the appropriate html.

This function needs to take one argument which is the response object and then return the proper html based on the response. There are different ways to do this that could be fast. One suggestion which I implemented was to create a hash table with the url as the key and the handler function as the value and i simply do a funcall on the handler function. it is that simple :) .

Hope you enjoyed the above and stay tuned for some more information on lisp programming.

cl-cron, cron like lisp library

March 21st, 2009

Hey everyone, I just released the cl-cron library that I have written during this week. The library with instructions on usage is found on the main website or directly by going here.I was pretty disappointed not to find such a library when I started searching a couple of days ago (apologies to the Clon author but I just saw your entry after my release), so I hope cl-cron is of use to someone.

Anyways, your opinion matters so if anyone uses it or wants some changes let me know.

The very first post

March 21st, 2009

Okay I have finally managed to get myself to start a WordPress blog after finding myself to busy to continue work on a blog like website in Lisp. The features of WordPress are quite impressive and the fact that I can manage to post from Emacs really sold me the whole idea. So here we are, I am not sure how often I will be updating but I will try my best and we will see how it goes.

Okay now for some background the blog’s domain names is a bit long I know but it fits with my personal website so I kept it. As for me, I love technology and to find out how it fundamentally works. I am also a big fan of nature and exercise. And … okay enough about me I guess.