DDOS attacks explained

If you are a gamer (and chances are that if you are reading this post, you are), you’ve likely heard of the Lizard Squad attacks on PSN and XBL. Kotaku has a great post explaining what DDOS attacks are and why they’re so difficult to prevent. As I was fairly n00bish on the matter, I found the article tremendously helpful. Perhaps you will too?

Only the Browns…

… would need to address that the GM and coach have not been fired in a press conference.

Overall, though, I’m pleased with the season. The Browns showed a lot of toughness, and there are some excellent pieces in place to take it to the next level. We need to go d-line in the draft, pick up some offensive line depth, maybe a receiver or two. Let Manziel and Shaw (who played okay) fight it out in training camp.

If Johnny Manziel doesn’t mature quickly, he’s going to be in a lot of trouble. Replacing Hoyer was the right move, no question. I’d even say don’t bring Hoyer back; I don’t care if he’s a local guy, he’s too limited to take a wide open offense to the next level. Watching the Colts game was a nightmare.

I’ve mixed feelings about the way the veterans are calling out the youngsters (specifically, Manziel, Gilbert, and Gordon). When it was just Dansby and Whitner, I ignored it; they were free agents who signed with Cleveland. NFL veterans, yes, but not Browns veterans. Then Joe Thomas joined in, and if Joe Thomas said 2+2=5, well then, math better fuckin’ get it right. I think Gilbert will straighten out.

Gordon’s a whole other ball of wax. The roster dickery — suspending him for missing a practice… which just so happens to screw him out of unrestricted free agency off his rookie contract at the end of 2015 — probably poisoned the well for him staying with the team, but to be honest, nothing I saw with him this season impressed me. I figure it might motivate him to play his ass off next season, so I’m okay with it.

Manziel gets an incomplete for this season. Next season is another question.

Browns need to re-sign Jordan Cameron and Buster Skrine, especially Cameron. The only receiver I saw have the slightest bit of chemistry with Johnny was Cameron. Skrine proved he’s a great DB, more than capable of starting opposite Joe Haden.

There’s promise and potential here. Let’s build on it for 2015!

Identity Integers Using ASP.Net Identity On MVC 5

ASP.Net MVC 5 introduced a new identity model, ASP.Net Identity.  Brock Allen has a blow-by-blow analysis of the product, and that’s pretty fantastic reading.  What I was really interested in, however, was an understanding of how to change the database tables used in the identity model.

By default, ASP.Net Identity creates a five tables, including dbo.AspNetUsers and dbo.AspNetUserRoles.  Ignoring the “you probably shouldn’t have table names plural because tables describe singular entities” bit, I looked at the way this information is stored and noticed that UserId is stored as NVARCHAR(128) and is a clustered primary key.  Even better, once you create an account, the NVARCHAR(128) actually holds a GUID.

Let’s take a moment to enumerate the problems with this.

  1. Define your data types appropriately.  If you are going to store a GUID, create a UNIQUEIDENTIFIER data type.  The reason you want to do this is that a UNIQUEIDENTIFIER takes up 16 bytes, whereas storing the GUID as a string takes up either 72 bytes (36 characters on an NVARCHAR table without compression).  With a large enough user base, this can make a difference.
  2. Clustered indexes should be narrow, unique, static, and ever-increasing (NUSE).  GUIDs stored as 72-byte strings are definitely not narrow, nor are they ever-increasing.
  3. Entity Framework understands the concept of integers quite well and handles identity integers with no problem.  Dropping back to using strings for these seems a bit string, especially when the AspNetUserClaims table uses an identity integer.  If you’ve got it going for one of the five tables, why not take care of the other four?

I will give Hao Kung and the ASP.Net Identity team credit:  they understood the problem and worked on solutions.  Hao Kung in particular has been very active on forums helping people out, and that deserves respect.

Fortunately, you can change this default behavior.  It’s a little complex, but Tom FitzMacken has a fantastic step-by-step guide on how to use integer values with ASP.Net Identity.  After following these steps, I’m back to being a (relatively) happy camper.

More Catallaxy Services Updates

I’ve been pretty busy with the Catallaxy Services website.  Since my last post on the topic, I’ve implemented steps 2, 3, and 4 of my master plan for two of my presentations.  Those two presentations are Much Ado About Hadoop and APPLY Yourself.

Step 2:  Add a “Links and Further Information” section to each presentation.  My presentations are generally meant to scratch the surface on a topic and having a section people can go to after my talk will hopefully help them solidify their knowledge on the topic.  I also want to give credit to anybody whose code I shamelessly stole adapted to make my point.

Step 3:  Move code to Github.  I now have a Github repo for my APPLY Yourself code; I already had one for my HDInsight code.  My Github repository list has always been a bit sad—I had my Index Comparer code up and pretty much nothing else.  Considering that I have a lot of (reasonably) well-crafted code sitting in ZIP files on my web server, it makes sense to move that stuff up to Github.

Step 4:  Update the slides.  First, I’ve decided to stretch the screen a bit with my presentations.  Up until now, I’ve left a huge swath of a wide-screen monitor as empty space, and even on most projectors I have used, I had pretty wide margins.  This isn’t always bad, but code snippets are a bit more difficult to walk through when you have to scroll left and right.  The presentations are now at 90% of the total width.

Second, I’m going back through each talk with a critical eye, fixing formatting and spelling errors and removing bits which don’t make sense or are unnecessary.  This is an iterative process, but until now, I’ve basically treated the slides as “do once and then forget.”  Instead, I’d like to update these presentations every once in a while—especially with something like In-Memory OLTP, where there’s a lot more information available today than back when I originally wrote the presentation.

The last big thing that I did was add a consistent closing slide (Hadoop version here) which says two things.  The first thing I want is, “To learn more, go here” and has a quick link to my presentation with links, code, and information.  The second thing is, “And for help, contact me” and my e-mail address and Twitter handle.  This came straight from a Brent Ozar post on how to end talks and it’s so glaringly obvious that I’m surprised I never thought of it.  This is the slide that I’ll keep up through Q&A in order to give people time to take a photo, plug in the URL, or make a note for later.

With these four steps in place, I think the Catallaxy Services site looks a lot nicer and people get a better idea of what’s available and just how much time I waste spend on these things.  I still have a slew of presentations to work through, but with this pattern in place, my hope is that things will proceed smoothly.

An early contender for dumbest HOF ballot

Meet Garry Brown, “Special to the Republican.” He is your one stop shop for all of your Venus the golden retriever news! Does Venus like cheesecake? Click to find out!

Oh, and he somehow has an HOF ballot, which is:

News item: Dec. 17 deadline set for Baseball Hall of Fame ballots. I voted for Jeff Bagwell, Craig Biggio, Edgar Martinez, Pedro Martinez, Mike Piazza and Tim Raines.

On the surface, that’s not a horrifically stupid ballot except WHAT THE HELL WHERE IS RANDY JOHNSON?!

Do I need to make the Unit’s case for you? Okay, maybe I do. He’s got 303 wins. #2 all time in strikeouts. 5 Cy Youngs. A perfect game. Another no-hitter on top of that. JAWS calls him the 9th best starter of all time, between Lefty Grove and Greg Maddux. Above Maddux, I might add.  He’s 9th in WAR. The only starter anywhere near him on the leaderboards that isn’t in the Hall of Fame is Roger Clemens, who should be.

“Oh, but maybe he thought the Unit was a slam dunk so he left him off in favor of somebody else?” Yes. He left him off for four blank spots on his ballot. Honestly, even if Randy Johnson sodomized, murdered and ate his entire family, I’m not sure that justifies leaving him off the ballot.

Your move, Larry Rocca. Can you outstupid this ballot?

What I’m Reading: Pro Git

I started reading the first edition of Pro Git, which was released in 2006.  Then, after grabbing the link for this blog post, I found out that they put out a revised version of the book this year.  Now I’m picking up on that new edition.

I have to admit that I’m not a tremendous fan of Git.  If I had to choose, I’d pick Mercurial over Git; nevertheless, most people don’t think this way, and so I’ve decided to learn Git to keep up.  This book has given me a nice start on that goal, and given that the eBook is totally free, there’s no reason not to check it out.  If you want to get a paperback copy, you’re in luck:  the second edition is out today.