Miswanting and web application frameworks

I’ve wanted to respond to this post by Kris Thompson where he predicts that “Struts will continue to lose industry acceptance as the MVC leader in the J2EE space” in 2004 for some time now. I believe this is happening already; if you read the blogging community or some of the industry rags, it seems like other alternatives to Struts are being promoted (not least of which is JSF). But there are still tons of Struts applications out there being built every day. There have been over 2000 messages on the struts mailing list for the past year (granted this number is declining–perhaps because folks are GFTFA [googling for the fcuking answer]).

This article explains why I continue to develop in struts: “A wider range of slightly inferior options, then, can make it harder to settle on one you’re happy with.” There is definitely a wide range of J2EE frameworks. In my case, these alternatives to struts are not inferior because of any technical shortfall, but rather because I have to learn them.

(An aside: I have programmers’ optimism as much as anyone else. But after a few years in the industry, I’ve realized that while I feel I can learn a new technology as quickly as need be, in order to really understand the pitfalls of a framework or API, I have to “build one to throw away.” I really do.)

Please don’t take these statements as a whiny “I don’t want to learn anything new.” That’s not true. But my time is finite, and the project deadlines are always creeping up. And struts works well enough for my problem set.

And that’s why struts is going to be around for a while yet.


Do you know where your sensitive files are? Google does.

Googling Up Passwords points out that Google‘s spiders crawl web server error messages and other misconfigurations just as easily as they crawl real content. For simple sites, like mine, there’s not really an issue. Static HTML doesn’t yield much of interest. For complex sites, like Amazon and Ebay, there is a phalanx of security experts waiting to pounce upon and patch the latest bug (perhaps not an entire phalanx, but those sites can and must afford security experts). But for the small workgroup web server, probably using MS products (for ease of use, convenience and training reasons), having such detailed examination of their web server available by keyword search is a disaster.

I often think of computers and cars in the same light. Automobiles were difficult to operate, prone to breaking down, and expensive during the early years of the 20th century. However, eventually, the technology standardized, the industry consolidated, and the car became a fundamental part of (American) life. Computers have only been accessible to common folk since the 1950s, so it’s not fair to demand the same level of reliability. Yet, how much more protean is the computer than the automobile? It took decades to get air bags installed and seat belts worn. How long will it take before folks have the same level of visceral, unconscious understanding of the perils of the computer?


Book Review: Legacies, A Chinese Mosaic

How much do you know about recent Chinese history? I knew a bit, but reading Legacies, A Chinese Mosaic, by Betty Bao Lord, really brought the recent human tragedies of modern China home.

Bao Lord intertwines two main themes: the story of her experiences as an American citizen who emigrated from China as a youngster and is returning as the wife of a American diplomat, and the stories of Chinese friends and acquaintances, often given to her on audio tape, and recounting the sordid and tragic tale of the last 50 years of China. She does all this against the backdrop of the mid to late 1980s and the Tiananmen Square protests by college students.

This book derives much of its power from the simple stories Bao Lord relates. Whether it’s the man who stays alive locked in his office (for years) because his son flys a kite to reminds his father of his presence, or the stories of the real life excesses of the Red Guards, burning any of the “Four Olds,” these stories are touching and real. Even her own family story has a certain pathos, as we learn about her grandfather dying three years before she was able to visit, her aunt calmly dying of cancer, and a sister who only learned that she was adopted by happenstance.

The Great Leap Forward, the Cultural Revolution and the other major events of modern Chinese history are only touched on as they affect the people in the stories told, but even that was enough to shock me with what this nation endured. In fact, it’s even more shocking than it was when I read about it in the history books, because the folks in the stories are real people.


With enough eyeballs…

I referred to Project Gutenberg obliquely here, but browsing their site I found that they’ve implemented distributed proofreading. This is a very good thing. I did one book, Hiram, the Young Farmer, for PG a few years ago, when I was in college and time wasn’t so precious. The OCR went quickly, but the proofreading was slow going and error prone; the story wasn’t exactly riveting, but it was in the public domain. (In fact, I just took a look at Hiram and found at least two mistakes. Doh!)

But Distributed Proofreaders solves the proofreading problem by making both the scanned image and the OCRed text available to me in a web browser. Now I can proofread one page at a time, easily take a break, and even switch between books if I’d like. Also, they’ve implemented a two phase review, much like Mozilla’s review and super review process. Hopefully this will prevent mistakes from being made, since these are going to be the authoritative electronic versions of these documents for some time. Linus’ law probably holds for text conversion even more than for software development.

Now, it wasn’t apparent to me from the website, but I certainly hope the creators of this project have licensed it out to businesses–I can see this application being a huge help for medical transcriptions (work from home!) and any other kind of paper to electronic form conversion.

Update:
It looks like there is a bit of a distributed.net type competition among the PGDP proofreaders.


Long running queries in servlets

The stateless nature of the web presents some user interface issues. Not least of these is how to handle long running processes most efficiently. Do you keep the user waiting, do you poll, etc? Remember, even if everything is going dandy, normal users like to see something.

This JavaRanch article is a good explication of how to use message driven beans and asynchronous access to data in the web tier to deal with these problems. It leans a bit heavily on WebSphere, but does seem to address some of Dion’s issues about there not being enough use of messaging systems. And it even throws a couple of design patterns in as well.


The people’s voice

Tim Bray points out Radio Vox Populi which is a really cool idea:

weblogs + web crawler + text-to-speech + mp3 streaming = talk radio for everyone.

Of course it could do with some filtering, or categorization, but it’s a cool idea. It actually jives with an idea I’ve had for a long time, which is to use text-to-speech, perhaps Festival, to burn cds of Project Gutenberg to create cheap books on cd (oh, should I listen to Boy Scouts on Motorcycles, by G. Harvey Ralphson or Armenian Literature, by Anonymous today?). That’d be cool, if you can handle listening to a robot voice.


Comments on “‘Real Throwbacks’ comment response”

Well, I was going to trackback this post, but Nancy doesn’t have that enabled, so I’ll just comment here. Much anger in this one.

The problem with raging about radio is that it’s a *free* service. What do you pay for the time you listen to the radio? Now, of course ClearChannel is pop pap and there’s a lot of consolidation happening in the radio business, with generally negative impacts on quality. Don’t blame CC–they’re just reacting to the mandates of the market. (Your media can be free, diverse, or equal, pick any two.)

If you don’t like that-which-was-KTCL, blame the government for taking a public good and whoring it out without thinking about the consequences or having any more justification than ‘the market always does right.’ If there’s one thing we should have learned from the last couple of centuries, it’s that while capitalism may the least of the evils, it’s still evil. Of course, this isn’t a new thing.


Harpers

I was at a friend’s house a few months ago and ran across a copy of Harper’s magazine. I’d read it before, mostly in dentists’ offices and such, but I read this one cover to cover. There was an especially hilarious piece, Beware of Dogg by Dr. Ninjaforkian, in the Readings section (which has apparently been posted on /. and MetaFilter). Since then, there’ve been bits on ClearChannel, the food chain, Korean sayings, and the coming election. Eclectic, no?

I just found out that one of my favorite sections is online: Harpers Index displays fascinating facts and gives you the source for every one. Just what you need at parties!

“Percentage of Chinese exports to the U.S. accounted for by merchandise sold at Wal-Mart : 10 [Wal-Mart (Bentonville, Ark.)/Department of Commerce (Washington) ]

Number of factory jobs that China has lost since 1995 : 25,000,000 [Alliance Capital Management Corporation (N.Y.C.) ]”
from Feb 2004

“Number of Canadian prison inmates who overdosed in March on fellow prisoners’ methadone-laced vomit: 2 [Saskatchewan Department of Corrections (Regina, Canada)]

Number of inmates charged with drug trafficking for providing the vomit: 3 [Saskatchewan Department of Corrections (Regina, Canada)]”
from Sep 2003

I didn’t see the sources online, but they’re there in the HTML source, and hence in the cut-and-paste above (I don’t really understand why they weren’t showing up; neither Mozilla nor IE displayed them). Go ahead, read them all.


IPTraf

Hey, I like to work at the higher levels of the 7 Layer Burrito, the Application, Presentation and Session layers. But every so often, you have to dig a bit deeper. Currently, I’m troubleshooting a ColdFusion application that was converted from a local mysql database to a remote postgresql database. There are quite a few docs about optimizing postgresql, but the focus on query and local database optimization, and I think the issue was the network traffic (based on load average of both the local and remote boxes). Anyway, I found this neat tool called IPTraf which gives you real time monitoring of ip traffic. Pretty nice, but avoid the US mirror of the binary build, since it’s not complete.


What are EJBs good for?

Dion had a good post about what EJBs are good for. I’ve only used EJBs seldom (and peripherally), but it’s my understanding, from reading the literature, that EJBs are appropriately named–that is, good for enterprise situations. In that case, what on earth are these folks thinking? They demonstrate using an EJB in JSP. What?



© Moore Consulting, 2003-2017 +