...right here. It doesn't really say anything, though - just a few pages that recap physics usage in games, and then a paragraph about how they're going to change all that, etc.
Didn't white papers use to be heavy on technical content? Now it seems that "white paper" just means "nicely formatted eight page PDF advertisement"....
> there probably isn't a Windows or Linux garbage > collection implementation that is fool proof
Right, of course, it's always possible to leak memory. Just add something to a Map and never let go of it. Not much a GC can do if the application insists that it still has a reference to the object. But other than stuff like that, I feel like most high-level language GC implementations can take care of all but the pathological cases.
> ALWAYS use the "sizeof"
Right, those are good C memory mgmt guidelines. The nice thing about Ruby or Java, of course, is that for the most part those things are managed for you.
Also, FWIW, if you're on Linux, Glib has some nice macros so that something like:
> Empirical evidence has shown, time and time > again, that low level languages like C and > Forth produce more efficient, faster, and > easier to maintain code than today's so > called high level languages.
How's that? So it's actually better to manually malloc and free memory than to let a GC take care of it? Surely you're just jesting!
As someone who's currently wrapping the Evolution C API in Ruby, I can assure you that writing Ruby code is much easier than writing the corresponding C code.
I'm not sure why this would be considered a "Linux strength",. since all the good high level languages - Ruby, Python, Perl, etc - all run on Linux, also.
> Personally, I think a person with his feet on > the desk staring at the ceiling can be "doing > design" just as seriously as someone playing > with UML diagrams in ROSE.
So true. Although I find it helpful to move along these reveries by writing little test apps to put wheels on some ideas... just little 10-20 liners to help get a better handle on things.
> Postgre [..] simply aren't replacements for > Sybase/Oracle in many situations
Actually, having worked on many government projects, I'd say the opposite - there are _many_ situations for which PostgreSQL is a perfect replacement for Sybase or Oracle. I've seen govt project leads buy Oracle and a 4X Sun server to run a couple thousand queries a day on a few hundred MB of data. PostgreSQL could handle much more than that without breaking a sweat.
> I see more mysql errors than 404 errors
Sure, because there's a low barrier of entry to setting up a MySQL server behind Apache. That's like criticizing empty projects on Sourceforge... fish in a barrel.
> I make a habit of stopping by the > manufacturing floor
Sir, I salute you. You're right on the money - an on-site customer is the best thing you can have.
> I can take time to learn PHP/mySQL and > add new features and apps
I found myself in a similar spot once and wrote a several Java apps which were deployed using JNLP. None of them were ever spec'd out or anything beyond a "it'd be cool if we could do blah", but they were all widely used and made folks very happy. And I got to learn some nifty stuff... good times!
The beauty of the things you're suggesting is that most of this stuff can be fixed with a few lines of code. It just takes someone who cares enough to actually watch the users and see how they work.
> Repetitive CPU-bound work is a strength of JIT > compilation. Java should do fine.
Right on, the JIT will do the job once the data gets into memory. And if the guys developing the DB backend need to, they can always use the Java NIO packages to make moving data to/from the disks faster. Good times all around.
> design documents, which end up being > dead documents that are outdated as soon > as the first line of code is written.
So true. Or only one page will be kept up to date - the database schema diagram, because it can be automatically generated from the production database schema.
Meanwhile, new hires are referred to these documents with mumbles of "this is the design documentation, read this and you'll know everything". This statement is usually accompanied with a cynical smile and a shrug, indicating to the new hire the uselessness of the ritual. Ack.
> If it's more than 100 lines long, you're > probably doing something wrong.
Quite right! Once that 100 line method is broken out into a class or two, you'll find two or three other places where you've got minor variations on the same code. Those variations (and their attending bugs) then get refactored away, the codebase shrinks, and good times result.
> Required javadoc/doxygen/VCS comments > often result in "XXX: required for checkin" > type comments.
So true. Or, just as bad:
/**
* The getFirstName method returns this person's first name
* @return the first name
* @author Fred
* @version 1.2.1.3
*/ public String getFirstName() {
return firstName; }
Is there a StatCVS-type reporting tool for Subversion? I suppose StatCVS could be modified to support Subversion... there's been some discussion of it on their mailing list...
I've seen this happen before; I think it's just a bot posting old comments to this store as an AC. And I bet his IP address will get blocked soon...
Or you can use a scripting language...
on
Hacking OpenOffice
·
· Score: 4, Interesting
...that has an Open Office object model, i.e., Ruby's OO4R:
ooo = OOo::Doc.new( filename ) new_text = "This is the NEW text added #{Time.new.to_s}" ooo.insert( new_text ); res_ary = ooo.find(/NEW/ ) ooo.insert_heading( "This is the heading", 1 ) ooo.save
...right here. It doesn't really say anything, though - just a few pages that recap physics usage in games, and then a paragraph about how they're going to change all that, etc.
Didn't white papers use to be heavy on technical content? Now it seems that "white paper" just means "nicely formatted eight page PDF advertisement"....
> why are people so down on malloc anyway?
Free the mallocs! Save the whales!
> there probably isn't a Windows or Linux garbage
> collection implementation that is fool proof
Right, of course, it's always possible to leak memory. Just add something to a Map and never let go of it. Not much a GC can do if the application insists that it still has a reference to the object. But other than stuff like that, I feel like most high-level language GC implementations can take care of all but the pathological cases.
> ALWAYS use the "sizeof"
Right, those are good C memory mgmt guidelines. The nice thing about Ruby or Java, of course, is that for the most part those things are managed for you.
Also, FWIW, if you're on Linux, Glib has some nice macros so that something like:
Message* msg = (Message*)malloc(sizeof(Message));
turns into
Message* msg = g_new(Message, 1);
Handy stuff!
> programming time is finite where as
> cpu time is not
True. But it's seldom the bottleneck.
> Although you may save 400 Development hours
> you can lose millions of hours of runtime
> productivity.
Or you may save millions of hours by being able to quickly and accurately implement features to help the users of your produce get work done.
> What's Ruby written in?
Why was Ruby written?
> Empirical evidence has shown, time and time
> again, that low level languages like C and
> Forth produce more efficient, faster, and
> easier to maintain code than today's so
> called high level languages.
How's that? So it's actually better to manually malloc and free memory than to let a GC take care of it? Surely you're just jesting!
As someone who's currently wrapping the Evolution C API in Ruby, I can assure you that writing Ruby code is much easier than writing the corresponding C code.
I'm not sure why this would be considered a "Linux strength",. since all the good high level languages - Ruby, Python, Perl, etc - all run on Linux, also.
Speaking of which, anyone using that? The user's email list looks a little quiet...
> I was hoping it would be a GNOME/GTK Calendar
Evolution has a nice calendar interface, and the API is pretty good, too.
I'm working on a Ruby binding for it and it's straightforward as long as you're familiar with the Gnome coding conventions.
> Personally, I think a person with his feet on
> the desk staring at the ceiling can be "doing
> design" just as seriously as someone playing
> with UML diagrams in ROSE.
So true. Although I find it helpful to move along these reveries by writing little test apps to put wheels on some ideas... just little 10-20 liners to help get a better handle on things.
> Postgre [..] simply aren't replacements for
> Sybase/Oracle in many situations
Actually, having worked on many government projects, I'd say the opposite - there are _many_ situations for which PostgreSQL is a perfect replacement for Sybase or Oracle. I've seen govt project leads buy Oracle and a 4X Sun server to run a couple thousand queries a day on a few hundred MB of data. PostgreSQL could handle much more than that without breaking a sweat.
> I see more mysql errors than 404 errors
Sure, because there's a low barrier of entry to setting up a MySQL server behind Apache. That's like criticizing empty projects on Sourceforge... fish in a barrel.
> I've worked with [..] PostgreSQL, and they are
> all toy databases.
Fujitsu disagrees with that.
> I make a habit of stopping by the
> manufacturing floor
Sir, I salute you. You're right on the money - an on-site customer is the best thing you can have.
> I can take time to learn PHP/mySQL and
> add new features and apps
I found myself in a similar spot once and wrote a several Java apps which were deployed using JNLP. None of them were ever spec'd out or anything beyond a "it'd be cool if we could do blah", but they were all widely used and made folks very happy. And I got to learn some nifty stuff... good times!
> Get clipboard. Stand over shoulder. Watch
Great post, thanks very much for writing it!
The beauty of the things you're suggesting is that most of this stuff can be fixed with a few lines of code. It just takes someone who cares enough to actually watch the users and see how they work.
> Repetitive CPU-bound work is a strength of JIT
> compilation. Java should do fine.
Right on, the JIT will do the job once the data gets into memory. And if the guys developing the DB backend need to, they can always use the Java NIO packages to make moving data to/from the disks faster. Good times all around.
> the code is the only thing that describes
> what it does
So true.
> There are few greater wastes of time then a
:-)
> code review attended by more than 4 programmers
Well said!
> hope that that line was delivered
> by a smirking co-peon.
It certainly should have been
> design documents, which end up being
> dead documents that are outdated as soon
> as the first line of code is written.
So true. Or only one page will be kept up to date - the database schema diagram, because it can be automatically generated from the production database schema.
Meanwhile, new hires are referred to these documents with mumbles of "this is the design documentation, read this and you'll know everything". This statement is usually accompanied with a cynical smile and a shrug, indicating to the new hire the uselessness of the ritual. Ack.
> If it's more than 100 lines long, you're
> probably doing something wrong.
Quite right! Once that 100 line method is broken out into a class or two, you'll find two or three other places where you've got minor variations on the same code. Those variations (and their attending bugs) then get refactored away, the codebase shrinks, and good times result.
Thanks for the great post!
> a straight face during a code walkthrough :)
In the code reviews I've attended, this code would be greeted with "but where's the '@param none' Javadoc?". Argh++.
> often result in "XXX: required for checkin"
> type comments.
So true. Or, just as bad:Argh!
...is that a motivated user can compile an optimized version or download an optimized build.
That option certainly isn't available in IE or Opera.
Very cool, thanks!
...Subversion support is one of the most requested features on RubyForge.
Is there a StatCVS-type reporting tool for Subversion? I suppose StatCVS could be modified to support Subversion... there's been some discussion of it on their mailing list...
I've seen this happen before; I think it's just a bot posting old comments to this store as an AC. And I bet his IP address will get blocked soon...