Saturday, August 30, 2014

Using email to manage work queue can be deceptive

I loathe on emails that have been replied more than 5-6 times. I am sometimes copied on emails where there are 20 replies. Today I have an email about post commit reviews which has 20 replies, Grrr.  I procrastinated whole day to read it and looks like I am not goint to read it today.

Problem with 20+replies email is that by the time you end up reading all 20 of them you have lost context of what is the final picture.

I saw this infographic from 2012  that 28% of time is spent on reading emails.  I think for me its may be 50% or more as I work from home and most communication is over emails except very few which happens  over skype or phone calls.

Would love to explore tools to save time.  I found 2 new tools in gmail so far, "Canned Response" and "Mark as Read" button, lets see if it helps.

For e.g. I would be copied on email "23.7.3 CL- 120157 on all Appnodes and EOS nodes in SJC, AVL and AM2", now I don’t want to delete it as I may need it in case there is an issue in prod. But I also want to move it out of my Unread queue as I am using email to manage my work queue. I am hoping now I don’t need to open email and mark it as read, a one click would do it.

Also thinking of adding more filters to just sweep some emails I care less to trash as other members are taking care of dealing with them.

But this got me into thinking should I use email to manage my work queue, I used to use a task list before but problem was that some items would never get done. Then I switched to gmail and all pending work would be in emails  marked as Unread, I would have read it but if any action is required I would mark it as Unread.  I am almost at a tipping point because it takes me almost from 9-4 to talk to my team and deplete the email queue. That leaves sometimes 1 hour or sometimes 2 hours to write any kind of code. Sometimes it feels like I got rid of all emails that came to me in the day but I got nothing productive done. So was I just pretending to work?

Also gmail is deceptive, when I come in morning it shows me I have 76 unread emails but daily there are many emails that have between 3-5 replies and some are suckers with 10+ replies. So really its almost 150+emails to deal with and this is after sending lot of emails to trash directly.

Need to find some other way to manage the work queue, I had  tried using JIRA but that also hasn’t fared well.

How to discover JS errors in production code in 5 min

Today I was pulled into a customer call where some customer complained that browser froze for him and the UI kept showing Processing.... . Now as usual I was asked to hunt if it was a server issue or did this customer had any errors. I checked from new relic and from haproxy logs but didnt found any. Then it occured to me what if its a JS error, there was no way to find it out. Then I remembered that New relic had a Beta product to detect JS errors. I went an enabled it from Browser->AppName->settings  and within 10 min the errors started flowing.

Good news is that there arent that many errors but in entire day there were almost 150 of them. But for a java guy this is good info and now I can hunt the UI team to fix them.

Wednesday, August 27, 2014

subeclipse 1.6 and svn 1.8 upgrade

I used to use subeclipse to connect in addition to having subversion command line client to work on same repo.  Subeclipse used to be great when doing move/rename in eclipse and adding new files without moving to command line.

Recently operations upgraded svn to 1.8 version and somehow subeclipse broke

it kept giving org.tigris.subversion.javahl.ClientException: svn: URL 'svn+ssh://' non-existent in revision '120,109'

At first I thought its eclipse issue because I was able to connect to some other public svn repo fine.

Then I found out that public repo was on 1.7 svn version and our svn server was upgraded to 1.8. I  had subeclipse 1.6 client connector.

I upgraded eclipse and reinstalled subeclipse but no luck.  Finally gave up  on subeclipse and installed subversive with 1.8 connector.

Even subversive worked fine but it wont show up Team->Share project for one repo. Restarting eclipse or other things wont help. Finally I figured out you just remove project from eclipse and add it back and that would solve it, phew.

Even with so many issues and bugs, open source software rocks :).

Sunday, August 24, 2014

new relic speed index comparison

If you are a SAAS company then its good to know how you fare against market in terms of SLA, speed index, error rate and other attributes.  It seems new relic has a way to share your speed data anonymous with others to see how you compare with others.

It seems our startup is in 95th percentile in terms of server speed and even though we had 99.979 % availability we are in 54th percentile and others are doing far better than us in SAAS B2B world.

Error rate is high for an almost obsolete backup product is causing the numbers to skew so I would ignore it for time being.

Although what stands out if web page response time for our single page app is in 11th percentile. It sucks, will chase what is going on in coming days.

transposing a video from horizontal to vertical

Wife got ALS challenge and I took a video of her drenching in ice using iphone. The only issue was the somehow I tilted the phone while taking it and it came horizontal. If it was an image then many image editors will transpose it for you.

Now challenge is that I cant ask her to drench in ice again so instead of her getting mad at me to ruin her video (yaa I know the Facebook generation needs everything to be perfect if its posted on Facebook).  So now I need to transpose it, it seems you can do it using ffmpeg in ubuntu.

First try was using

ffmpeg -i ~/Desktop/IMG_0888.MOV -vf "transpose=1" -r 30 -sameq -acodec copy ~/Desktop/test.MOV

but a 90MB file became 350MB which would be impossible to post on FB in 1 hour.

So I gave a second try using

ffmpeg -i ~/Desktop/IMG_0888.MOV -vf "transpose=1" -b 25000000 -sameq -acodec copy ~/Desktop/test1.MOV

where some site said you take 1G and divide it by your no of seconds in video and that would be the bit rate you give in -b

Tuesday, August 19, 2014

Do we scale?

For sure we scale, I got this report from new relic out of 2 data centres and even if traffic is increased 5 times the response time only increases 40%.

Having this kind of visibility is great for keeping 99.99% SLA

Monday, August 11, 2014

Proactive production support by trusting data

Five years ago when I joined my employer we were in reactive mode when it comes to production performance. Nodes were going down daily and we would jump to fix that fire and then move to next fire. Problem with this approach was that we would be always busy and even nightly calls for customers in Europe.  Similar pattern was happening when it came to production support, many issues were known only when a customer would report it. Again this would mean that we would get calls on weekend and we had to fix issues ASAP and sometimes that means putting a band-aid. Some times issues will linger in production unnoticed for 1-2 weeks and when customer would report it, its a lengthy and arcane process to hunt for issues in existing logs. More than debugging this would require  a lot of patience and persistence to look for trend and form a time-line of events to hunt for root cause. Only few engineers would be willing to do so.

Over the course of last few years we became better at production support by turning to proactive production support. I wrote a exception analysis report and  daily my team members and me would analyse exception report and send tickets to appropriate colleagues.  Many times there will be tickets that don’t require patch and can be temporarily fixed by doing some data cleanup. If the issue was in the flow executed by background jobs or automated agents then we would fix issues even before customer would notice it.  Advantage of this approach is that issues will get caught before it becomes a nightmare. Incremental fixes adds up to a lot and now the volume of production issues we have to fix has reduced because we fix many of them in the background and include it in coming patch.

Two months ago we installed new relic and we are not turning the table around on performance front also by trusting data rather than gut feelings.  New relic allows us to do trend analysis and release impact analysis, we can catch the issues while its turning from Green->Yellow->Red. Off course some issues turn from Green to Red within 10-15 mins but there are many that takes time. For e.g. Last week I noticed that one data centre is behaving odd and avg response time of all apis increased from 50ms to 100ms. That means customers were having degraded performance but still they were not complaining. Today I found it was due to one customer and the problem can be fixed by some data tweaks. I did the tweaks and performance is back to normal.

Similarly from new relic we found many issues where calls to memcached would happen in a loop or database queries in a loop. Those kind of issues affect customers with 25-30K users but not all customers. Every penny counts and by taking a proactive jab at these issues we are increasing customer satisfaction and loyalty but also we are becoming more predictable by trusting metrics.

for e.g. we recently converted a service from python to java and in past we have never ramped up from 0 to 1000 customers in a week.  But because of new relic I clearly saw that system was performing well with no errors even though we ramped from 30->200->1000 clients. Tomorrow we would add 500 more clients and all this is because the decision is based on data rather than gut feeling.