Sunday, March 10, 2013

If you don't try, it is the same as failure.

I always give this piece of advice to everybody who is on the dating scene. It is all about numbers. You can stare at a distance, and hope that the hot girl across the way will come over. Or man up and go over to her and say hello. If you get shot down, oh well, move on. If you don't go over and ask, guess what? You just got shot down.

By not doing anything, you are essentially getting shot down over and over again. You can apply this to lots of things. Look at these blog posts. When I first started, I was kind of worried that I was going to get put down for spelling or grammar. Or even worse, be called out for posting something that was wholly inaccurate. I could have sat on the sideline in fear, but I stood up to the internet and said hello. And the internet is the hottest chick in the room.

Same goes for writing code. In the beginning...and middle and end, you need to just hammer out code like your life depends on it. It will most likely suck and be shot down by somebody above you. Guess what though, it isn't the end of the world. You will learn from this, and get better. You will continue to write and write until one day your code is amazing. Then you will go back and look at your old code and think, "damn, the cocaine after affects lasted longer than I thought" Then you will fix it and life will go on. You should learn from this and you will get better.

I think this is the reason why some people are terrified of open source. You are laying it all out on the table. Your hope is that your repository will be downloaded and forked for future enhancements. But what if the fork is to fix some major flaw that you missed? Can you live with that? Or what if you fork something and just make it worse? These things happen, but you will learn from your mistakes and get better.

Just like trying to get a phone number at the bar, these things take time. You have to keep trying over and over again. If all else fails, go after the ugly chick at the bar, or invest in Visine for allergies.....

Sunday, March 3, 2013

How to lose customers.


This weekend I traveled back into 1955. That is right kids, I had no internet. On Friday I began to notice that my internet connection was slow to say the least. Come Saturday, I had nothing. So I did the normal thing and called Time Warner. In my head this was going to go something like this.

Me: Hey my internet isn't working.

TWC: We will send a technician out tomorrow, as it is already past noon.
Me: Great, thank you very much.

The next hour on the phone made me realize that some companies just don't care about you. You are a dollar sign and nothing more. When I first called the support line I was talking with a nice lady and explained to her what my problem was and all the steps I had gone through to fix it. Reset the computers, unplugged the modem, hard wired into the modem(eliminate WiFi being the cause); everything that their site says to try before calling. After I explained all of this, I was informed that there were no outages reported in my area, so it must just be me. For some reason this just didn't give me warm and fuzzies like I think she was expecting. 

So next I'm asked if I can connect to any websites at all. I say, it is about 50/50 and even then it is super slow. "Well please try a speed test" Ok not sure how this will help solve my problem but ok. About 6 tries and another laptop reboot, I'm able to load the page. Time Warner has their own speed test page that I was asked to use. Click begin test, 72 ms ping. Not bad. Preparing Download.........10 minutes goes by, 15, 20, 25, 30. After 35 minutes the test completes . I pay for 50Mbs/second. I was happy to see I was getting .04Mbs/sec, money well spent. Upload starting. And the site crashes. Doesn't even try, internet just gives up.

Now at this point is where TWC will lose me as a future customer. I was informed that because I had a connection, that there was no outage, nothing could be done. Excuse me? I'm getting 1/100th of what I am paying for and I'm shit out of luck? This did not sit well with me. I asked for somebody more technical, I have had you guys log into my modem before, why can't you now? I'm elevated to tier two. This lady asked me ping google.com and do a traceroute. Shocking results, 75% packet loss and traceroute times out before the 6th hop. Which six hops is how many hops I have to make before I'm out of TWC network. Now this gets their attention and they connect to my modem remote and attempt to troubleshoot. Note this has been 45 minutes on the phone to get somebody to actually look at logs.

Yup, wouldn't you know it. Critical errors all over the logs, I do have a problem. Let's get somebody out to your place ASAP and get you up and running. How does seven days from now sound?

That is correct Ladies and Gentlemen, I was to wait one week before anybody could think about getting to my place. Needless to say, I was furious. I asked how that could even be thought as a reasonable timeline for an outage. The only thing I got back was an unapologetic sorry. Not good enough. I asked to be transferred over to their billing department because one of two things were happening. I am getting comped for this time without service, or I'll just cancel my service and have another ISP set up in 1 day rather than wait 7 for them. And like some form of corrupt magic, a Monday slot has opened up.

I went to twitter to vent my dissatisfaction, 

 internet outage and the first available time for repair is seven days from now. Unacceptable! Only when I threatened not paying my bill did you magically find a time on Monday. Still, unacceptable.

and was greeted with a response from TWC. They asked for for my information to try and help out. The response I get back.

Thanks I see we have an appointment setup for Monday the 4th from 1 - 3 PM to get your issue resolved. ^JH

So now They aren't helping or reading my messages. I explain that I am still unsatisfied that my service is out for 48 hours with no explanation of what is going on. This is the last response I have gotten from them.

Unfortunately that is the earliest available appointment we have. The notes show your appointment has been expedited already. ^JH

So the notes show that they expedited the appointment huh? You mean the appointment that was never set up because I just threatened to cancel my service? And since when is 48 hours expedited on anything but the mail?

It is just unfortunate that ISP's are monopolies because they don't have to get better. While I was talking with them on twitter, I looked at other conversations going on. It doesn't matter who you are, they don't care. They had business customers who were being told they would be without phones, and internet for 72 hours at the earliest. Business customers, people with SLA's that state they are contractually obligated to being serviced in a timely manner. 

Sorry, that this is just a massive venting post. But dammit, somebody needs to bring down the giant. I am not going to sit on my hands quietly, I'm going to find a way to make it hurt for TWC. The first thing is by canceling my service. And if this post gets even one more person to either cancel their service or decide against stating with TWC, then I have done my part.

And from the bottom of my heart, Time Warner Cable. Fuck You! Go play in traffic and Die in a fire.

As for the rest of you ISP's, get your shit together before Google Fiber spreads like herpes in a Catholic Boys choir.



Monday, February 25, 2013

Google can do what?

So say you have done all the things that I have said in previous posts about your social networking. Now you getting job offers left and right. Next thing you have to do is the interview. When you go in there will be lots of questions asked to you. But hopefully you will have a chance to ask your own questions. If you aren't given this chance, that might be a bad sign. So what should you do before you go in? Well first off, research the company you are going into.

Do a quick Google search on the company and maybe the position in your company. Find anything other than some news article and the job posting itself? Didn't think so. But here is what you can do. First thing go into advanced search and search by file type, or place this command at the beginning of your search "filetype:(pdf, excel, doc, etc.)" This will limit your search to only the filetype of your choosing. Now what can you gain from this? Well if you search by PDF or even powerpoint, you can get presentations that the company has created. You search by excel docs and you might find payroll. Not exaggerating here. I know a guy who trains this kind of stuff for a living. He used to put in the names of companies that were in His classes to see what they could find. That was until He found the commissions of all the managers of the CEO that was in his class. Needless to say, very awkward.

So the question is how does Google have these things? Is this illegal? Is Google hacking our networks? Well to answer those questions with the following; Magic, maybe...., and no. Google "crawls" the internet. Much like you surf the net, Google does, but much much faster than you or I. What happens is that say you attach a document to an email. You send your email and somewhere between here and that Nigerian prince that is giving you millions to hold, there is a place that is not encrypted, and allows open access to their network that your email crossed over. Google by happen chance finds this area and starts caching and downloading the email and the attachment. Or the more simple situation, somebody saved this doc to something the outside world could reach, meaning Google could too.

Google isn't doing this to be evil, it is just how their service works. It has to find everything on the internet in order to index it and make searches faster. If they didn't do this, then search results would be meaningless and take forever to get anything that was even close to what you were asking for.

Once you have done your research, go into the interview with your questions and maybe even some insight that would make it look like you are very interested in the company. Trust me, if I were interviewing two people and they were similar. I'd pick the candidate that actually seem to know what it was in fact our company did. Don't be the guy just looking for a job, be the guy looking to fill a role.

Sunday, February 17, 2013

Linkedin and you!

Alright if you haven't been reading my posts on social media, you might should pay attention to this one.

So you have a Facebook? Now how would you like a version of Facebook that is simply for finding jobs? That is Linkedin. If you don't have a Linkedin, do yourself a favor and read this. Then go and create your account.

So first thing you need is a decent head shot. Linkedin is where professionals look to find employees. So depending on what job you're looking for, what you will pick for a profile picture will vary. If you are looking for an executive position, then a suit and tie is for you. If you use some picture of you drunk at a party, well expect to be spending more time drunk. As you will still be unemployed months down the road. I just use a basic headshot, nothing fancy. Think Senior photos, but more professional.

The next step is setting up a profile. You need to put your position that you are currently holding on your profile. If you are unemployed, say you are a consultant in whatever field that you want to work in. Java Consultant, .NET Consultant, Database Developer Consultant, etc. This title will come in handy shortly.

Now you have a summary section to put a basic information about yourself. Now where most people screw up is that they just transcribe their resumes onto this page. When a employer gets your resume and goes to look you up on Linkedin, they don't want to just read it over again. This is where you put your elevator speech. An elevator speech is just a short speech about what you are wanting to do and what you have done. I put a short life story and what my current goals are. I do this for two reasons. It makes your profile stand out, and it gives the person reading your profile a small glimpse into your personality. Now there is something very crucial that you need to remember when writing this out. Your job title, try to fit that in to your summaries as much as possible. This increases your weight when being searched by people for your job title.

The next step is filling out education and past work experience(if you have any) Once again here, do not just list off your resume in the summary section. Tell a story. Your resume has to be short and sweet, your Linkedin is where you put all your details. And like the general summary, put your job title in this summary as much as you can, if it relates. This will help elevate you in the search results.

There is an area for skills that you have. This can be anything that you can think of. These will be search terms. This will match your resume on skills that you have. Put down anything that you think is a good skill that you have that can help an company. Public Speaking, .NET, HTML5, CSS3, MVC, etc. These will help recruiters find you when they do an advanced search.

Now one big difference between Facebook and Linkedin is that while in Facebook you want to try and hide your account as much as possible, you need to be as open as possible on Linkedin. You are going to get tons of connection requests on Linkedin as you get your connection base built up. This is a good thing. Even if your direct connections can't directly get you a job, you better believe they are connected to someone who can. And the more connections you have, the higher you show up in a recruiters search results.

There are also groups that you can join. Some are helpful in that there are lots of connections and some of the information is helpful. Sadly, most of them are very, very, very, veeeeeeeeeerrrrrrrryyyyy spammy. I tend to steer clear of them because my inbox can't take the abuse.

Lastly, this is just a side note that I learned the hard way. You can link your twitter account to your linked in. This allows twitter posts to go on linkedin or vice versa. Make sure if you do this, then you click the checkbox that makes linkedin check for #IN hashtag in your post before putting it on your linked in. If you forget this step, you will end up retweeting Pictures of Staph infections from Joe Rogan.

Sunday, February 10, 2013

Eh, close enough?

So some of you may know that I have started going to the gym and back to martial arts. Martial arts is my favorite thing to do. If I had enough money, I would quit my job and travel the planet and train Martial arts. First stop would be Fairtex Thailand learning Muay Thai from the best. But we will save pretend time for another post. Since I love martial arts, I thought a kickboxing class would be a good way to get an hour at the gym in and not dread all 60 minutes. I was wrong.

That 60 minutes was the most painful kickboxing class I've ever done, no literally it hurt. As I write this my knees are still in pain. I have never had knee pain from martial arts ever and I've been doing this for 15 years. So was the class hard? No. Did we hit each other? No. Did the instructor say, "Fuck form and let's go for speed!' You better believe it. This was the single biggest mistake I could have made taking this class. I knew I should have walked out when She was demonstrating the moves. There were a few flags right off the bat.

1. A jab, cross, uppercut, and a hook do not look the same at all. Yet she was showing everybody the same "jab" as all four punches. YouTube them if you have never seen them.

2. A proper kick generally goes above the knees. Especially a front kick, that shit is not to be aimed at somebody's shins.

3. Bouncing always is fine to stay moving. But trying to get everybody to kick one direction while jumping back the other way is a recipe for disaster. Hell, doing any jump kicks in tennis shoes are a horrible idea. In real life Jean Claude Van Dam would have busted his god damned ankle the first time He did some spin kick while jumping in running shoes.

4. Also this instructor is having us squat on our toes and you are doing it wrong if your heels are on the ground. Nearly fell over when I heard that.

I can only imagine how many people walked out of that class thinking that they actually did something other than put an expiration date on their knees with a date still in the teens. Now how does this relate to technology?

Form is key in everything we do. If you try to slam something out just for speed sake, you can expect that there will be pain when you are through. If you don't take the time to learn the proper way to do something, you can't expect your doing it right to begin with. I can't count the times that I have had to watch hotfix 5 go out on a project only to have to pretend to be shocked that another is going to be needed. That is pain that nobody needed. The project I inherited had great forms, and yes I mean that to be plural. It was piece parted from examples found all over the internet. So the pieces were pretty good, just not the whole. The problem is that nobody stepped forward to say, 'Hey, stop!'

When writing code, deploying code, or standing up environments. Have some standards, or proper form. Save yourself countless hours or even days of pain. Doing things fast is cool, doing them right is even better. It isn't a badge of honor that you can do something in 5 minutes, if you have to do it 10 times to get it right. Or even worse, you get it done in 5 minutes and shut down and don't even check your form. This is how an application blows out its knees.

So please, check your ego at the door. Start with a lower weight before you take on the heavy shit. And lastly, for everybody's sake, get a fucking spotter to help you. It is easier to have someone help you carry something when it gets too heavy, than to pull it up off your throat once you drop it.

Monday, January 28, 2013

Ooey Gooey Chocolatey NuGet

So by a show of hands, who has used or heard of Nuget?

NuGet is a sweet package manager for Visual Studio that allows you to keep your libraries up to date on your solutions.

Chocolatey is the windows version of that tool. It will download and install any application that you need and keep it up to date for you. Sounds too easy right? Well it is even easier than that. Open up your command prompt and paste in the following;


@powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('http://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%systemdrive%\chocolatey\bin

Now press enter, and bam you have installed Chocolatey on your computer. So easy little Bennie from down the street could figure this out. Now once you have done this, now what?

Use their search and find some packages to install. http://chocolatey.org/

Here are a few commands to try. I use these to get a me through my day to day.

cinst git
cinst notepadplusplus
cinst 7zip
cinst fiddler
cinst hg

I could go all day with the commands,  just use the search and go. Save yourself hours searching for installers from here on out.

UPDATE 2/8/2013:

Type in the command CUP ALL and Chocolatey will update all of your packages automatically.

Sunday, January 6, 2013

Ignore it, it will go away.

Like a child saying they are hungry, most things can be ignored and the problem will just solve itself. This isn't always the case in IT. Oh sure, you have problems that seem to just go away. But what caused it in the first place?

Let's look at a common problem in the .NET world. Session. Session is a great tool you can use to store information your app needs to run without a cookie. The other cool thing is that sessions have a short time span of the users session, or when you say die.

Now you must be thinking, wow what could go wrong with this setup? Well session works great until you have to deal with a couple stumbling blocks, that are very very common.

Sessions have a built in timer to die set by the server but can be overridden by the application. So you could just set it to something ridiculously high like a day, but something has to store that on your server, and it is usually in memory, so that won't last very long with a busy app.(there are other ways, we will cover them below) So you set it to 20 minutes and hope for the best? The best solution that you can try is to have a timer on the page with a need more time button, but somebody will still miss that.

So your application starts to get more popular. You need to add in a few more servers and load balancing. You are set to expand right? No changes needed, well, of course that is if your user never leaves your application for any reason. So here is the scenario, you application needs to send a customer to another application, like a commonly used checkout page to keep you out of the business of worrying about PCI. What happens when you come back to your application? .Well I can tell you, session will break. Chances are you won't land on the exact same server that you left from. Then your session won't have a clue what to do, as well as any cookies will de-serialize wrong. So how do you solve this? There are a few ways, and they all work about the same, just depending on your resources you have.

So let's start with the most simple. If you have load balancing set up, then you can tell the load balancing tool to use something called Session Affinity. What this does is stores a cookie in the users browser. This cookie is read by the load balancer to let it know what server it came from, and puts it back into the right location. This is usually the simplest of solutions, well for me. Although this isn't fool proof. A user might delete their cookies, or worse not allow them. So now what?


Well session can be stored in multiple ways; in memory, on another server, or a sql server.

In memory is the most basic. No complicated set up, no need to get routes set up or permissions. Your application pool just stores that information. The problem though is that if you do any maintenance that bounces your applications app pool, well all open session just got killed. So easiest, just not the most efficient. Makes deploys tricky.

You can just point to another server and have it store your session. I have done this before, and it also works very easily. Just a simple web.config change and you are set up. The problem is that you must make sure that you have routes set up.

Now the best way to do this, but takes the most set up, is storing sessions in SQL server. You can set up a session state server using SQL server. Every time that a session is opened up, it gets placed in the database. This is nice, because then you can truly have a load balanced application environment  No longer to you need to worry about what server your users come back to. The application will always go find the user in session state server and you're good to go.


So this was a lot to just tell my fun story from last week.

Logs are showing that we have invalid and empty sessions all over our application. Well shit, we have got to track down the root of this problem. Well we thought we had session affinity turned on. Maybe not? So we turned off one of our web tiers. Still we are seeing issues in the logs. Great, well now we just gave ourselves a limp, and still have cancer. Start doing a little digging and figure out that all the session are dying in the same place. Before they leave the application they have to upload a document to the application. Well, if it takes more than 20 minutes....session is killed and no warning is given to the customer. There is your problem right there. 

Something that when I saw it in the logs, we can choose to ignore this, but we need to fix it. A timer will soon be going up as well as the 'I need more time' button. Just more fun times in a long month that I never thought would end.