January 6th, 2009 § § permalink
How many times have you had a cool idea that never saw the light? Or that amazing conversation you had with your best friends which resulted to nothing? It can be that amazing facebook application to solve all the problems of your single friends, or that Iphone game that will rock the world, or an android application, or that robot which will help elderly people remember their pill times. Whatever it is, this is a time to build it and ride the wave with the support of the entire startup community. Surprised?
Well, we hear ya! We call this Shotgun Startup and its your way to huddle together for 48 hours and work on something which will change the world.
How do YOU participate you ask?
Step1 : Get those scribble books out and start going through all those ideas. Once you have decided on the idea you want to implement go here and submit it. This is where the fun begins, The ShotGun Team will go through all your proposals and pick 20 ideas which have the most potential – In other words, that which sounds uber cool and useful.
Step 2: Now that your idea is shortlisted, you need to put together a team which helps you realize this idea. All shortlisted projects can publish list of open roles and participants can apply to be part of this team. You get to pick the ones you like! Use your blogs, twitters, facebooks to find these people and get them as part of the team.
Step 3: Its 22nd January evening and there are 20 teams eager to make it happen. We have experts on various platforms like Android, Iphone, Php, ROR etc, Just in case you need some expert advice. This is where we give you plenty of wifi, coffee (maybe food) and get out of your way. For the next 48 hours its you, your team and your product. Make it happen, and breathe life into your idea.
The Proto.in attendees will start voting for your ideas on the 24th, The top 5 teams will then move to Innovation Jam where they get 5 minutes to present the idea and then the audience can suggest enhancements to the product so it can move towards being a full fledged product.
As the adage goes “Let the Startups win”, sharpen your pencils now! and for more information head to http://shotgun.proto.in Now!
PS: Have you registered for the event yet? if not, head to www.proto.in/register
Proto.in January edition is in the dates of January 23, 24 2009 in the Nimhan’s Convention Centre in Bangalore.
January 3rd, 2009 § § permalink
I think that a lot of people think that its easy to start a web startup and get funding, well part of that is true. Yes, the barrier to start something on the web is extremely low, but lately with the recession getting money for the same is way more difficult than before. So if you are hooked into the web business, here are some simple tips to get through these difficult times.
- Conserve cash – Guess it applies to everyone right now. Optimize for survivability and not being investor friendly. You will need the money later.
- Plan growth – If you are a consumer internet site without any business model (read revenue), control your growth. Optimize for server costs.
- Cut on features – Focus on current platform , make sure you implement absolutely necessary things. Spend time analyzing on why you need it
- Remove dead features – Gain some more resources, remove features which are not being used or not exposed. Most platforms tend to load up a lot in memory, free it for better things / traffic.
- Know when to quit – Sounds stupid, but you should know when to call it quits. There is always a point of diminishing returns. Sit down figure it out and make sure you know your limits.
These are things that I am learning at kwippy, this list more or less encapsulates what is need to run a lean and mean operation. I believe that lower entry barriers does not teach most of us young businessmen the “baniya” ways. Its time to learn that oceans are made of smaller drops of water
, If you have anything more to add to this list, feel free to throw in a comment. Do forgive me for the naive techincal look at it.
December 26th, 2008 § § permalink
Easiest way to get php with good looking urls running on your site . Works for drupal, wordpress and joomla.
server {
listen 80;
server_name www.domain.com;
index index.html index.htm index.php;
root /path/to/domain/files;
location / {
error_page 404 = //e/index.php?q=$uri;
}
location ~ .php$ {
include fastcgi_params;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /path/to/domain/files$fastcgi_script_name;
}
access_log /usr/local/nginx/logs/domain.access_log;
error_log /usr/local/nginx/logs/domain.error_log;
}
November 18th, 2008 § § permalink
This is a basic tutorial on how to get CodeIgniter facebook application on nginx (with the gotchas). The nginx configuration would be like the following
1
2
3
4
5
6
7
8
9
10
11
12
13
| server {
listen 80;
server_name blah.com;
location ~ /index.php/ {
root /home/production/blah;
index index.html index.htm index.php;
include conf/fcgi.conf;
fastcgi_param SCRIPT_FILENAME /home/production/fb_apps/quickdate/index.php;
fastcgi_pass 127.0.0.1:9000;
}
access_log /usr/local/nginx/logs/blah.access_log;
error_log /usr/local/nginx/logs/blah.error_log;
} |
The critical line is the fastcgi_params parameter, that changes the whole game. In the code Igniter application you need to add the following file in [app]/system/application/libraries/FB_controller.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
| <?php
class FB_Controller extends Controller {
// Facebook application key
var $API_KEY = 'your api key';
var $facebook;
var $uid;
/*
* Custom Controller constructor.
* Adds Facebook support.
*
*/
function FB_Controller() {
parent::Controller();
// Authentication key
$secret = 'your secret key';
// Prevent the 'Undefined index: facebook_config' notice from being thrown.
$GLOBALS['facebook_config']['debug'] = NULL;
// Create a Facebook client API object.
$this->facebook = new Facebook($this->API_KEY, $secret);
$this->uid = $this->facebook->require_login();
}
}
?> |
There are some significant changes in the configuration which is at [app]/system/application/config/config.php
1
2
3
| $config['enable_query_strings'] = TRUE;
$config['subclass_prefix'] = 'FB_';
$config['uri_protocol'] = "REQUEST_URI"; |
Now in the application you should write controllers extending the above defined class , for example I modified the welcome controller.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
| <?php
class Welcome extends FB_Controller {
function Welcome() {
parent::FB_Controller();
// Check if the application has been added by the user
try {
if (!$this->facebook->api_client->Users_isAppUser()) {
$this->facebook->redirect($this->facebook->get_add_url());
return;
}
}
catch (Exception $x) {
// Clear cookies for your application and redirect them to a login prompt
$this->facebook->expire_session();
$facebook->redirect($this->facebook->get_login_url());
}
}
function index() {
}
} |
Fire this up and see it all running smoothly, this is basically compiled from all kinds of forum over the internet. Thought it will be useful for someone. In case of any issues contact me at me@dipankar.name.
November 18th, 2008 § § permalink
In my experience with both rails and django, i would have to admit that a lot of things need to be improved at the core of these platforms so that developers can truly deploy a really fast production site. Let talk about what we did at kwippy to make it that much more faster than the default Django setup.
- Use memcached properly : The trick in getting speed is to cache all logged out pages and heavy caching of the user objects when logged in. For example we recently got our sessions into the memcached cloud to see a good speed jump.
- Database structuring : Django does a lot of joins and magic in it ORM, and has a built in caching layer. But the problem is that we developers structure our tables to our percieved needs … not necessarily for the way the ORM works. One way is to start writing custom SQL inside your views, another is to understand the ORM better. Your choice
.
- Database connection pooling : It is pretty shocking to realize that Django does not do connection pooling, I have used DButils connection pooling for our needs. But IMHO it should be a default thing inside the application platform.
- SMTP is slow : Imagine the user filling up a form which is emailed to you, and your SMTP is down. There is a good chance that you will lose that data and the application will give a 500
. To alleviate that i have created a command queue where emails are not sent within the application and a daemon is doing all the dirty work. I will put it all out in the market
, so that you guys can make you site that much more faster/robust.
- Pagination : To be honest, i still do not like django pagination. The problem was that it will getting all the objects and as the database is on a separate machine a lot of data was being transferred over the network. So i created my custom pagination which was faster than ObjectPaginator or Paginator.
Well there are all i could think of right now. Obviously there are some other optimizations that i keep doing …. and will keep writing about. Till the next time, feel free to contact me about these optimizations at me@dipankar.name.