It turns out that modeling the rules of Chess and Checkers in code is a pretty good way to teach and learn some programming concepts. Inspired by Chapter 2.4 "Abstracting a Domain" of "Software Design for Flexibility" by Chris Hanson and Gerald Jay Sussman, I've spent more hours than I want to admit in writing a code walkthrough of one possible solution . I might soon start looking for another…
Implementing Code-Completion for VS Code with ANTLR
How do you implement code-completion (aka "intellisense") for Visual Studio Code? and if you have an ANTLR grammar for your language: Can you take advantage it for code-completion? Below I share what I've learnt implementing code-completion (on VS Code) for SOQL (Salesforce's Object Query Language), a SQL-like language. Main Challenges I'll break the problem down into three main issues to solve:…
Workflow/BPM Systems, 2020
How do you implement (in software) a long-running "business" process? Think of any long-running process that you want to implement. A process with multiple steps, some of which might require waiting for external events or user input. A process that cannot be enclosed within the scope of a single DB transaction. Steps might fail, might need retrying, coordination, or wait for human input or for a…
Software Delivery Platforms 2019
We are starting a new "SaaS" project. After working for 5 years on a project with a rusty "enterprise" deployment solution (Weblogic!, 🙄... not my fault), I'm now evaluating options to build a modern "software delivery platform". It's almost 2020 and "devops" evolved a lot in the last few years. This post is a disorganized dump of my thoughts and findings. Here's a initial list of what I want to…
Why React?
The project team wants to move away from AngularJS (v1) for all new modules. What do we choose instead? Angular 2+ (now at version 6) is the obvious first option. This article is an attempt to explain why I prefer React instead. Busy readers may want to jump straight to the summary at the end. React Principles React is based on solid design principles , most of which I value. Here I summarize the…
Catching a Wave
I think Google Wave could become a big thing. The idea of replacing emails with feeds of conversations is not a new one. I remember brainstorming about this with friends, and here is an old article around this idea from an ex coworker. But the guys behind Wave not only turned this idea into reality, they are pushing it very far, with great ambition and with the power of Google. Wave might not only…
Career move
Today is is my last day as an Oracle employee. "Fired? Lay offs?" No, I decided to leave. "What happened?" Nothing, really. I was working with nice people, in a good environment, doing interesting work, getting a good salary. I was comfortable. "So? Why are you leaving?" A deal popped up that allows me go independent and try something different. Actually, I'm teaming up with a good friend to build…
Practical API Design
I wrote about API design guidelines before, collecting links, resources, papers and hoping someone would write a book on the subject. The wait is over! Jaroslav Toulash published a book on Practical API Design ! Take a look at the book's accompanying website for more details. I'm waiting for my copy.
Oracle eats BEA
To me, BEA was the big fish not long ago. Today, BEA is the small one in the mouth of Oracle . We are in a steep ride, jumping quickly from a start-up to becoming part of BEA and now of Oracle. I hope we can keep the "small-company" atmosphere here in our division.
Content-aware image resizing
Watch this video demonstrating some cool algorithms for resizing and cropping images. They analyse the content of the image and try to remove/add/stretch/shrink only those areas of the image that are less relevant.
Online Mind Mapping
A couple of smart friends of mine are strong advocates of mind maps , so much in fact that they had nothing better to do than develop http://wisemapping.com . It's a pretty impressive online mind-mapping tool with everything you'd expect these days from a web two-oh application: rich UI, collaboration, tagging, sharing. It's still a private beta, with many more features coming.
Moving back to Argentina
In March, I accepted a new position within BEA, to work for BEA Argentina. After more than six years in the U.S., my wife and I were thinking about moving back to Argentina. We were talking about doing so in 2008. Then, this opportunity within BEA came across. It was sooner than what we planned, but it was interesting for me professionally, and BEA was helping with all the relocation needs. So I…
Violating Java's privacy
I found myself in the need to invoke a private method of a Java class that was out of my control. I really needed it. So, I went ahead and violated the method's privacy declaration via reflection. You can (under certain circumstances) invoke methods which are declared as private using the Reflection APIs ( java.lang.reflect ). But before using reflection, I created two classes: class A { public…
History and auto-completion with rlwrap
If you ever used Oracle's sqlplus you'd agree that it provides an arcane command-line interface. Being a textmode command-line tool is not what makes it arcane though. It's that it doesn't offer auto-completion or a command history. If you made a small mistake when typing a long statement, you would have to re-enter it all over again. Most modern command-line tools (including MySQL and…
On API Design Guidelines
Update: Good news! Jaroslav Toulash emailed me that he published a book on Practical API Design !!! Looks like Brian McAllister may be preparing a talk on Designing Elegant APIs . I've been very interested in good API design for a long time. But I could never find a single book on the subject. Many design and programming books provide good advice and guidelines that are essential for designing…
Variable Severity Logging
Most software products and logging frameworks produce entries in their log files with different severity levels (say, from Debug to Severe). Then, you can configure which level of messages you want the application to log. At development time, you may want all messages to be logged. But once in production, you normally configure things so that only Warning and higher messages get logged (for…
AntDoclet 1.1
I just released a new version of AntDoclet . No major changes. Now the comments of inherited methods are properly extracted from the parent class comments. Thanks to Daniel Lindner for this fix.
On What BPM Promises
Tom Baeyens (from jBPM) wrote an interesting article about the over-promises of some BPMS (Business Process Management System) vendors. His dicussion addresses two points: BPM vendors often overpromise by hinting that BPM tools can unify analysis with implementation Lack of integration between processes and plain general purpose programming language From my experience with Fuego (now BEA AquaLogic…
Real-world SOA at Amazon
A great interview with Amazon's CTO Werner Vogels appeared in ACM's Queue magazine. A must read if you care about how to run a modern IT organization. The SOA acronym has been abused to the point of becoming a dirty buzzword for many. The interview shows how Amazon applies service-orientation concepts with a very pragmatic approach. WV: ...The services model has been a key enabler in creating…
Project-Oriented IT
Over the last years I had the opportunity to work on projects for really big companies. My initial observations led me to think that the bigger the company the more inefficient its IT operations are. Economies of scale seem to work against Information Technology and software: the bigger the company the more inefficient, bureaucratic and slower it gets. But it would be too simplistic to say that…
BEA Systems acquires Fuego
Old news: BEA Systems acquired Fuego Inc. . Starting March 1st, virtually all Fuego employees (including myself) became BEA employees. There are few organizational changes, which helps minimize disruptions on our productivity and service. I've been with Fuego since its early days. I started working for Fuego's ancestor company, InterSoft , as a Java/C++ developer in 1997. I have different feelings…
Airport "Security" Jokes
I'm at the Saint Louis International airport (STL), waiting to board on my flight back to Dallas. I have just experienced another stupidity of the airport (in)security procedures. This post is not about software, but software security and "physical" security depend on each other. It's an American Airlines flight. You can usually do the check-in procedure online, and print the boarding-pass…
AntDoclet
After nearly two years of procrastination, I finally decided to spend some time on wrapping things up and putting AntDoclet online for public consumption. AntDoclet is a little tool for documenting Ant Tasks. It automatically generates HTML and LaTeX documentation from the source code of your Tasks. I wrote it initially in January 2004, for documenting the Ant tasks provided with the FuegoBPM…
My Job Went to India...
If you work as a software developer for a living, I recommend you get a copy of "My Job Went to India" . Ignore the curious title and funny cover. It's about planning your career and making yourself a more valuable developer. I read it right after "The World is Flat" (by the way, a fascinating description of today's globalized economics), and it was a good 1-2 punch. Full of great advice.…
Quality of Experience
I'm surely stating the obvious here (I hope!), but what seems obvious for some people is not so for others. Work Experience should not be expressed in years . There's a quality component to it that is more important than quantity . Some people learn very little over several years of "experience", while others learn and grow a lot in a fraction of the time. The amount of experience is still…
Version Control Systems and Open Source
If you haven't looked at the available Version Control Systems lately, you'd better look again. About 5 years ago, CVS was pretty much the only open source Version Control System in use, and it's still very popular. But in the last few years, a surprising number of new and really good open source version control systems came to life. Like most open source projects, their authors started them to…
Graphical Thread Dumps
I am surprised by the high number of Java developers I meet that do not know what a Java Thread Dump is or how to generate one. I find it a very powerful tool, and it is always available as part of the JVM. I haven't played much with Java 5 yet, but it comes with jstack , a new tool that makes it easier to generate thread dumps. Earlier this year, I was working on a load test for for a well-known…
AT&T Text to Speech
A co-worker pointed me to AT&T Natural Voices , a Text-to-Speech research project from AT&T. I tried the online demo and I'm really impressed. It's been a long while since I last tried a TTS system, so may be I'm just late to the party... but this one produces very natural speech. I tried a couple of English and Spanish voices, and all seem very real. I knew about the Festival project, which…
Baby Pilar is here
This is old news already, and although it's not about Software, it's definitely about Development :-) I'm happy to share that Pilar , my second daughter, was born last a couple of weeks ahead of schedule --and on budget ;-). She has jaundice , so she is under photo-therapy. Fortunately, this can be done at home, and should only last a few days.
Micro and Blind Optimizations
Yesterday, a good friend of mine and ex-coworker contacted to me to share his frustration. (he hates to be called "Polino", so I won't.. doh! ) He finished a software solution for a customer, and now an expert is reviewing his Java code. The expert code reviewer insists on small performance optimizations, but he is way off target. He wants to micro-optimize, and to do it blindly. For example, he…
Oracle DB Express
I just realized about an interesting move from Oracle. They released a Beta version of their new Oracle Database 10g Express Edition . This Express edition is free of charge. It is free not only for production use, but also for distribution. These are the limitations it has: It restricts itself to use only one CPU Only one server and database instance (SID) per installation Database size limit of…
Errata for "Holub on Patterns"
Months ago, I was looking for a book on Design Patterns. I already own the great classic GoF and a few more, but I was looking for a more practical, real-world exposition of the classic Patterns. I wanted a book I could recommend to new developers, so they could really learn how to apply the concepts. I came across Holub On Patterns . I liked it, but I was disappointed with the editorial quality…