Site Sponsors:
Technology Tips for 2013 
I was asked to come up with a handfull of trendy tips for IT Professionals.

Here is the short list.



--- Nagy's Top Tips for 2013 ---

“The realm of continuous integration is putting a great deal of pressure on software developers to do a far better job on real-time testing & diagnostics. Moles, PEX, Delegate, and System-style Integration interfaces & testing strategies must rapidly fill the void between an NUnit Testing mindset, and the creation of a more pluggable, production-quality, stimulation / simulation regression test ability for our applications.”

“MYBATIS and Hibernate are simply must-have technologies for any large corporate undertaking. The ability to quickly represent database schema in source code (Hibernate the choice of many for exact tabular-object CRUD), or efficiently re-factor database schema (MyBATIS is often the choice there) are surely two of the hottest topics in the corporate software-developer world today.”

“The economic realities of our time are clearly favoring software developers who are capable of doing more than writing code. -Becoming familiar with design patterns, UML, as well as tuning our production-quality solutions are the key skills that will help ensure that our resume stands out in a crowd.”

“After reviewing technologies like Hadoop, one will discover many opportunities for performance improvement. While a revolutionary step toward treating massive hardware installations as a single monolithic computing resource, today's software developers should be keeping a closer eye on the more obvious ways to let Big Data task big resources a lot more effectively.”

“Service Orientation is another huge opportunity for software developers. In addition to the technical underpinnings of 'bottom-up' discussions over REST, SOAP, and / or BEST, the real call of duty is to discover why IT is only half of what any good IT Alignment process is all about.”

“With one exception, our modern Enterprise Service Bus is simply a restatement of an old, time-proven, transaction-processing system: Today, often lacking the efficiencies of bit-level encoding, iuo-architecture, and packet-level obfuscation, modern software developers should be paying far more attention to making our data exchanges far more efficient, as well as secure.”

“It is no longer advisable to be selecting technologies simply because they make life easier for developers. In a time when computing power is no longer increasing as fast as we have become accustomed, we may yet have to quickly return to the day when a developer knew enough about microprocessors, operating systems, networking, memory, and bottom-line technology justifications so as to be able to prove that we have selected the right tool, for the right job.”

“When we see Java projects like Hadoop re-writing their own performance-critical routines, we should be interested in discovering how we might do the same. Why? -Because probably sooner - rather than later - we too might reasonably be expected to know how to make our favorite technology natively-faster, resource-smaller, and consequently a better choice for our own projects. Having a common linker, as well as a native-code-creation option would be a good place to start.”

“Just as the loss of traditional occidental values made unlocked car doors and hitchhiking a thing of the past, so too is the rise of digital skulduggery threatening the open and free exchange of standards, ideas, and software. From international copyright & intellectual property issues, to the proper use of asset & license management tools, techniques, and best practices, the software developer of today should be keenly interested in becoming far better versed in the growing legal & regulatory consequences of practicing our trade.”

“Virtualization may be nothing new, but new software developers should be a lot more comfortable with discussing cloud, networking, SAN, and other on-demand software support alternatives, strategies, and concepts. For reason of license validation, if not outright image creation, the ability to deliver and test stand-alone, turn-key applications on-demand is becoming the norm in our modern, corporate elastic-cloud, world.”

[ view entry ] ( 3849 views )   |  permalink  |  related link
Drawing Points On A Line 
Certainly the idea of drawing a simple line is well supported by just about every graphical framework. What is less sure is the ability to enumerate through a set of points so as to choose just which points we are interested in.

LineDDA For Java

While the technique pre-dates Microsoft Windows, the idea of using a Digital Differential Analyzer (DDA) might seem easy enough to write. Once we account for slope management however, the algorithm can get a little more complex:

public static boolean Enumerate(int x1, int y1, int x2, int y2, int step, PointCallback result) {
if (result == null) {
return false;
if (step == 0) {
step = 1; // avoid "divide by zero" possibility
if ((x1 * y1) > x2 * y2) {
int h = x1;
x1 = x2;
x2 = h;
h = y1;
y1 = y2;
y2 = h;
int base = (x2 - x1);
if (base == 0) {
base = 1; // avoid "divide by zero" possibility
double m = (double) (y2 - y1) / base;
double y = (double) y1;

if(x1 == x2) {
// No Slope
int iy;
while (y <= y2) {
if (y % step == 0) {
iy = (int) Math.round(y);
result.onPoint(x1, iy);
return true;

if (x1 > x2) {
// Negative Slope
y = (double) y2;
int iy;
for (int x = x2; x <= x1; x++) {
if (x % step == 0) {
iy = (int) Math.round(y);
result.onPoint(x, iy);
y += m;
} else {
// Positive & zero Slope
int iy;
for (int x = x1; x <= x2; x++) {
if (x % step == 0) {
iy = (int) Math.round(y);
result.onPoint(x, iy);
y += m;

return true;

In the above, we have cobbled together a point enumerator. One that also has a 'step' capability:

Note that testing has verified the support of positive slope, negative slope, zero slope, no slope, as well as the need for point inversion.

Graphics gr = jpDrawing.getGraphics();
gr.drawLine(300, 15, 300, 200);
boolean br = false;

LineDDA.PointPlotter plotter = new PointPlotter(gr, 5, 1);

// Slope Tesitng
LineDDA.Enumerate(10, 100, 10, 200, 0, plotter); // No Slope & div by zero
LineDDA.Enumerate(20, 200, 20, 100, 0, plotter); // No Slope & point swap
LineDDA.Enumerate(10, 100, 300, 100, 0, plotter); // Zero Slope & div by zero

LineDDA.Enumerate(3, 100, 300, 0, 2, plotter); // Negative Slope

// Positive Slope
LineDDA.Enumerate(15, 20, 300, 200, 7, plotter); // standard point
LineDDA.Enumerate(300, 200, 0, 0, 3, plotter); // point swap

// Picket Testing
Point p1 = new Point(20, 200);
Point p2 = new Point(300, 20);

LineDDA.Enumerate(p1, p2, 20, plotter);

LineDDA.Enumerate(p2, p1, 40, plotter);

Here is the source code & test. --Hope you will find it useful!

[ view entry ] ( 3225 views )   |  permalink  |  related link
Backup & Restore Dates & Times under Linux 
Here are two single-line scripts to save + restore the date & times of files + directories under Linux:


find / -mount -print0 | perl -ne 'INIT{ $/ = "\0"; use File::stat;} chomp; my $s = stat($_); next unless $s; print $s->ctime . "/" . $s->mtime . "/" . $s->atime ."/$_\0"; ' > dates.dat


cat dates.dat |  perl -ne 'INIT{ $/ = "\0";} chomp; m!^([0-9]+)/([0-9]+)/([0-9]+)/(.*)!s or next; my ($ct, $mt, $at, $f) = ($1, $2, $3, $4); utime $at, $mt, $f;'

I did not write them - got them from somewhere else - but I used them today. They worked great: We use them to save + restore the dates & times from a backup over to a server where a few gig of files were intermixed.

Wanted to keep it here for future use!

[ view entry ] ( 3177 views )   |  permalink  |  related link

<<First <Back | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | Next> Last>>