Skip to main content

Posts

Showing posts from January, 2012

REST semi-realtime transactions

The freelance pattern implemented with TornadoWeb and ZeroMQ.
I recently implemented one of the broker reliable patterns as described by the ZeroMQ guide. It's something very similar to beanstalkd's but left to the reader to implement. This in itself is not a bad thing but it is more code to design, write and test; and had you the budget to hire these guys directly you would get the best broker money could buy. But how reliable is this model. Really?

I'm not a big fan of the broker model. It's a lot of extra code to write for the broker itself. It's also a single point of failure. And then there is the error handling as the client and worker negotiation the status of a transaction only to renegotiate it when the broker fails. And then there are all those places where transactions can queue up and all that code that is written that does not need to be. (the crux of this article)

In a brokerless model each client connects to each server (many to many) and in a tradition…

'take me off the list'

A couple years ago there was a "do not call list". Well that did not work.  Every new and fly by night company ignores those laws anyway and by the time law enforcement or the attorney general investigates they are long gone. So what is a person to do, specially when they call several times a day, when the babies are sleeping or when my wife and I are sleeping?

Also, these new phone systems are pretty smart. Their voice recognition is really good and their artificial intelligence or workflow is even better.  I've been fooled 2 or 3 times already but I think I have the magic now.

Hmmm... I tried a few things...

Talking and talking and talking.... it did not work, the machine has more patience than I do. - FAIL
Every swear word I could think of... the machine just ignores me and asks another question like Eliza did. - FAIL
Answering in the negative to every question... but either it would keep trying to sell me something or I would receive another call in a day or two. - FAIL
An…

Proper use of a MQ designs

Bus, as a term referring to hardware/software components has been around long enough that many noobs have no idea of it's origin or how to use it properly or when to use it.

In modern computing the bus has it's origin in hardware. It was not always like that. Engineers went back and forth between direct connected components and bus architecture until the 1980s when IBM introduced BusMaster architecture in the PS/2. Things remained stagnant for a few years until there was yet another resurgence of direct connected hardware.

Memory I/O performance was increased by moving cache directly into the CPU, connecting the CPU to RAM via DMA type access.1

Disk I/O performance was increased when the disk controllers were allowed to talk directly to the systems RAM.

So it's no wonder now that MQs are becoming easier to deploy that they are becoming the connective tissue between components rather than direct connections or API calls.

Old school programmers remember MQs like IBM's very we…

Dynamic Languages and PCI-DSS

Some security experts, including myself, thought that implementing financial software using dynamic languages would create a security threat for the "company" or the account holder. However, as I sit here this morning contemplating an open source payment platform delivery system I realize that it's a silly hypothesis.

Forgoing all of the traditional attack/fraud vectors I'm thinking about the code. The PCI-DSS covers the production hardware and database(s) but it also covers the developer's computers, build machines, staging and QA, and the code repository. The "processor" is expected to treat the securely and equally. (this highest priority goes to the encryption keys and devices).

So if an attacker can get to any of these systems and inject code then you really have a bigger problem than whether the code was Python, perl or Ruby. Of course since Java can be executed anywhere then it can also be compiled anywhere. Reverse engineering Java and then recomp…

How to find programmers

Inc is running an article that finally makes sense of internet hiring. The leadership at Pulse, the company named in the article, told it's programmers to start blogging. As a result they have started attracting attention from all corners. This certainly makes more sense than speed dating, code scraping, social ranking, etc... And of course it helps to have Inc do a story on your business.

First you are attracting people who are interested in the company and the work being done. Second you might be opening a dialog with the candidate before they are actually a candidate via blog comments. And finally, it likely is not going to cost you anything more than existing methods and it's certainly less than professional recruiting services.

Pulse get's a +1 from me.

Hirelite - speed dating for jobs

Hirelite is another one of those last minute entries in the fly by night job site of the day websites. There is no doubt that the likes of Careerbuilder, Monster and TopJobs have lost their luster. But this is starting to look like a clown car at the circus. Just how many of these so called job search companies are there?

That was rhetorical. Don't answer it.

While it's true that there is a social aspect to the professional hiring process it's certainly not akin to dating. The Bachelor is on TV right now and I do not see a resemblance to the hiring process there. When you date someone it's usually because there is an intent on a level of permanency, in an employment situation you're going in a different vector. In the 1980s it was commonplace to ask "where do you see yourself in 5 years".

Anyway, as an employer I have a responsibility to find the best candidates though responsible means. As an employee I want to be hire by companies that aren't trendy an…

Hirewolf makes no excuses

Hirewolf is the latest in a series of employment service providers that promise to filter and test potential candidates in the hopes of getting a "golden ticket" to employment. (recently I wrote about GitHire)

What makes these guys different is that they make no excuses for the decision making process. They are going to decide the candidates fate by
"We will choose whichever project strikes us as most beneficial to the open source community."
This is probably the most shameless description of the 1% solution that I've ever heard or read. Just in case I've never said it... I do not want to be scrutinized by any these services. These companies are not driven by the same rules that HR departments of proper companies which are prohibited from disclosing anything about your performance. All they can say is the dates of employment. And maybe your title.

So the fact that both of these companies are going to scrub your social identity and produce a score for the perspe…

Domain Specific Framework

I'm grateful that Wikipedia does not have a reference to something called a Domain Specific Framework. So I get to define it here.
A Domain Specific Framework (DSF) is a set of hardware, languages, libraries, and best practices that make up a software development environment for a programmer(s) for implementing applications larger than "hello world" and of median complexity that does not require too much specialization or edge case libraries.
A perfect example of an ideal DSF might be Xcode for iOS application development. What makes it ideal is that it is self-contained and has most everything an iOS developer is going to need to implement, test and deploy an application for an iOS device. A second good example would be JEE (fka J2EE). (Grails, Rails and Django are good examples too)

Where I typically get derailed is when super heroes start with a base programming language, maybe they implemented version 1.0 of the application,  and then start stapling on libraries in orde…

Forced Pomodoro

I was in the middle of writing and testing my CRUD-fest article when it occurred to me that the evaluation versions of IntelliJ, PyCharm and RubyMine might actually be better than the paid-for version. Granted it's not English to use the eval version and not pay for it but an American might split hairs a little while longer.

For the record I am preparing a purchase order but I might continue to use the eval version. That's because the eval version pops up with a warning every 30 minutes. And every 30 minutes you have to restart the IDE. Now I'm not a fan of IDEs because they hide so much from you in terms of the full stack, however, they are pretty good when it comes to productivity when you want to concentrate on code and not framework. I'm also not a big fan of using Java or the JVM unless it's packaged with the IDE; but that's off topic.

The fact that I have to restart the IDE every 30 minutes means I have a better concept of time. I have a moment to catch my …

CRUD-fest : grails, rails, django shootout

The mission is to deploy a CRUD implementation in all three frameworks by reverse engineering my schema from an existing Postgres Database which I will construct with raw SQL. Later I would like to add some data to the tables so let's see how it handles some ETL (export transform load) in the form of a CSV file into some REST calls that I'd implement or some other type of messaging.

What I did not do! I think O'Reilly has the most comprehensive map of the history of all computer programming languages, however, GitHub has a list of languages that would seem to be current or relevant. Granted that some of this, to be effective, would mean investigating popular frameworks within the domain of languages. Well of that semi-complete list from GitHub I picked out this set: php, go, lua, haskell, erlang, scala, clojure, perl, javascript, rhino, nodejs, iOS, Objective-C, C++, C, Pascal, Pro-SQL, CoffeeScript, OCaml, Scheme, tcl, Smalltalk, Visual Basic. I think they are the most rel…

My Ruby Installation

[update 2012-01-22]A new project is underway. 'crud-fest-rb' it's part of a new story I'm writing. I just tried to launch a new rails project and I was blocked because I was missing some basic gems. They are now in the list below. The names are: jquery-rails, coffee-rails, sass-rails, uglifier. My empty RubyMine/rails-3.2 project is now running. The CRUD comes next.

[update 2012-01-21] I just published this article a few hours ago and I realized that I forgot some stuff. I forgot to mention that I need Twitter's Bootstrap project here too. So when I start working on my first project I'll need to import Bootstrap. I might have missed a few more things... I have been following python and many of the python libs longer than ruby so that makes sense. If you have any recommendations send them on. PS: TextMate is getting an update soon but I think I'm going to install and use RubyMine from jetbrains.com. It's like PyCharm, also from jetbrains.com but for Ruby …

Netty 3.3.0 was release with some dependencies

I'd like to try some netty code whether it's standalone or connected to Apache:Camel but when I downloaded the source I saw that I needed Maven2 in order to build it. So I started the install process for Maven2...

Yikes! I have no idea what licensing constraints I've entered into; why maven needs rhino and a large number of other libs.

Back in the day when Object Oriented programing was becoming popular, around 1983-ish, people gravitated to the private/protected/public guarding of methods and data. I'm not sure why that was but I can guess it's probably ego. There was a point to it when code or libraries were distributed in binary only form but today open source has all but eliminated secret sauce and we typically use naming to identify usage with documented examples and recommendation.

That said, the super-dumptruck needs to be replaced with a backpack approach. This means that there is a more granular approach to installing dependencies and even interdependencies b…

Flask, Pystache and Bootstrap

[Update 2012-05-14] RDO pointed out that there were some changes in pystache. The first and foremost is that they changed the API structure entirely. While I might not have actually implemented that best practices as there are a number of ways to accomplish the same thing. I was more interested in staying try to the initial project structure.  So if you read the pystache Renderer class you'll probably see everything you need. And to round the changes out I found a few bugs in the MANIFEST.in and __init__.py that have been corrected here. This code runs although it's not loading any of the images and some of the css... as I have not updated the html to work the way it should. But it's easy enough for the reader now that the rest is working. (One final note, edit the fluid.html file and change ../assets/ to /static/) 

I'm using flask, pystache and bootstrap in order to build a fast prototype. I've already written a little about this but the text was getting long in th…

Bootstrapping your next project with Bootstrap.

Bootstrap is a nice little web app starter framework released by the kind folks at Twitter. I'm not sure why they did it but I suppose that does not matter much. It's nice, open, and fun.

For the purpose of this bootstrap project, which I'm calling freestrap, I'm going to select some technology that I previously installed in a recent article. The stack will be:

python
tornadoweb or maybe flask
beanstalkd
bootstrap and it's deps
modern-package-template
mustache

I was going to implement a database layer too but I think that will be postponed until the next project is fully realized.

At this point everything is already installed.
You need to navigate to your project directory.  I like to create a git or hg folder immediately in my home.

cd ${HOME}
mkdir -p hg


then you'll need to create the project folder ('freestrap') with the modern packager.

cd ${HOME}/hg
paster create -t modern_package freestrap


And you can run the application by typing
freestrap
if you execute the '…

Redis EVAL() in 2.6.0

Our friends on the Redis commit team are proponents of the Ruby language when not coding in Lua, tcl or C. And so the EVAL() function example code is written Ruby. That's all fine and well... but what about <my_lang>?.

So I spent all of 30 seconds on a python version of the same code. Chances are pretty good that the code will work. I do not know for certain because 2.6.0 is not ready yet and I'm not in a position to install unstable yet. Of course I could run it in userspace but that's another topic.
import redis
r = redis.Redis()
RandomPushScript = """
local i = tonumber(ARGV[1])
while (i > 0) do
res = redis.call('lpush',KEYS[1],math.random())
i = i-1
end
return res
"""
r.delete('mylist')
print r.eval(RandomPushScript,1,'mylist',10)
# __END__
One of the crappy things about python is the indents. It makes copy/paste to a place like wordpress semi-functional.

I Want A Skype Replacement

I'm not happy with Skype. There I said it. But like many things in life I do not have much of a choice. The first time I used Skype I was in Barcelona Spain on my honeymoon and I needed to call our family to let them know we arrived before we headed out.

So it cost me $4 for the hotel wifi, and $5 for one day of Skype... and I was able to make one phone call that was interrupted 5 times by either bad wifi or Skype service. I'll never know. I should have used my cell phone thanks to hindsight.

Now I use Google Voice for as much as I can. There are still a few challenges there. It's decent quality but in order to keep the cellphone minutes down I'm forced to use Google Talk via the browser because they do not have a wifi client for the iPhone.

What I'd really like, now, is a Skype online number.  That's a number that someone else, presumably landline or mobile, in order to reach me wherever my Skype connection is active. The problem is I cannot tell what the pricing…

More! Your Want Some More?

The Hungry Programmer was an interesting article. Unfortunately the comments have been closed so I could not reply directly... While he talks about the quality of food and relates it to programmers. I think he forgot one important analogy.

If you buy pre washed green beans in a bag. While they cost more... they are simpler to cook, simpler to eat, have a predictable shelf life, and if you belong to the school of shopping daily to reduce waste then you've done that too as consumption is well known.

So after all that. It's ok to pay more for good programmers who write good code.

GitHire - novel but nothing new

I'm getting tired of this subject. GitHire is trying to get employers and candidates that they have a better way. But for one, candidates don't care how GitHire works because it's the employer that's going to make the call and the employer... well let's just hope they are not naive enough to spend $500.

GitHire uses GitHub's APIs. This gives them access to all sorts of project data. But it's all meaningless.

there are a million programmers but they program JavaScript and Ruby (see http://github.com/languages/). You better not be looking for an erlang programmer.
besides, what about all the exceptional programmers that use BitBucket or their projects are private or maybe they don't use any DVCS.
just how do they determine "exceptional"? Lines of Code, Check-ins ... we talked about these metrics and gaming the system in CS101.
code reviews? But wait, they said they don't do code reviews. The fact that they got your creds from GitHub means that th…

SOA and Transaction Processing

I really like the idea of client/server and distributed processing. Cloud computing with all of it's distributed and cooperative nodes around the planet is really cool. SOA might almost be cooler.

Yet another one of my mentors once said:
"I spend the first third of my career building monolithic applications and the second third converting them to client/server applications so it's no wonder that my last third was spent converting them back". --Sagg
The fact of the matter is that there are constant tradeoffs as we convert from one system to the next. And while hybrids reduce the cost somewhat they are incomplete as far as swinging fully one way or the other... and they offer their own problems.

SOA for Dummies draws a nice picture of what a typical SOA system looks like.



Once you get past the infrastructure requirements like the hundreds, possibly thousands, of APIs available in the ESB implementations like Apache Camel, ActiveMQ and JMS. Then you have to manage the many c…

Getting things done, read, or a reply

I'm not a productivity guru but in a recent conversation with a client of mine we started to hash out why his vendor was not responding to more than a few of the questions posited. In some sample emails there would be several one sentence questions and in others there might be multi paragraph descriptions before any number of questions. In the end we always seem to defer to a conference call. (I really wanted to get things going in an email because there was logical sense to the discussion.)

Then there is the resume. Recent studies (not sited) suggest that a one-pager is the best way to increase the likelihood that your resume will be read. I have both a one-pager and a multi-pager. With my history it seemed to me that a narrative approach rather than the usual boring: assignments, roles, responsibilities, languages, frameworks, etc... would make sense. And besides it no longer fits.

When I worked for NaBanco, later First Data, (circa 1994) we had a "one-pager" to describe…

Job Search

So you want to search for a new job? The first thing you must do is update your resume. You also need to take a good look at your career and decide if that is where you want to continue to work and just how far from center you are willing to go. You then need to ask yourself about relocation, benefits, and compensation. Once you have those things in perspective you are ready for the search.

Unfortunately the search breaks down into several paths. a) the general job board, b) the specific skill job board, and the ever present c) recruiter.

I'm not going to discuss (c) except to say; I like recruiters for a lot of good reasons but the landscape has changed a lot in recent years. Management in most recruiting companies use their most senior staff to work with the client(employer) and the the most junior work with the resource. The process is always the same. And unless youve studied the process you wont know what I mean so lets move on.

a) the general job board includes; FLUID - Florida…

Interview Problems *sigh*

[update 2012-01-10] Braintree does it too. While they list some attributes that they look for in their code reviews it's subjective. The interpretation of the results do not appear to be based on any science but probably intuition.

[update 2012-01-08] ** additional note at the end.

[update 2012-01-08] I was in such a hurry to get out of the house today that I forgot to add this little tidbit. [Top software dev job boards ~ Max Masnick http://bit.ly/wqcEuv]. One of the interesting services that Montana links to is something called InterviewStreet. I have no idea what it really is but Montana says "connects you with jobs if you can solve programming problems on their website." So after you spend all of that time customizing your resume, cover letter, making sure that your GitHub contributions are top notch... you now have to take a quiz so that maybe someone is going to notice you and give you a phone screen. And just maybe if you know whether to wear boxers or briefs you mi…

Response: startup coding challenges

Startup coding challenges are meaningless. They are a way for the "haves" to show they are superior to the "have-nots". In very many ways it's legalized cyber-bullying. [If you've ever watched a show like big brother or Survivor; you peer(s) are not your friends. The workplace is not a utopia and therefore your peers are not your friends either.]In fact So under all but the rarest of circumstances should a prospective employee be interviewed by a peer because:

if the manager does not take the peer's advice and hires the candidate anyway; the peer will feel slighted
unless the peer is trained what to look for in the interview he/she will likely game system so that lesser candidates are hired
the interview and hiring process is [already] subjective. The coding challenge is very subjective; disguised as objective. "solve the challenge and get the job and get the job" is just not the way it is... "solve the problem using my favorite language wit…

Cloud Storage Options

I have been considering my cloud storage options and they all lack serious consideration. The best seems to be the best of the worst. I've made a spreadsheet of the features that are important to me and my situation. They are:

Backup?
Sync?
Secure Share?
Mobile?
Net Drive?
Cross Platform?
Free is more of a curiosity for testing?
First Pay is the cost of first entry?
And whatever else I've learned that is a deal breaker.

The spreadsheet below is incomplete only because they simply do not stack up. There are so many other considerations... speed, server location, trust, brand awareness, security, perceived benefit and service.



Given the state of my environment, which is a hybrid family/SOHO setup, I like/prefer CrashPlan and DropBox. However, I'm certain that things are going to change.  These companies need growth which is only going to increase with features and service levels. Of course brand awareness like Google means a lot.

PS: Google storage should be on the list but it's not…

New Years Resolution - Reduction

I've decided that the word that will describe 2012 is reduction. In that spirit I have noticed that I have a number of articles in my instapaper queue that need to be read. Once they are read I will do my level best to reduce the number of articles that I actually collect. So if I'm scanning my news feed the criteria for a read later is going to be more strict. But let's review the stories so far.

reducing code nesting: We've been talking about this since CS101.
SQL to MongoDB mapping: I really like mongo but the argument for SQL is too strong. There is no need for an end user mapper... just implement SQL.
programming competitions: really?
Assembly Language Hello World: It's not much bigger than a DOS assembler version of the same. It's not the assembler that I grew up on.
DropBox Automator: only if you do not care who reads everything in your account.
scripting the un-internet: history repeats itself is not the same as a loop.
Digital Wallets: They've been talkin…