Prevayler: How to market stupid ideas
I am absolutely amazed that people can discuss the usefulness and production-worthiness of Prevayler with a straight face.
The genius of prevayler is not that it does anything innovative (it doesn’t), or that it provides incredible functionality (it doesn’t), not even that it is hugely robust and reliable (it isn’t). The genius is purely in the marketing. In fact, it is a shining example of an open source project that manages to play with the big boys using the same dirty tools.
For example, prevayler advertises itself as a persistence engine (sort of), but instead of comparing itself to similar approaches, it wisely chooses to benchmark itself against completely different products used for wildly different purposes. By doing that, it’s able to look you in the eye and gleefully proclaim that it’s 9000 times faster. Amazing huh, that storing something in memory is 9000 times faster than putting it in a relational database.
For the uninitiated, prevayler is basically 3 of 4 classes that allow you to record system state. It basically serialises stuff to disk. That’s it. The clever part is that it doesn’t do so all the time, oh no, it does so once a day. So you have everything sitting around in memory because, well, ram is cheap apparently.
The prevalence skeptical FAQ they offer is another work of sheer genius. Instead of comparing apples with apples, they decide to compare apples with spaceships. The questions all cleverly ask silly things like ‘but what about remote access/clustering’ with hilarious answers like ‘you’re free to use whatever you want! RMI! Corba! XML! Sockets!’. Transactions? You don’t need them! They’re an antiquated idea and pointless anyway! Most of the answers seem like joke responses to be honest, delivered with that devil-may-care-throw-caution-to-the-wind cavalier attitude. It’s cool, it’s hip, it’s also utterly, utterly useless for any serious usage.
I wouldn’t be surprised at all in fact if the prevayler team were to eventually admit the whole thing was a joke to try and see how gullible people are.
June 30th, 2003 at 1:13 am
Prevayler is one of those technologies that just leaves me puzzled. I mean, it is objects, with some serilization for disk storage. Hooray for that. All these smart people keep using it, and I am left feeling that I must be stoopid because I just can’t grok it. Then again, I am still using SQL and JDBC for persistence (and looking forward to Rowsets) so I must be hell-of dumb.
Prevayler reminds me of of XML. Change the world. Through text. I am still confused why that is news.
June 30th, 2003 at 4:21 am
Well the nice thing with Prevayler is
a.) it works
b.) it works
c.) you don’t need 50mb of binaries and 4 layers of EJB, O/R mapping, JDBC APIs and XML descriptors to just persist your objects.
> The clever part is that it doesn’t do so all the time, oh no, it does so once a day.
Wrong. Prevayler serialiases changes to your objects all the time (incremental serialisation just like the Redo/Undo log of your database) and the whole object space whenever you like, usually once a day. Until this post I thought you actually used the things you shred to bits, but this seems not to be the case. This gives all your other posts quite a different angle.
June 30th, 2003 at 4:31 am
I’m a great admirerer of your work, Hani, this is not your best one.
I don’t think you’ve completely understood Prevayler. It’s a bit more than just keeping everything in memory and snapshotting to disk once in a while. For example, it does have transactions, even ACID ones. Prevayler 2 will also support rollback and clustering. And it’s still just a couple of classes. Amazing, right!?
It’s been used at hundreds of succesful commercial projects, 2 of whom I have been part of building. I don’t think they would agree to that it’s completely and utterly useless.
Do you still use a database? :-)
June 30th, 2003 at 4:45 am
It seems some very famous programmers also likes Prevayler:
http://www.beblogging.com/blog/20030626-220031
That is btw the complete source-code for Prevayler 1.00.003 as background for the text.
June 30th, 2003 at 7:08 am
You know, without addressing the technical issues… I like how people are name-dropping. Did you skip over the marketing aspect of the blog entry? Or are you too busy participating in prevayler marketing to realise it?
What is it, do you guys get toasters if you convert enough people or something?
June 30th, 2003 at 7:26 am
@epesh: YES! :-)
June 30th, 2003 at 7:44 am
Okay, regarding the marketing:
I think it’s funny and entertaining. Just like The BileBlog; it’s funny and entertaining. I actually agree with Klaus and not with Hani, but I still think both are funny and entertaining. They are both needed because they shake the community, make people think. It’s good when people start thinking more for themselves instead of just doing the lemming-walk.
The whole point with this blog-entry was that Prevayler was a stupid idea and that marketing tried to cover that over. But since Hani has misunderstood how Prevayler works, the point doesn’t come through.
I feel a bit sad that Hani, who I though was actually trying to provoke people into thinking, didn’t himself think through this Prevayler rant properly. Instead he just reacted with the same knee-jerk reaction most people do: “Huh!?! In memory!?! Not in a database!?! Fools! That cannot possibly work!!”
It would be a really neat rant on those kind of lemmings. Just have a look at the Slashdot thread on Prevayler. That’s entertainment!
(And we don’t get toasters, we get tickets to a vacation in Brazil.)
June 30th, 2003 at 11:49 am
I think Hani’s right on mark. Transaction support? So if I get a runtime exception in the middle of an update, the Prevayler will roll back to the pre-command state? Refactoring my domain model? I suppose that I can only make changes to my domain objects that are allowed by the Serialization spec. There’s something to be said about decoupling your domain model from its persistent representation (not saying that O/R is the best answer either).
June 30th, 2003 at 12:21 pm
I think Hani’s right on mark. Transaction support? So if I get a runtime exception in the middle of an update, the Prevayler will roll back to the pre-command state? Refactoring my domain model? I suppose that I can only make changes to my domain objects that are allowed by the Serialization spec. There’s something to be said about decoupling your domain model from its persistent representation (not saying that O/R is the best answer either).
June 30th, 2003 at 12:54 pm
“Run-time exceptions are just that - exceptions,
and you should not plan on receiving them normally”
LOL!!! (Whew, Hani’s rubbing off on me.)
“Also, the constraints (serialization-capable and not using random generated values) are the easiest to comply with. In fact, EJB, RMI and sockets-based applications already require serialization.”
Please read more closely. I’m not talking about making my domain objects Serializable. I’m talking about evolving domain objects that are Serializable.
June 30th, 2003 at 1:44 pm
Hani-,
This time you missed the target…
Can you point us to those “similar approaches”, so
we can leave the RDBMSes alone?
What is so wrong with creating simple software that just … works! Oh, I forgot - you are an EJB fan!
Bob-,
Run-time exceptions are just that - exceptions,
and you should not plan on receiving them normally. Also, the constraints (serialization-capable and not using random generated values) are the easiest to comply with. In fact, EJB, RMI and sockets-based applications already require serialization.
June 30th, 2003 at 1:49 pm
If only C.J. Date or Fabien Pascal (http://dbdebunk.com) would take the time to pick Prevayler apart. It is the embodiment of all they have been criticizing in the database industry and practice.
Basically, some people think that persistence is all they need to do data management. Seems that we are travelling back in time to the ancient mainframe age when applications owned the data. This means even before the IMS/CODASYL age. Extrapolating this trends, Prevayler 3 will include support for Hollerith cards…
It would also make a far more interesting rant than this one. Just take a look at some of their stuff.
June 30th, 2003 at 3:19 pm
Bob Lee-,
If being “serialization-capable” is a
tough requirement for the evolution of your domain model, please, point us to that “alternative technology”, which poses easier constraints and yet, makes your app as performant as a Prevayler-based one.(In your own words, O/R tools do not cut it either)
Having said that, default java serialization does have its well-known problems (for solutions, see the excelent “Effective Java” by J Bloch), but this is not Prevayler’s fault…
Bob-,
I think your evolution concerns are coming from the dogmatic “…decoupling your domain model from its persistent representation”. How about some more OO thinking here, like: “Object’s data is ALWAYS private and should ONLY be accessed thru object’s public interface. Period!”.
For example, if you want to *export/import* your objects in evolution friendly format (such as XML, DBF or plain text), make this a *feature* of your application. You’d be surprised how little code/effort is typically involved!
As in the above, Prevayler challenges well-cemented concepts in our brains, such as “application server”, “transaction” or “always strive to conserve RAM at ANY cost”.
As a result, Prevayler is getting a lot of … “bile” along the way. I am actually a bit surprised, since other novel and radical concepts, such as AOP, pico/nano-containers, etc. do not get the same “attention”.
Only time will tell, I guess…
Hani-,
If Prevayler is an example of “How to market STUPID ideas…”, then, well, we have to assume that Jon Tirsen (Nanning), Jonas Boner(AspectWerkz) and Kent Beck (XP), among the others, are … also stupid (or at least, can not read code)! If you have a problem with the “aggressive” web site and FAQ … just take a look in the mirror;-) and read your own blog! (I certainly do not have a problem with the presentation style on both web sites!)
Hristo
July 1st, 2003 at 8:40 am
Bob:
Schema evolution is a very tricky subject persistence what technology you are using. The good thing is that they are quite orthogonal. There is nothing stopping a Prevayler system to for example export it’s data to an RDBMS just to do it’s schema upgrade. It is in fact close to the strategy we are using (although we don’t export to an RDBMS). As a matter of fact in one system we use exactly the same schema upgrade strategy now as when the system was based on EJB and RDBMS. We didn’t change one line of code in the upgrade sub-system when we ported to Prevayler. It just works… and the customers hardly complain about the sometimes almost unbelievable performance gains, and of course, much easier deployment.
And, yes, Prevayler 2 has transaction support. It will rollback your objects to the state they were before the transaction was executed (if the transaction fails, of course). Prevayler 1 just has ACID transactions without rollback, the changes your transaction made will be persistent for all future.
Please try to think outside the box for a while. I’m not saying O/R or RDBMS is a terribly bad solution (although I think for many situations it is overkill), but it’s not the *only* solution. Prevayler is definitely an alternative worthy of serious consideration. It’s multitude of succesful (sometimes hugely succesful) deployments indicate this. It should be part of any serious developers toolbox just as OODBMSs, RDBMSs, O/R, flat files, property files, XML, b-trees and so forth.
July 1st, 2003 at 10:27 am
That first sentence really came out kind of weird (it’s a shame you can’t edit these comments)… It should read:
“Schema evolution is a very tricky subject no matter what persistence technology you are using. The good thing is that they are quite orthogonal.”
July 2nd, 2003 at 8:44 pm
Jon, sorry but when I read things like “hundreds of successful deployments” and I can’t find any mention of this on the main page of Prevayler, I wonder if you haven’t been drinking a little bit too much of Kool Aid.
You guys should enlist Gerald Bauer, he would be a great addition to your PR team :-)
July 3rd, 2003 at 10:54 am
I agree, Cedric. We should get hard facts on the references. But you know as well as I do that companies are reluctant to give permission to use their names in marketing, especially considering that such a thing would reveal proprietary information about their technology choices.
We (www.lecando.com) use it with solutions deployed at several large swedish companies. I know of several other very large companies that has also succesfully used Prevayler. For example, ask Jonas Boner where he used Prevayler.
The numbers are unquestionably true, proving it with hard facts are much harder. But I thought this was an informal forum and not a legal court.
September 7th, 2003 at 10:24 pm
I just ROTFFL when people say stuff like “Prevayler is just a stupid idea” :-)
BTW, what’s up with this stupid “calendar” thing that doesn’t let me read the blog entry without copy/paste to notepad?