Slashdot Mirror


Prevayler Quietly Reaches 2.0 Alpha, Bye RDBMS?

ninejaguar asks: "Slashdot did an article on an Open Source product called Prevayler, which could theoretically resolve all the problems associated with OO's rough courtship with Relational databases. Slashdot covered Prevayler when it was still 1.x. Despite fear, doubt, and memory concerns, it has reached 2.0 alpha. Is anyone currently using this non-database solution in production? If so, has it sped development because of the lack of OO-to-RDBMS complexity? Was there a significant learning curve to speak of? The LGPL'd product could be incorporated into proprietary commercial software, and few might know about it. Is anyone considering using it in a transactional environment where speed is the paramount need? And, are there any objections to using Prevayler that haven't been answered at the Prevayler wiki? Would those who use MySQL find Prevayler to be a better solution because it's tiny (less than 100kb), 3000 times faster and is inherently ACID compliant?" Update: 09/24 19:25 GMT by C :Quite a few broken links, now fixed.

"We've used relational databases for years despite incompatibilities in SQL implementation. Accessing them from an OOP paradigm has been so tedious, that Object-Relational mapping technologies have sprouted all over the Open Source landscape. Some competing examples and models are Hibernate, OJB, TJDO, XORM, and Castor; which in turn have supporting frameworks such as Spring and SQLExecutor. Because SQL is the dominant form of interfacing with the data in an RDBMS, there's now a specification to offer it a friendlier OO face.

Most of the above, including the SQL-variants, arguably appear to add yet another layer of complexity (even if only at the integration level) where they should be taking complexity away. These solutions are put together by some very smart people, but it's inescapable to get that feeling someone is missing the forest (simple answer) because all the trees (incompatible models) are in the way. If there are so many after-the-fact solutions attempting to simplify relational database access and manipulation from OO, isn't it reasonable to think that there is something generally wrong with trying to cobble-together two disparate concepts with what are essentially high-caliber hacks? Is Prevayler a better way?"

444 comments

  1. To Hell with MySQL by Anonymous Coward · · Score: 0, Redundant

    I, for one, welcome our new object-oriented relational database managment systems overlords!

    1. Re:To Hell with MySQL by Anonymous Coward · · Score: 0

      This article is entirely buzzword-compliant(TM).

  2. 3000 times faster than Mysql? by Anonymous Coward · · Score: 4, Insightful

    Is that really possible? How do you even benchmark that?

    1. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 4, Informative
    2. Re:3000 times faster than Mysql? by Delirium+Tremens · · Score: 0, Offtopic

      Hey, ninejaguar, you could at least have the decency to log in if you want to participate in this press^Wdiscussion. Don't insult our intelligence further. Please.

    3. Re:3000 times faster than Mysql? by pVoid · · Score: 4, Interesting
      Something else that makes me think "is that even possible"...

      Zero bugs. Ever.

      No one has yet found a bug in Prevayler in a Production release. Who will be the first?

      link.

      I didn't know people still made such bold assertions past the dot-com era.

    4. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0

      Well, even if they found one, or eleven bugs, they'd still be leaps and bounds better off than MySQL.

    5. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 2, Insightful


      Yeah, well, something needs a production user-base before it finds errors in production use.
      </flame>

    6. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0
      That was my point =) quite implicitly.

      Also, I think you meant flame bait?

      -pVoid

    7. Re:3000 times faster than Mysql? by FrangoAssado · · Score: 2, Insightful
      Well, from the comments in the wiki FAQ:

      • Not really. (...) MySQL used a SQL query, where as Prevayler just tranversed a set of objects. Since Prevayler doesn't include a query language, that's comparing apples to oranges.

      I haven't looked at the benchmark, but it seems that Prevalayer traverses a set of objects in memory 3000 times faster that MySQL queries the database and traverses the results.

      In other words, that *is* actually comparing apples to oranges.

    8. Re:3000 times faster than Mysql? by slimdave · · Score: 0, Flamebait

      Sure it's possible -- all you do is let java programmers design a relational database. Ta Da! Instant pile-of-crap. Would anyone believe Microsoft if they posted "3000x faster than ..." results for one of their products? I think not -- these folks are no different. As soon as they post results of an industry standard benchmark (TPC or whatever), the myth will be nicely punctured.

    9. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0

      Faster than MySQL and JDBC, allegedly. MySQL ain't great, but it's not that bad. JDBC? It's that bad. Java? It's that bad too.

      Give me a real database I can access from multiple languages, thanks.

    10. Re:3000 times faster than Mysql? by arivanov · · Score: 1

      Yes it is. Guess on what.

      On a memory resident database vs unoptimized MySQl reading from disk. What a horrrid crock of worthless shite for a benchmark.

      Object prevalence is not the answer for any large scale problem. A good example for this is the old Vitria connector used for mediation which used an in-house prevalence library and an in-house persistent connection implementation by whoever wrote it. The result was that a single communication failure lead to the object backlog eating 8-9G of RAM on a machine processing real call records in a real telco.

      Otherwise it is a qute small scale concept that has its place.

      --
      Baker's Law: Misery no longer loves company. Nowadays it insists on it
      http://www.sigsegv.cx/
    11. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0

      Somewhat OT but djb has made similar claims for qmail and some of his other programs, and qmail is actually quite popular.

    12. Re:3000 times faster than Mysql? by lokedhs · · Score: 3, Insightful
      In short: No it's not.

      The long answer is: Yes, it's a lot faster retreieving data. It's about as fast as looking up an object in an in-memory array, because that's what it does. However, they are comparing apples to oranges.

      Prevayler is a very neat piece of software. It's very simple, and not hard to implement really. The problem is that the people behind Prevayler seems to think that it's the end-all-be-all of databases. It's not.

      What these people fail to mention is that you lose somehting that a lot of people find very useful in SQL databases: select. Yes people, that's right. It doesn't provide any way of searching or joining tables. In fact, you don't even have tables. All that Prevayler really is, is a method to encapsulate all data modifications in an action object which is persisted to disk, so that they can be re-played whenever the system starts after a crash. All data accesess are performed just like any other memory read, in the same way as you access any other object. Of course it'll be faster than accessing an SQL database.

      The Prevayler people are very good at twisting the truth to create some amazing benchmark results. It's a good technology, but the the attitude of the developers is slightly irritating.

    13. Re:3000 times faster than Mysql? by GreyPoopon · · Score: 1
      No one has yet found a bug in Prevayler in a Production release. Who will be the first?

      Sorry...can't resist...

      Source Code for Prevayler V1.0

      #include <stdio.h>

      void main() {
      printf("Hello World.\n");
      }
      --

      GreyPoopon
      --
      Why is it I can write insightful comments but can't come up with a clever signature?

    14. Re:3000 times faster than Mysql? by Emil+Brink · · Score: 1

      That's horribly buggy!! In C, main() returns int . And a function taking no parameters should be defined as (void), Since main() must take either zero or two arguments, your code is incorrect there, too.

      --
      main(O){10<putchar(4^--O?77-(15&5128 >>4*O):10)&&main(2+O);}
    15. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0

      Sorry...can't resist...

      Source Code for Prevayler V1.0 #include void main() { printf("Hello World.\n"); }

      Well, there's several bugs there. main() should return int, and takes an int and char ** arguments.

      Chris

    16. Re:3000 times faster than Mysql? by GreyPoopon · · Score: 1
      That's horribly buggy!

      Yeah, I know. Part of the humor was in waiting to see how long it would take somebody to "bite" the bait. :-)

      --

      GreyPoopon
      --
      Why is it I can write insightful comments but can't come up with a clever signature?

    17. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0
      Well, there's several bugs there.

      Looks like Emil Brink beat you to it. Yeah, I knew all of that when I wrote it. What I wrote will technically work, and I started to write it correctly but instead I left it as it was to see if anybody would catch the humor in it. Left as is, it compiles with a warning that main should return an int, but still runs. Anyway, I was hoping somebody would find the errors funny.

    18. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0


      Of course you were waiting for someone to bite the "bait". Very humorous - you almost had us going there that you were a moron.

    19. Re:3000 times faster than Mysql? by julesh · · Score: 1

      You're probably not too far from the truth. Quote from the site:

      The current production release implementation code is 335 lines long

      I think I could write a bug free 335 line long program over the course of 18 months, which is I think roughly how long this has been in development for. That's less than 1 LOC per day! You were probably writing that example about 3000 times faster than they were writing prevayler! ;-)

    20. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0

      > What these people fail to mention is that you
      > lose somehting that a lot of people find very
      > useful in SQL databases: select. Yes people,
      > that's right. It doesn't provide any way of
      > searching or joining tables

      Well, to look at another angle, it doesn't *force* you to use neither tables nor a constrained mechanism such as select. Querying and updating data in memory is MUCH EASIER, believe me! That is, if you can do OO.

      And trying to quote Morgan Freeman in Shawshank Redemption: "these walls are funny; first you hate them, then you get used to them. And then... you start depending on them."

      Luckily I barfed all my stomach's content the first time I saw SQL and never jumped in that bandwagon. I knew that 3rd class hack couldn't be the universal solution to reliably storing and retrieving large amounts of data.

    21. Re:3000 times faster than Mysql? by lokedhs · · Score: 1
      Well, to look at another angle, it doesn't *force* you to use neither tables nor a constrained mechanism such as select. Querying and updating data in memory is MUCH EASIER, believe me! That is, if you can do OO.
      If you read my post again you will notice how I never said that Prevayler is in any way bad. In fact, it's very good.
      Luckily I barfed all my stomach's content the first time I saw SQL and never jumped in that bandwagon. I knew that 3rd class hack couldn't be the universal solution to reliably storing and retrieving large amounts of data.
      That's just trolling, and really doesn't desrve an answer. Suffice it to say that a lot of people (who actually used SQL) disagrees with you.
    22. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0
      If you read my post again you will notice how I never said that Prevayler is in any way bad. In fact, it's very good.


      If you read my post again you will notice that I was just pointing another angle to the matter. People always complain: "bah, I can't do select!", because they just don't get that there are other ways to.. well.. select the objects you're looking for.

      Luckily I barfed all my stomach's content the first time I saw SQL and never jumped in that bandwagon. I knew that 3rd class hack couldn't be the universal solution to reliably storing and retrieving large amounts of data.

      That's just trolling, and really doesn't desrve an answer.


      Sorry. Didn't mean to be a flame bait. I really did feel that way -- disgusted to death! I didn't actually barf on the classroom tho.

      Suffice it to say that a lot of people (who actually used SQL) disagrees with you.


      That goes without saying.
    23. Re:3000 times faster than Mysql? by Anonymous Coward · · Score: 0
      In other words, that *is* actually comparing apples to oranges.


      No it's not. While you "traverse" the objects in memory with Prevayler you are actually doing an implicit query. See - you can read your data whenever* you want. There Is No Query. There is no imposed "query language" layer between the logic that uses the data and the data.

      * use synchronized when needed.
  3. Good news by Anonymous Coward · · Score: 0

    Richard "DataBase" M. Stallman needs a break.

  4. Who got paid to post that Prevlayer ad? by Anonymous Coward · · Score: 0

    Sounds like harassment to me.
    Call your EU member!

  5. Victorious by Anonymous Coward · · Score: 0

    Given enough time, I suppose this particular implementation will Prevayl

  6. Project Promotion by Bingo+Foo · · Score: 5, Insightful

    I'm all for trying to use Slashdot to promote your pet project, but don't couch your story in questions about people's use of your admittedly relatively unknown software.

    --
    taken! (by Davidleeroth) Thanks Bingo Foo!
    1. Re:Project Promotion by Anonymous Coward · · Score: 3, Funny

      I agree; the phrasing is pretty off-putting, especially with all the answers and assumptions presumed in the posing of the questions themselves.

      Leave that stuff for the "Messages for Marketdroids; Nerds that Natter" website.

    2. Re:Project Promotion by ralico · · Score: 1

      Perhaps it should be changed from the lightweight-louie-vs-the-data-behemoth dept. to the shameless plug dept.?

      --

      SCO to Hell
    3. Re:Project Promotion by C10H14N2 · · Score: 5, Interesting

      ...the quasi religious cult sanctimonious denigration crap doesn't do much to convince either, as if storing tabular enterprise data in - GASP - "tables" is such a terrible thing to do indicative of a lower order of being in need of spiritual and philosophical cleansing and release from porridge-feeding in prison.

      [Question: In SQL] Given a table of employees, and a table of offices, it's very easy to find those employees who don't have offices, and those offices who don't have employees. How can I do this in a consistent manner in Prevayler?

      [Their answer:]

      Trivial. But how about a query over polimorphically evaluated methods based on the current millisecond?

      Talk of "trivial," you can already persist your Java objects into the same store as all your other data and access it either through EJB's, simple entity beans or straight SQL. IMHO, that is a far more useful model than locking everything into a pile of serialized object collections accessible only to a handful of Java gurus who have better things to do than write reams of application logic in order to tell Jim-Bob in accounts payable that he owes the janitor fifty bucks. If it takes less SQL than it would take to write the necessary includes in Java and I can still map everything into Java objects when necessary, why bother giving up 80% of your functionality to get only what is already there? Performance? Please. When the effort of generating a simple report exceeds the price of the CPU, just buy another CPU and save on labor. Besides, after being categorically insulted by these self-satisfied pricks, I wouldn't use their product if it would end hunger and bring about world peace.

    4. Re:Project Promotion by Anonymous Coward · · Score: 1, Insightful

      I agree wholeheartedly with this last point. Could anyone present content from this Wiki at a project fact finding meeting with a straight face?

      Project leader: Ok, but I just don't see what real benefits we're getting here.
      You: Let me check the FAQ... ahr, here we are: "You're an idiot who doesn't know how to program."
      Project leader: These Prevayler guys really know how to get me and my team onside!

      It's like something out of My New Filing Technique is Unstoppable! All other technical merit issues aside, this ( might ) be great if we were all programming in some kind of vacuum where nobody else wants to run Crystal against our data stores, and the purchasing officer doesn't mind me applying for another 512Mb of RAM per week, and the server has infinite RAM slots because the JVM can't be spread across multiple hosts without allegedly introducing atomicity issues, and nobody minds the downtime while I fit it, but unfortunately I don't work in that kind of vacuum, and I suspect very few of the other posters here today do either.

      Someone by the name of Alan wrote on the wiki: You don't need to be this hype-heavy to sell a good product. The corollory is left to the reader. - if you're reading this Alan, I wish I could shake your hand. You've hit the nail right on the head - people making potentially important development decisions don't like being preached to, and they don't like to be made to feel like they're some kind of idiots.

    5. Re:Project Promotion by baka_boy · · Score: 4, Insightful

      First off, SQL is an idealized, functional language for querying large datasets -- in theory, you can run any imaginable query, but in reality, you can't touch an un-indexed field on most production databases unless you've got *lots* of horsepower to burn, and very patient (read: non-existent) users. Personally, I find that there are a pretty large number of queries that are also pretty difficult to write in SQL.

      Really, it's not that different from the procedural-vs-functional or static-vs-dynamic typing issues in language design: a holy war that no one's going to win, except for the developers who learn to adopt the best pieces from each side without making dire claims about the imminent death of either side.

    6. Re:Project Promotion by Anonymous Coward · · Score: 0
      Then shoot your important-decision-making-boss before he makes the mistake of shaking the hand of a Microsoft rep who'll just take him out to a power lunch at the local ritzy country club. Of course, I'm assuming you haven't been outsourced yet and still hold a job where you have such a clever boss making those fine decisions.

      Cheers

    7. Re:Project Promotion by thenerd · · Score: 1

      Prevayler does anything you want!

      (You've just got to code it)

      --
      The camels are coming. I'm in love.
    8. Re:Project Promotion by C10H14N2 · · Score: 1

      No, it is a very simple situation.

      Your final point exemplifies the simplicity of the situtaion: everything being alternately disparaged or glorified amounts to nothing more than a stack of tools and reasonable beings find the best available tools to suit a purpose. These jerks invited wrath by saying quite directly "you are ingorant subhuman morons if you don't want to use our tool for absolutely everything imaginable," which is not exactly the best professional, scientific or academic stance to take if they want anyone to take them seriously or even pay attention to them beyond a casual "piss off," especially if the holy grail of a tool in question is utterly useless for all but a tiny selection of applications and even then the exact architectural bottlenecks they champion themselves as solving become overwhelmingly impaired in the most obvious of cases that even a 15 year old could identify.

    9. Re:Project Promotion by functor0 · · Score: 1

      > in theory, you can run any imaginable query,
      > but in reality, you can't touch an un-indexed
      > field on most production databases unless you've
      > got *lots* of horsepower to burn, and very
      > patient (read: non-existent) users.

      If you've got more than 10's of gigabytes of raw data to search, and are willing to trade indexing time for query, these products can index ALL your data without exponential increase while achieving order of magnitude faster queries:
      http://www.arunasoftware.com/
      http://ww w.disc.com/products.html

    10. Re:Project Promotion by Anonymous Coward · · Score: 0
      You've hit the nail right on the head - people making potentially important development decisions don't like being preached to, and they don't like to be made to feel like they're some kind of idiots.


      Well, Oracle and Microsoft surely know how to massage egos.
    11. Re:Project Promotion by Anonymous Coward · · Score: 0
      Really, it's not that different from the procedural-vs-functional or static-vs-dynamic typing issues in language design: a holy war that no one's going to win, except for the developers who learn to adopt the best pieces from each side without making dire claims about the imminent death of either side.


      There is discussion on the prevayler list about integrating some kind of object "query" engine (or having it as a standard add-on). So you can code "queries", like, in character strings, like you do with SQL. Altought this defeats the protection that the compiler gives you, it seems that people are happier that way. Well, lots of people are happy with VB...

      Another point is that Prevayler needs enough RAM to hold all your objects, and a JVM that supports it. If you don't have that for your application, you don't even have to consider Prevayler. Your DMBS and it's SQL "wins". For the time being, that is... :-)
    12. Re:Project Promotion by ninejaguar · · Score: 1
      These jerks invited wrath by saying quite directly "you are ingorant subhuman morons if you don't want to use our tool for absolutely everything imaginable,"

      They said no such thing. Admittedly, there may be posts where they may have been feeling particularly defensive due to unwarranted attacks by dbms fundamentalists. Or, they may have just been weary of repeatedly giving the same advice one more time to someone who'd rather just talk instead of taking eight simple classes out for spin. Or, they could've been irritated for any hundreds of reasons that could irritate coders (not marketers) and might've lost their patience. God forbid we should see something like that happen on Slashdot!

      However, if your perception of their posts have led you to believe as such without trying their code, I'll give you some advice I gave a younger cousin, "Sticks and stones can break my bones but words can never hurt me."

      Don't throw away the gift just because you don't like the package. Don't confuse the gift with the package. Take it and add it to your toolbox. Don't thank them for it if you don't think they'll appreciate it. But, if you find that it's the right tool for the right job, then use it to help your clients.

      There are many wacky and dangerous things that come from the mouths of M$ and Sun. Do I stop using their tools? Nope. I just throw away the packaging before my clients see them, and help make the world just a little bit easier for them.

      = 9J =

    13. Re:Project Promotion by C10H14N2 · · Score: 1

      I was responding to what they put on their own website, which I have never seen the likes of spewed by any 800-lbs gorilla like Sun or Microsoft. Despite the choice of words, which led many to similar conclusions that these guys are complete assholes, their arguments nonetheless did not convince that their product was useful for any real purpose. With no logical reason to bother with it in the first place, the shitty attitude they chose to communicate with simply provided conviction to a foregone conclusion.

    14. Re:Project Promotion by ninejaguar · · Score: 1
      "which I have never seen the likes of spewed by any 800-lbs gorilla like Sun or Microsoft."

      With only that statement to go on, I would guess that you may be new to Slashdot. Please visit and read the outrageous lies. More can be found here, here, and here.

      You've confirmed for me that not many people actually looked at the code (around 500 lines) or even tried the demos that came with it before offering an opinion. The value of their opinions should be weighed with that in mind. After all, why voice an opinion on something you haven't tried? Why should someone believe that opinion? If you have a child, would you give that child the advice of following, and believing, in the opinion of others who haven't even experienced the subject firsthand, or know of actual cases where the subject warranted that opinion? Granted, a small minority of posters who didn't "think" the product could work at least prefaced their opinion with the fact that they didn't know the product at all.

      did not convince that their product was useful for any real purpose

      The idea that there isn't a place for this technology is proven false by the existance of products using some form of object prevalence. Simply go through the posts in this article and you'll run into a handful of people who bothered to post about their experiences and projects.

      However, if you have no interest in using the product, there is nothing wrong with that. There may be a myriad of legitimate technical reasons why someone wouldn't use it (I know of very few). However, let's be clear here. To base a reason on packaging is nothing more than a simple matter of taste, not true objectivity. It has absolutely nothing to do with technical merits.

      = 9J =

  7. Persistance does not make a DB by Godeke · · Score: 5, Insightful

    This would be great for projects where interoperability isn't an issue or only occurs via edge connections like SOAP. However, I generally would be wary of a "database" which is only accessible in Java, via unique interface. What do you do with your Crystal Reports users? How do I get this into data cubes for analysis?

    Frankly, this is simply a persistance layer with some nice properties. It *isn't* a database. A database stands at the center of your applications and makes itself available to as wide of an audiance as possible. It shouldn't limit your choice of tools in such an absurd manner.

    --
    Sig under construction since 1998.
    1. Re:Persistance does not make a DB by Elwood+P+Dowd · · Score: 5, Interesting

      Their jingoism is absurd.

      "We have some features that are better than relational databases. RELATIONAL DATABASES SHOULD NEVER BE USED AGAIN."

      In their wiki, "When Should I Not Use Prevalence" lists three things:
      When you do not know how to program.
      When you cannot afford enough RAM to contain all your Business Objects.
      When you cannot find a Java Virtual Machine that is robust enough.

      That's obviously the stupidest thing ever. How about, "When I don't have the time and money to connect all my company's SQL DB stuff to your java stuff." Obviously my scenario encompasses a whole lot more users than their three, and perhaps explains why no one is using their product.

      What assholes.

      --

      There are no trails. There are no trees out here.
    2. Re:Persistance does not make a DB by Atario · · Score: 1
      could theoretically resolve all the problems associated with OO's rough courtship with Relational databases
      Can someone enlighten me here? There's an incompatibility between OO and RDBMS? How so?
      --
      "A great democracy must be progressive or it will soon cease to be a great democracy." --Theodore Roosevelt
    3. Re:Persistance does not make a DB by angel'o'sphere · · Score: 0, Flamebait


      What assholes.

      I think the asshole is you.
      Either you do not understand what tehy say, or you did not read the article on their site.


      That's obviously the stupidest thing ever. How about, "When I don't have the time and money to connect all my company's SQL DB stuff to your java stuff." Obviously my scenario encompasses a whole lot more users than their three, and perhaps explains why no one is using their product.

      If you HAVE AN SQL DATABASE, then you wont obviously not use prevayler.
      But what if you start writing an application from scratch? No data, no data base, green hills?
      Then read theri wiki and you find reasons why you then may find prevayler excellent.

      Come on boy! /. makes an articel about a "thing" on a website ... with a wiki.

      And you post here: What assholes

      I hope the prevayler guys have an education and are more gentlemen like you .... or it might be your face that get smashed when you accidently meet one of them at a software convent.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    4. Re:Persistance does not make a DB by Delirium+Tremens · · Score: 2, Insightful
      There is obviously a lot of heated arguments here with a surprising lack of scientific objectivity or hand-on knowledge, two things that we usually came to expect from the Slashdot crowd.

      Maybe, it is because many posters violently disagree with certain marketing tactics. God knows they might be forced to tolerate many of them in their professional life. Maybe they just don't want it in their hobby life?

    5. Re:Persistance does not make a DB by Elwood+P+Dowd · · Score: 5, Informative

      I'm not sure what the ACs' problems are. My post has plenty of grammatical errors as well.

      But the point is, in business, not only do we have a SQL database, there are thousands of vendors with products that expect SQL/ODBC databases.

      Sure, if I'm writing something that requires a database, but will never ever have to interoperate with anything else that I haven't predicted, then Prevaylent is in the running. Otherwise, not. Their website is gleefully ignorant of this fact.

      They imply that anyone not using their product is idiotic. They do it many times, and here the poster acts like their relative unpopularity is an enigma. They sound like assholes. I'll stand by that.

      --

      There are no trails. There are no trees out here.
    6. Re:Persistance does not make a DB by RevAaron · · Score: 3, Interesting

      No incompatibility per se, but it's a rough analogy. People often use an SQL RDBMS along with some layer in between it and their OO language, the layer "flattening" objects into rows in the database, and then dynamically reinstantiating the row into an object in that language.

      This is all fine and dandy when you have simple data- a "Person" object filled with nothing but integers and strings flattens fine into an SQL row. But then again, you're kind of just using that object as something not much more than a C struct.

      However, when you have more active objects- which generally arise when you are actually doing good OO design and programming- the interface falls apart some. What if I've got my data objects pointing to other complex objects, rather than just elemental/translatable types like strings, numbers, and dates? What if the state of object A depends directly on what is going on in object B?

      In an OORDBMS translation system, the objects are essentially dead while in storage. Object A can point to Object B - another row in a different database which holds data from a different class- but it dead.

      A good object oriented database, like GemStone (for Java or Smalltalk) allows the objects to remain "alive" while in storage. I have never used or read much about this Prevayler db, so I don't know where it lies. There are some database systems which claim to be an "OODB," but are little more than an RDBMS and an object translation layer built in.

      Not all applications benefit from the OODB methodology, but there are plenty which do. For an OO system which saw some decent design, an OODB is often a good fit. If all of your data is relatively simple- for instance, a customer and parts database on an e-commerce site- an SQL database will probably fit well enough.

      --

      Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
    7. Re:Persistance does not make a DB by Karl+Cocknozzle · · Score: 1
      There is obviously a lot of heated arguments here with a surprising lack of scientific objectivity or hand-on knowledge, two things that we usually came to expect from the Slashdot crowd.

      I love the fact that your sarcasm was modded "Insightful." Hey man, I get you...
      --
      Who did what now?
    8. Re:Persistance does not make a DB by MattRog · · Score: 0, Flamebait

      But the thing is that the RDBMS (which a 'true' one does not exist, of course) using logic and a sound model ensures that your data is safe and correct. This Prevlayer product has none of these and is basically, "We thought this might be neat, but can't really back it up by any sort of sound foundation. Good luck!"

      --

      Thanks,
      --
      Matt
    9. Re:Persistance does not make a DB by dipipanone · · Score: 3, Funny

      or it might be your face that get smashed when you accidently meet one of them at a software convent.

      Damn, that's some seriously un-nun-like behaviour going on in that place. The last thing I want is a smack in the face from Sister Mary Loyola Stallman, Mother Superior Torvalds or any of the other Little Sisters of the Penguin.

      I'm keeping my mouth firmly shut.

    10. Re:Persistance does not make a DB by Elwood+P+Dowd · · Score: 1

      I don't really know what you mean when you say Prevayler can't ensure that your data is safe and correct.

      Their system seems better for those two things. Certainly miles and miles better than MySQL and PostgresQL, for example. Perhaps not much better than Oracle.

      The foundation might be solid. It's the last 10% of features that they'll never get, and will make their product totally useless to the majority of RDBMS applications.

      --

      There are no trails. There are no trees out here.
    11. Re:Persistance does not make a DB by saden1 · · Score: 1

      The only client of your application's data is your application. SQL is a standard, with prevayler the "language" your application speaks is very much proprietary and vague.

      In my opinion the way Hibernate does things is the way of the future!

      --

      -----
      One is born into aristocracy, but mediocrity can only be achieved through hard work.
    12. Re:Persistance does not make a DB by asb · · Score: 1

      I used Prevayler in a test project to see how it works. I became quickly frustrated to the way the objects are serialized. It is nearly impossible to make usable test releases of a program that uses Prevayler. Once the data model changes all existing persistent data beccomes unusable (class inconsistence) and that data is only readable by Java programs.

      But this can be fixed, yay! There are several projects that provide XML serialization to Java objects. This added to Prevayler would improve the system a lot and would possibly make the system more compatible with other languages. Performance would propably degrade (but that's a hardware problem ;-)).

      Or another solution is to write specialized serializers that turn the data model into plaintext or other format. The great thing about Prevayler is the way it works. It doesn't require Java serialization to work. Java serialization just makes it easier to implement.

      --
      Antti S. Brax - Old school - http://www.iki.fi/asb/
    13. Re:Persistance does not make a DB by joib · · Score: 1


      However, when you have more active objects- which generally arise when you are actually doing good OO design and programming- the interface falls apart some. What if I've got my data objects pointing to other complex objects, rather than just elemental/translatable types like strings, numbers, and dates? What if the state of object A depends directly on what is going on in object B?

      In an OORDBMS translation system, the objects are essentially dead while in storage. Object A can point to Object B - another row in a different database which holds data from a different class- but it dead.


      In my experience, hibernate solves these kinds of problems quite neatly, with support for collections, dependent objects and whatnot. I'm sure other OR mappers worth anything do the same.

    14. Re:Persistance does not make a DB by rycamor · · Score: 1

      > I don't really know what you mean when you say Prevayler can't ensure that your data is safe and correct.

      I think Matt is not talking about robustness of memory storage but the integrity constraints one can apply in a relational system, which have never really been possible with any other approach.

      ...and by this, I mean that any system which truly and logically allows one to apply integrity constraints will in the end become a relational DBMS of its own. It's not about SQL per se, but about the application of logic to data management.

    15. Re:Persistance does not make a DB by Zagadka · · Score: 1

      I hope the prevayler guys have an education and are more gentlemen like you

      That seems unlikely, considering their "if you don't know how to program" crack.

    16. Re:Persistance does not make a DB by rbolkey · · Score: 1

      Being completely off-topic (hopefully the moderators will ignore this), but great nick. Favorite movie of all time. Called my homepage "18th & Fairfax" thanks to that film.

    17. Re:Persistance does not make a DB by Elwood+P+Dowd · · Score: 1

      My understanding with their object based design is that it absolutely does allow integrity constraints. It's written in Java. There's got to be a way to ensure that your School object has a Principal, whom must also be in the People table. Or something like that.

      Plus, a lot of these people are comparing Prevaylent to MySQL, which (so far) has none of these features.

      --

      There are no trails. There are no trees out here.
    18. Re:Persistance does not make a DB by Godeke · · Score: 1

      Exactly. Without a query language that can be used universally, I'm going to have a hard time explaining why I chose to store my clients data like this.

      Client: 'Ok, thanks for the system modifications. Wow, it sure is fast now. I'm off to build some reports in Crystal.'
      Me: 'Sorry Sir, but Crystal is old school SQL, only used by losers and drug addicts. Same with your data warehouse and analysis tools. Here, use Java.'
      Client: 'I know how to link tables up in Crystal, not program in Java.'
      Me: 'Well, I guess you will have to pay me to write your reports from now on! Woo hoo! Gotta love monolithic, non-externally queriable data stores!'

      --
      Sig under construction since 1998.
    19. Re:Persistance does not make a DB by Godeke · · Score: 1

      My problem with this isn't the serializer. SQL allows a collection of tools to work together on a single database in a universal way. When asked about querying they say "use a for loop". Sorry, that isn't going to fly: the reason for relational databases is that it creates a mathmatically based model of your data that can be shared between applications, reporting tools and analysis software. The whole point of the relational model is that I shouldn't need a for loop until I have completed the extraction of the data.

      This would be great for private systems, but would never fly in a company with more than a hundred people or so using a system: some are going to want ad-hoc query capability and some are going to want to drill down on the data and some are going to want to post back from other applications. The universal method for this today is SQL against a relational database, because just about any tool can connect.

      The painful part is that they have just pushed the relational/object problem out a bit, not solved it.

      --
      Sig under construction since 1998.
    20. Re:Persistance does not make a DB by RevAaron · · Score: 1

      Above all, hibernate- and other OR maping layers- still put your objects into a relational database. Flat rows, dead objects. Not active. Again, this may not be important, but it depends on the design. Unless you change the database, not just the interface, that'll always be the case.

      --

      Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
    21. Re:Persistance does not make a DB by rycamor · · Score: 1

      Well...

      1) MySQL does have referential integrity, since version 4.0, if you use innoDB tables. Not that I really care, since I use much more capable DBMSs.

      2) Foreign key (referential) integrity is only one small aspect of integrity constraint capability. Of course constraints can be implemented in any application, but they usually most be done in a messy, implementation-centric manner. In general, the idea behind any sort of object store looks very similar to the "network" database model used in the 70s, (which itself was an enhancement of the hierarchical systems that came before that). Essentially, you still have to be concerned about such things as the path from one class to another, and "object IDs", etc...

      Let's forget about SQL for a moment: look at at the relational model itself as a method to allow one to express constraints and data manipulation in a purely logical manner without worrying about how the system actually implements the storage or constraints in the back end. Given that, there is absolutely nothing preventing some clever developer from implementing a relational language interface to Prevayler, which would then make it... an RDBMS. (In fact, that would be quite cool ;-). If that developer were to do it without SQL, but with a truly relational language, such as C.J. Date's "D", that would be even cooler)

    22. Re:Persistance does not make a DB by joib · · Score: 1

      Um, could you clarify what you mean by "active" vs. "dead" objects?

      I meant that with hibernate, if I have a persistent class, say

      class Foo {
      Bar B;
      // setB and getB methods
      }

      I don't need to explicitly manipulate B through the hibernate API, it works transparently. Eg. if I have loaded an object of the class Foo (say foo), I can access B directly

      foo.getB();

      Depending on how you configure it, B is loaded at the same time as foo, or it is backed by a proxy and loaded only when it is accessed for the first time.

      Of course, being backed by a RDBMS, fancy shit like runtime addition of properties to a class etc. possible with e.g. metaclass hacking in python or MOP in LISP aren't possible. Anyway, if your requirements are on this level, I think Java is the wrong choice for implementation language (aspectj etc. notwithstanding).

    23. Re:Persistance does not make a DB by William+Tanksley · · Score: 1

      the integrity constraints one can apply in a relational system, which have never really been possible with any other approach.

      Obviously untrue -- constraints are possible in ANY system. What's interesting is that the contraints in relational systems are designed to allow them to consistently model objects; and object systems _always_ model objects consistently. Thus, contraints in the relational sense are unneeded. (Other types are needed, of course.)

      -Billy

    24. Re:Persistance does not make a DB by rycamor · · Score: 1

      Se my other comment in response to Elwood P Dowd.

      I wasn't talking about any type of integrity constraint, but specifically the type of "integrity constraints one can apply in a relational system", as I said in my original post. Specifically, I mean that in a relational system one can apply integrity constraints in a declarative, relational manner. Ergo, if any other database system became able to apply such integrity constraints, it would become relational. And: 1) true integrity constraints are not the same as modeling objects consistently. 2) SQL itself is only a halfway solution to declarative integrity constraints. 3) "Business rules" systems might be considered an example of the application of declarative integrity.

    25. Re:Persistance does not make a DB by exhilaration · · Score: 1
      'Sorry Sir, but Crystal is old school SQL, only used by losers and drug addicts.

      DAMN that's funny! :)

    26. Re:Persistance does not make a DB by William+Tanksley · · Score: 1

      I wasn't talking about any type of integrity constraint, but specifically the type of "integrity constraints one can apply in a relational system",

      Have you considered the type of constraints you CANNOT apply in a relational system?

      Specifically, I mean that in a relational system one can apply integrity constraints in a declarative, relational manner. Ergo, if any other database system became able to apply such integrity constraints, it would become relational.

      This is either a useless tautology or a terrible non-sequitur, depending on whether you want it to be useless but true or useful but false. Yes, if you do things relationally I suppose you're relational; but that's not the only way to do things.

      -Billy

    27. Re:Persistance does not make a DB by Anonymous Coward · · Score: 0

      Either you do not understand what tehy say, or you did not read the article on their site.

      Well, I didn't read the article, but I did see the copy/paste someone put up where they listed 3 reasons you wouldn't use their product (and also followed the link to make sure someone wasn't posting a select few to make them look bad). They don't say to not use it if you HAVE AN SQL DATABASE. So, either the authors forgot to mention that they don't think anybody should migrate their SQL database over, or they disagree with you.

      And then, from right below that section in their wiki, somebody asks, "What if my boss or my peers are too scared to use Prevayler?" And their reply? Find a better job. :-) Now, this answer is an answer an asshole will give. It's not productive at all. It's a perfect chance to espouse the many benefits of their product, but instead they tell the interested party to quit their job. Yeah, real nice. And if the smiley means it was supposed to be a joke, then they're not assholes, they're idiots (for giving up a good oportunity to convince others that their product is a good thing, even if that just means posting a link to some other page where they already do that).

      Also, if they truly think they've made RDBMS obsolete, they need to step up and address the technical questions being presented. Otherwise, claiming the be the end-all and be-all is 1) stupid, and 2) something a total ASSHOLE would do. And the thing is, the main issue isn't even whether they're right or wrong. It's the attitude they're displaying. (Of course, there has been much research in relational databases, and if they can't rigorously prove that their system is better in some way, then nobody is going to trust millions of dollars do an unknown (i.e. not backed by big business) database that might lose their data).

      -Tim, the AC Poster Child

  8. Nice press release by PCM2 · · Score: 4, Funny
    Prevayler Quietly Reaches 2.0 Alpha, Bye RDBMS?
    "Quietly," eh?
    --
    Breakfast served all day!
    1. Re:Nice press release by Delirium+Tremens · · Score: 1

      Yeah, it sounds like ninejaguar (the guy who submitted this story) has a vested interest in Prevayler.
      Hey, even his nickname is suspicious.

    2. Re:Nice press release by Anonymous Coward · · Score: 0
      Sorry for the long delay in answering you DT (I saw your other posts, and appreciate your contributions), I've been busy trying to dig some insight from most of the noise. You know, swimming through the posts and navigating between the crock-o-shitters and patiently-pedantic-gurus, and everything in-between. I also apologize for posting this as AC. I can't seem to login and post without removing the points I've given to posts that clarified a few things for me (it wouldn't be fair to them).

      In anycase, I'd like to clarify a few things myself:

      1. I'm in no way affiliated with the Prevaylent project, and simply found it yesterday on Slashdot. I did find out something interesting. The product apparently has less than 600 lines of code! So much discussion over so little leads me to believe very few people actually bothered to look over the source before posting an opinion on it.

      2. Slashdot won't allow me to post booksized articles, so I had to cram as many questions as I could into that first paragraph (sadly, none of them were answered). The side-effects were two: an awful marketoid writing-style, and a highly polarized discussion of the subject (I don't mind the second effect at all as it's certainly been lively). You'll notice that the style of the 2nd and 3rd paragraphs is quite different from the 1st.

      3. I have yet to see a question from a Slashdotter regarding the product that hasn't already been answered either in the wiki(have to dig for it) or articles by the product's author. I doubt any product is that good, so I place the blame on Slashdotters (including myself) for not being more original.

      4. What is so "suspicious" about my nickname? Please, I don't wish be involved in conspiracy theories. :-)

      I'm sincere in my attempt at finding out the answers to my questions. Unfortunately, due to the inability to post under my pseudonym without taking points from others, you may doubt that is really ninejaguar's reply. If so, ninejaguar could at any time post under that pseudonym and claim this reply to be false (I promise, that won't happen).

      If you have any questions for me, I'd be glad to try and answer them. Don't be too disappointed if I don't have a satisfactory answer; I'm still a slashdotter afterall. In the meantime, I ran across this link in another AC's post. Has some more answers regarding this Prevayler.

      = 9J =

    3. Re:Nice press release by Monty · · Score: 1

      In defense of slashdot, this project is interesting, but like everyone else has been saying, these guys need some serious PR lessons. And while our behaviour might not be all that dignified, it's only in reaction to their blatant and shameless over-hyping which clouds any technical value their product actually has.

      What's more is that the project lead has unsuccessfully trolled dbforums before. Here's some nice quotes:

      Some people like tables, some people like objects. Were you at least convinced that Prevayler is an ORDERS OF MAGNITUDE faster and simpler OBJECT persistence mechanism than using ANY relational database for that?
      Prevayler - TRANSPARENT persistence for Java. 9983 TIMES faster than ORACLE. 3251 TIMES faster than MySQL. I would not believe it if I were you. But I would take a look: http://www.prevayler.org

      You can probably google him and find more.

      Probably seems ad hominem to point out someone's trolling tendencies, but read some of the threads he's participated in and the responses point out that Prevayler is nothing but a persistent object store with a transaction log all stored in RAM for speed. Does this replace an RDBMS? No. As said many times here, they each serve different purposes and each have different features and drawbacks. Promoting either as a THE data solution is foolish. RDBMS's give you advantages like physical and logical data independence, full transactional support and unlike Prevayler, include a query language to access and modify your data. If you need any of these features, then go with RDBMS. Prevayler mainly gives you a natural (from an oop view) and quick way of having objects persist, and using it as a simpler model than the relational one to build an OO app around, with the drawbacks that things like referential integrity and queries are largely for you to handle.

      That said, what of your questions has remained unanswered?

      • Is anyone currently using this non-database solution in production? I'd say the lack of comments answering in the positive would make that a no, or at most possibly yes, but it's a secret.
      • Was there a significant learning curve to speak of? That's difficult when it's tied to the above. Although the Zodb thread gives hints on the learning curve of doing queries over the object store.
      • Is anyone considering using it in a transactional environment where speed is the paramount need? Again, silence says no.
      • And, are there any objections to using Prevayler that haven't been answered at the Prevayler wiki? Google is your friend, but if not then try this advogato article here that covers some nice discussion about Prevayler, although a little outdated.
      • ... Is Prevayler a better way? Again, as its been said many times already, it depends on your app. However it's notable that OO to relational are not as disparate as one might believe, see here. Enterprise Objects are a good counter-example, but by all means probably not the only one to your statement.
    4. Re:Nice press release by arkanes · · Score: 1
      I was really excited when I read this article because using an RDBMS for persistent data storage has always pissed me off - it seems like a useless waste of cycles to write code that converts my in-memory binary data format to SQL code, so that the DB engine can parse the SQL (expensive) and turn it into an in-memory binary representation. A direct object to table mapping without the SQL interface is what I've been looking for.

      Prevalence might even be usefull (but I'm not a Java programmer), but the fact that they're selling it as a replacement for an RDMBS is just silly. It's (arguably, but very likely) a better solution for object persistence than using MySQL or whatever. It certainly won't hold up for massive data storage though, and I'm sure that's not even what it's really for.

    5. Re:Nice press release by William+Tanksley · · Score: 1

      the fact that they're selling it as a replacement for an RDMBS is just silly.

      It is and it isn't. It's not a replacement for a RDBMS; but it fits in many areas where a RDBMS has traditionally been used, but isn't actually a good idea.

      It also fits in many areas where NO persistance is currently used: for example, word processing.

      -Billy

  9. Huh? by KyleW · · Score: 0

    What's so complicated about OO with RDMS? Just use EJB or buy/write your own object relation mapping library. This is a crock. I predict object oriented databases will fizzle and die in 3 days.

    --
    1st known failed CIA coup in South America : http://www.chavezthefilm.com/index_ex.htm
    1. Re:Huh? by jonfelder · · Score: 0, Flamebait

      I believe "take control of Iraq's oil supply" would be the answer to step 2.

      Another possibility would be, "receive kickbacks from the $150 billion+ spent on the war".

  10. Can't be done by Anonymous Coward · · Score: 0, Funny

    One of my coworkes will explain to you that such a project is impossible. He's an idiot.

  11. Here's why by Anonymous Coward · · Score: 5, Insightful

    A direct quote from your Wike:

    Prevalence requires us to have enough RAM on our servers to contain all our business objects.

    What do you do if you have a nice big data set that won't fit in memory? Businesses my company works with have millions of customers. Do they have to have all those gigabytes of data in memory to do anything?

    Don't come at me with yet another memory resident thing that's supposed to be the greatest ever, when it doesn't come close to addressing the real needs of a database user.

    1. Re:Here's why by zekt · · Score: 4, Funny

      Yeah we have a backup strategy... we have another machine sitting next to it with about 20 gig of memory..

      --
      In my next incarnation, I hope to come back as a code monkey.
    2. Re:Here's why by Fr33z0r · · Score: 1

      Well said, I have probably 10 databases here ranging from a few hundred k to about 5gb with most falling at the upper end of that scale, I'm not about to go installing spamware posted on slashdot to make the dinky ones run 3000x faster and leave the ones with hundreds of thousands of records running at less than half the speed.

    3. Re:Here's why by JUSTONEMORELATTE · · Score: 2, Funny

      Oh, no problem. I'll inform my (contract) employer that they'll have a much faster system when they switch. The only hangup is that they'll need a box with 30 gig of RAM to do it.

      Tell me again why this is better than SQLServer using a data file on a RAMdisk?
      No, really. Tell me how this is better than a Microsoft solution, 'cause the astroturfing article didn't do it yet.

      --

    4. Re:Here's why by Lucas+Membrane · · Score: 1
      Everyone wants to plan to be a success. If your company grows like crazy, and you run out of memory at the critical moment, what do you do? Scrap the database and rewrite everything at the worst possible moment? Nah. Use a real RDBMS.

      This is a good idea in one way. It ads usefulness to that little green light on the front of your computer. It now means "Your database might not have died yet."

    5. Re:Here's why by Anonymous Coward · · Score: 0


      Tell me again why this is better than SQLServer using a data file on a RAMdisk?
      No, really. Tell me how this is better than a Microsoft solution, 'cause the astroturfing article didn't do it yet.


      ho-hum ... all nice and dandy, but barring a win for itanium what ms solution do you have that can access 30G of ram, to use your own example? (and I mean 'living' solution, not the alpha thingie that's unsupported now).

      which brings about a different point - it's pretty useless for a x86 server. go figure.

    6. Re:Here's why by g_braad · · Score: 1

      Is that supposed to be Swap space or Physical memory ;oP)))

      --
      F/OSS & IT Consultant
    7. Re:Here's why by keester · · Score: 1

      DB's hold data in memory. Then swap it out as it reaches some maximum. Prevayler could be setup to do the same. I'm not arguing for or against it, but you're not really saying anything here.

      --
      Take it easy? I'll take it anyway I can get it . . .
    8. Re:Here's why by AVee · · Score: 1

      What do you do if you have a nice big data set that won't fit in memory?

      Did you ever tried to calculate how much memory you can get for the price of an Oracle database?

    9. Re:Here's why by ninejaguar · · Score: 1

      Actually, I hadn't. You're absolutely right, it would be incredibly cheap in comparison to the insane Oracle licensing costs. Naturally, you'd have to consider where the memory would go (a cluster would be nice). = 9J =

  12. Whoa wtf by Breakfast+Pants · · Score: 5, Funny

    I'm glad I'm not a subscriber right now cause if you payed to have the advertisements removed I don't think it would have caught this one.

    --

    --

    WHO ATE MY BREAKFAST PANTS?
  13. What a crock of shit by Anonymous Coward · · Score: 1, Insightful

    Big fucking deal. This is all in-memory querying from the same process. What about querying from another process or across a network from another machine?

    1. Re:What a crock of shit by angel'o'sphere · · Score: 0, Troll

      CORBA?
      SOAP?
      RMI?
      Sockets?

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    2. Re:What a crock of shit by Anonymous Coward · · Score: 0

      So you expect the users of this two bit memory persistance hack to code up their own inter-process/inter-machine communication layer? That's fucking idiotic. What about maintaining consistant data over the network? You ever think about that? You're going to create your own XA protocol and distributed two phase commit as well? It's better to use a real database that has real client APIs for all these common tasks.

      Angel'O'Sphere - I expected better from you. Your posts are normally quite insightful, but not this time.

    3. Re:What a crock of shit by TummyX · · Score: 1

      Uh no. With RMI (or any other remote method call protocol) they don't need to write their own IPC protocol. They can just call objects as if they were local. What the hell is wrong with you?

    4. Re:What a crock of shit by Anonymous Coward · · Score: 0

      RMI is not a database client protocol. Database inserts (for example) require much more than this to function correctly. Like Two Phase Commit. You could build something on top of RMI, but RMI itself buys you nothing in this case. But don't let silly things like "facts" get in the way of your argument. Please continue making an ass of yourself.

    5. Re:What a crock of shit by Delirium+Tremens · · Score: 1

      RMI doesn't come with transactional support. JRMP doesn't have it either and IIOP support in the JDK doesn't ship with an OTS or JTA implementation. What the hell is wrong with you?

    6. Re:What a crock of shit by TummyX · · Score: 1

      WTF? Even with a database API you need to enter and exit a transaction by calling enter() and exit().

      Whether you call those methods (enter & exit) over RMI or locally is irrelevant.

      And the implementation would simply be done using a java monitor.

      Duh.

    7. Re:What a crock of shit by Delirium+Tremens · · Score: 4, Insightful
      I am probably going to be considered pedantic with this, but usually people refer to begin and commit. Sometimes, they use rollback too. It's not enter() and exit(). And it's not please() and letsGo() either.
      That being said, the other gentlemen in this thread are talking about Two-Phase Commit. Yes, I do understand that Prevayler doesn't even have one-phase-commit to provide things such as Isolation, but that's beside the topic discussed in this thread. So please, let's both stop referring to it. Even if one-phase-commit can be implemented over RMI. But if you want to really simplify this issue to the extreme, you need to tell us how Prevayler handles rollbacks. After that, you could maybe explain to us (and to the RMI engineers at Sun) how to implement the Two-Phase-Commit protocol over RMI with a data store like Prevaylers that is not XA-compliant.
      Thank you for playing(*).

      (*) I told you I was going to be pedantic.

    8. Re:What a crock of shit by Anonymous Coward · · Score: 0

      Yeah, seriously, WTF is this shit?

      Summary:
      "Okay, but it's not a SQL query vs. SQL query comparison."
      "Well see, we could write a query in Prevayler, but you can't test MySQL without a SQL query. (cute winky face!)"
      "Okay, so write a SQL implementation for Prevayler, then do a SQL query vs. SQL query comparison."
      "You need to think outside the box, man. Anyways, the test is fine, because it was done on different systems."

      I mean, WTF?

    9. Re:What a crock of shit by eidechse · · Score: 1

      Please continue making an ass of yourself.

      That's rich coming from someone whose implying that all transactions should be distributed and use two phase commit.

    10. Re:What a crock of shit by TummyX · · Score: 3, Insightful

      The objects are in memory. You implement the locking mechanisms yourself in your object model.

    11. Re:What a crock of shit by Anonymous Coward · · Score: 0

      That's rich coming from someone whose implying that all transactions should be distributed and use two phase commit.

      Get with the program. We are discussing how this Java "database" library could distribute transactions across a network and still maintain integrity. You need two phase commit for such transactions. RMI by itself is not a solution. In any event - the programmer ends up coding all the communications layer himself. How is this progress?

    12. Re:What a crock of shit by eidechse · · Score: 1

      Go read their faq. They claim that transactions are unnecessary. I don't know that I buy in to their pitch but they have already answered your critiques.

    13. Re:What a crock of shit by julesh · · Score: 1

      How does "the programmer end up coding all the communications layer himself" if RMI is used as a communications layer?

      We are discussing how this Java "database" library could distribute transactions across a network and still maintain integrity. You need two phase commit for such transactions

      Or you need to simplify the transactions to the point that you specify a single command, which includes an implicit decision on whether or not to commit. That is, all the logic of the transaction must be known to the server before it begins executing.

      This is equivalent to sending a message to the server that says something like "if record x hasn't been updated since time t, change record y by setting field f to the result of expression e". There is no need for a two phase commit if you express all of your transactions with this kind of logic. Integrity is still maintained.

    14. Re:What a crock of shit by Chazmyrr · · Score: 1

      You assume that transactions can/should be simplified to that point.

      Lets consider an overly simplified sales transaction. You can update your inventory before or after you obtain authorization for the credit card. Without a two phase commit, you will have authorize the card before you update the inventory. If the inventory operation fails, you will then have to reverse the authorization unless you want to piss off your customer. With a two phase commit, you perform the inventory operation first but do not commit unless the authorization is successful. Two phase commit is preferable in this situation.

    15. Re:What a crock of shit by Anonymous Coward · · Score: 0

      DEAR GOD ALMIGHTY!

      And we might as well reinvent the wheel, and abandon use of libraries to do IO.. and heck even high-level languages while we're at it.

    16. Re:What a crock of shit by William+Tanksley · · Score: 1

      Thank you for playing(*).
      (*) I told you I was going to be pedantic.


      Well, your message was pedantic (thank you, I appreciate your efforts to instruct in fine detail, and although they missed the point I believe the distinctions you draw are useful), but that last quip wasn't pedantic; it was merely condescending. Just thought I'd mention the difference.

      I also need to mention that Prevlayer does provide isolation, even without one-phase-commit.

      Rollback is handled by Prevlayer, in a slow but effective way (by resetting and replaying up to the failed operation). There are two causes of rollback: first, a failed atomic operation; and second, an undo of one or more operations as part of an unforseen larger-scale event. Of course, it's also sometimes possible to include "inverse commands" in the set of prevalent commands; such a trick would allow much faster rollbacks for any command which actually had a defined inverse.

      -Billy

    17. Re:What a crock of shit by TummyX · · Score: 1


      Sometimes, they use rollback too. It's not enter() and exit(). And it's not please() and letsGo() either.


      Well I was thinking of monitors at the time and spat out not so accurate terms wrt transactions. So sue me.

    18. Re:What a crock of shit by julesh · · Score: 1

      The essential idea of simplification to this point of view is that you ensure that everything will work before making any changes. So in your example, you would check for all the possible error conditions that would prevent the inventory update from succeeding before authorising the card.

      However, this doesn't really fit in with the entire model used because one requirement is that all state information modified by a transaction must be stored within the same system, otherwise replaying the transactions to recover from an error will not work correctly (i.e. the customer would be charged twice!).

      I'll agree, its not suitable for all purposes. And if you need to span data that's stored in two separate locations, well tough luck really. But for many other purposes, its fine (i.e., if you really wanted to, the credit card authorisation system could work using this scheme).

      (BTW: with a traditional PDQ style credit card authorization, this is a non-issue. The authorization is just a check that the transaction won't be bounced, but doesn't change any data. The data is only updated when the signed paper is submitted. So this system actually can be used in the described situation in reality.) (Yes, I have noticed the irony in the fact that I've just described the fact that credit card authorisation effectively uses a 2 phase commit system).

    19. Re:What a crock of shit by sergio.garcia · · Score: 1

      RMI + synchronized methods. It takes a few more lines than programming a regular object. You really have no clue, go read the documentation.

      --
      "Agree with them now, it will save so much time."
    20. Re:What a crock of shit by Anonymous Coward · · Score: 0

      No. If you find a finer solution for a certain family of problems (i.e. prevayler only works if you can keep all your data in memory), why not using it. It is easier, it is faster. Go read their documentation, and come back with real arguments.

  14. Answers to your questions. by Anonymous Coward · · Score: 1, Funny

    Is anyone currently using this non-database solution in production?
    Hell no! Are you stupid?

    If so, has it sped development because of the lack of OO-to-RDBMS complexity?
    No. Reduced complexity? Are you smoking Crack?

    Was there a significant learning curve to speak of?
    Is, not was, there a significant learning curve? Hell yea. Take everything you know and throw it all out. Then learn this new backwards system and in the end you have a worthless pile of crap.

    It's no wonder that everyone is jumping on the bandwagon. NOT.

    1. Re:Answers to your questions. by jonabbey · · Score: 3, Interesting

      Hell no! Are you stupid?

      I might be.. we use an in-memory Java objectbase solution for Ganymede.. when coupled with an on-disk transaction log, we get extremely high performance, transactional integrity, and the ability to run wherever there's a Java VM.

      While I wouldn't claim that this kind of solution will scale indefinitely, it works very well indeed for our application and our dataset size.

      It's not Prevayler, though, so I can't comment on his API or code quality.

  15. Oh, ye hater of linux and true developers... by Anonymous Coward · · Score: 0

    know that we of slashdot have voted
    ye off the proverbial island, that ye
    have been deemed rightly to have failed
    in your quest for heterosexuality, and
    have indeed been generally guilty of
    faggotrous acts. Standing hereby, we
    request that your ignorance of said software
    be rightly punished by the general population
    incarcerating you at the Grand National
    Ancient American house for a period of no
    less than thirty days, or the length of time
    required for windows to be uninstalled from
    your home computer and a fat black cock
    shoved up into the roof of your mouth,
    or something. Besides, pet project to you
    probably involves a hamster wheel and a cucumber.
    Too bad you already pulled that one off in
    seventh grade science class. Except your teacher
    was the cucumber.

  16. Re:Answers to your questions. MOD UP by Anonymous Coward · · Score: 0

    You took the words right out of my mouth.
    It must have been while you were kissing me.
    -Meatloaf

  17. 3000 times faster is somewhat misleading by Xeger · · Score: 5, Insightful

    If you could cache an entire MySQL database in RAM, I'm sure your MySQL performance would improve dramatically.

    If you could then optimize MySQL's search routines for working on memory instead of disk blocks, your MySQL performance would improve even more dramatically. As it is now, MySQL must go through all sorts of contortions, probably using B-Tree-like structures for indexing, and other fanciful datatypes I can't even conceive of without a PhD. The reason for all of this silliness is the fact that MySQL's backing store is disk, not memory.

    In a prevalence system like Prevayler, one of the fundamental tenents of the system is that ALL of your objects are ALWAYS in memory, and are only serialized to disk when they change, for persistence.

    So...yes: as always, a memory-based system will be three orders of magnitude (or more!) faster than a disk-based system. Prevayler vs. DBMS is no exception to this rule.

    But when your website has grown popular, your prevalance database has swelled to 30 gigs and you find yourself hosting it on massive systems with 12 gigs of core memory and another 30 gigs of swap space -- when your memory access times are starting to look like disk access times because of swapping -- well, don't come crying to mwe.

    Prevalence is a brilliant solution, for small projects. But they only scale to the size of your physical memory, or slightly (50-100%) larger. You can't expect them to scale beyond that.

    1. Re:3000 times faster is somewhat misleading by 693746 · · Score: 2, Insightful
      If you could cache an entire MySQL database in RAM, I'm sure your MySQL performance would improve dramatically.

      For what it's worth, 5th sentence on the Prevayler web site is:
      These hoax-like results are obtained even with the Oracle and MySQL databases fully cached in RAM and on the same physical machine as the test VM.
      That said, I think the Prevayler developers would agree with you. They are suggesting Prevayler as a good solution in situations where you:
      • have enough RAM to hold all your business objects and
      • only need to access your data from Java.
      Of course it will suck if your project doesn't fall in those categories. Everyone can see that.

      Erik

    2. Re:3000 times faster is somewhat misleading by Xeger · · Score: 4, Interesting

      Thank you for the clarification.

      I'm sure that, with its entire database cached in memory, MySQL's performance *does* improve dramatically. But it's still using maladapted algorithms for doing all of its queries -- the poor algorithms think they're reading blocks from a disk, not pages from memory. And of course every time the MySQL process performs a "disk" read, control reverts to the kernel and the process sacrifices the rest of its quantum. So MySQL will never be able to take full advantage of the fact that it's running with a memory backing store.

      My point was simply that Prevayler is naturally going to be much faster than a MySQL database, because one of them is dealing with RAM and the other is dealing with disk. Hence, comparing Prevayler and MySQL performance is like comparing apples and oranges.

      We're agreed that Prevayler is very useful, provided that your application fits its memory and reliability constraints. Thus, instead of distracting us with how much faster their orange is than the MySQL apple, they should spend their time evangelizing the "orange" way of doing things.

    3. Re:3000 times faster is somewhat misleading by MattRog · · Score: 1

      The fact that MySQL is 'dumb' has nothing to do with the absurdity of this product (and the 'RDBMS is dead' arguements).

      Most modern-day SQL DBMS have DBMS-controlled data caches which store commonly accessed (generally on a MRU/LRU basis) data whose access is controlled by proper costing algorithms.

      It's far easier to do it the MySQL way (assume the OS will cache it) but not nearly as powerful.

      --

      Thanks,
      --
      Matt
    4. Re:3000 times faster is somewhat misleading by Anonymous Coward · · Score: 0

      The basic assumption of Prevayler is that we will all have huge amounts of RAM soon, changing the programming paridigm of data storage.

      By that logic you might as well assume that we will all have huge amounts of NV-RAM soon, and if that's true, wtf is the point of Prevayler again?

    5. Re:3000 times faster is somewhat misleading by ajs · · Score: 3, Insightful

      You're missing the point.

      Your system might be fine for my project TODAY, but what happens when I've tied my project to ITS funky interface and TOMORROW, I find that my data-set has grown to a size that is not managable in-core?

      Do I have an easy out, or do I re-write my whole application?

    6. Re:3000 times faster is somewhat misleading by Xeger · · Score: 1

      Didn't I just say that Prevayler will only work for applications whose entire database will gracefully fit into core (plus some swap)?

      I'm not trying to explain why Prevayler is "better" than a DBMS in this thread; I happen to think it is *not* better, except for small applications that aren't expected to scale up. My argument is that the statement "Prevayler is 3,000 faster than MySQL" is misleading.

      But, to answer your question, you do have an easy out. Since the entirety of Prevayler support in your application involves only a few dozen function calls, you remove those few dozen calls from the app then switch to using Java Data Objects, or perhaps find a native OODBMS. They do exist.

    7. Re:3000 times faster is somewhat misleading by baka_boy · · Score: 1

      You write a translation script, the same way you would handle the move to a new production schema, or from one RDBMS vendor to another. And of course, since anyone so concerned about future-proofing their code would insure their business logic is using a nice polymorphic OO design, you'll be no more vulnerable to a change from Prevayler to JDO or another O/R mapping tool than you would be to schema changes.

    8. Re:3000 times faster is somewhat misleading by Anonymous Coward · · Score: 0

      The funniest thing is that computer architectures may tend to non-linear access ram in the future, necessitating disk-style algorithms for memory access.

    9. Re:3000 times faster is somewhat misleading by Anonymous Coward · · Score: 0
      This would fit perfectly for small departments that are forced to share server resources due to budgetary/administrational constraints. Most (not all) small departments don't generate enough data to worry about throwing it all in RAM (I've seen dozens of accounting departments use less than 200 mb of sql server space).

      And, think about this, a clustered Linux server could literally expand as the need arises. Just slap on another cheap desktop with a Gig of RAM and you could support another department. Persist to a disk array or SAN every hour (the wiki claims you don't have to halt the server to store to the hard drive for backup).

    10. Re:3000 times faster is somewhat misleading by .tom. · · Score: 1

      While I do agree with your conclusion, one thing is important though : they compared with a MySQL database which tables where actually all in RAM.

      So I would say that this kind of persistence can be very nice for small/medium databases; but I guess you're right, there is some problem when your database is getting bigger (comparable to your RAM).

    11. Re:3000 times faster is somewhat misleading by blancolioni · · Score: 1

      And of course every time the MySQL process performs a "disk" read, control reverts to the kernel and the process sacrifices the rest of its quantum.

      I don't know how this is implemented in MySQL, but reverting control to the kernel is not inevitable.

      You ask for a particular page, and if it isn't in memory, then you go to disk. Otherwise, you get the page immediately. The only slow down is the extra mapping required, though it's trivial to set things up so that this is pretty close to zero if the database is smaller than available memory.

      When doing a key search, it's true that the normal algorithms are optimised for minimising page reads, which may result in slightly worse performance. But not by much.

      So I suppose my point is that Prevayler's assumptions do not lead it to be naturally faster than MySQL by more than a trivial amount.

      (I've been involved in the implementation of two databases, neither of which you've ever heard of)

    12. Re:3000 times faster is somewhat misleading by Anonymous Coward · · Score: 0

      MySQL went from 2.8 times faster to 3000 times slower when JDBC was used.

      This tells me that JDBC will make my apps run 8400 times slower.

    13. Re:3000 times faster is somewhat misleading by keester · · Score: 1

      Depends on how you wrote your system. Basically, you would need a layer between prevayler and your model, such as a DAO -- if you're not familiar with that, search sun's j2ee design patterns.

      --
      Take it easy? I'll take it anyway I can get it . . .
    14. Re:3000 times faster is somewhat misleading by Xeger · · Score: 1

      Page reads or block reads? If one is talking about virtual memory, then one speaks of pages (which have been swapped out into disk blocks); else one normally speaks of blocks on disk.

      No problem if you've decided to use nonstandard terminology. I only ask because I want to make sure you're thinking of disk access and not virtual memory, which is a different beast.

      The Linux kernel is smart enough by now to do read-ahead caching of disk blocks; in that case, if what you've said is true, a memory-mapped file or a RAM disk will tend to act more like memory than disk.

      I haven't looked at the kernel code lately, so I'll take your word for it that asking for a block read does not always suspend the process.

      I think we're both arguing the same point: that Prevayler is not much faster than MySQL, except by virtue of the fact that its database resides in RAM. I was just trying to explain the 300,000% discrepancy between the claimed speed of Prevayler and the speed of MySQL with a RAM backing store.

    15. Re:3000 times faster is somewhat misleading by ajs · · Score: 1

      Sounds like you're saying that I shoudl take a leap of faith that my application which fits in core today won't have to scale... no thanks.

    16. Re:3000 times faster is somewhat misleading by ajs · · Score: 1

      "anyone so concerned about future-proofing their code would insure their business logic is using a nice polymorphic OO design"

      First off, I just asked about scalability to data-sizes greater than core. I don't even see that as ADEQUATE concern over "future-proofing", much less going out of my way.

      Second, just because I have a "nice polymorphic OO design" doesn't mean my application is simple or that re-writing that layer will be painless. Unless this database design has significant wins OTHER than being memory-resident only (which is IMHO a drawback, but a survivable one), then I don't see what it has going for it other than being the new kid on the block.

    17. Re:3000 times faster is somewhat misleading by ajs · · Score: 1

      Such indirection comes at a cost.

      If you use Oracle and your database fits in-core you can tune it so that Oracle only writes to disk to commit the logs (which is a linear append) and to occasionaly synchronize the in-core version of the database (which is a block memory-to-disk transfer that the OS can optimize very nicely). This gives you much of the performance benefit of the in-memory only database, preserves scalability, is language neutral and doesn't require heavy indirection in order to move to another database later.

      I'm not a big fan of Oracle, but if I needed it, I'd use it, not a shoestring memory-manager.

    18. Re:3000 times faster is somewhat misleading by keester · · Score: 1

      I know what you're saying, but DAO has little to do with a shoestring memory-manager -- which has it's own merit. E.g., you need a shoestring memory-manager -- I know I'm begging the question at this point. (thanks someone's post from yesterday) All I'm saying is that, if you want to start with prevayler and later switch to an rdbms it's not that hard to design it to work like that. The cost is minimal, really. If you look at that pattern you'll see that.

      --
      Take it easy? I'll take it anyway I can get it . . .
    19. Re:3000 times faster is somewhat misleading by ajs · · Score: 1

      I wasn't talking about DAO, I was talking about the database that the article refered to. I consider it a shoestring memory manager, which is interesting in so far as it goes. I'm not dissing their hard work, just the bozo who thought he'd get the project noticed by casting it as a mysql-killer in a Slashdot article submission.

      What's more, I was pointing out that any abstraction layer will come with a cost (not bad per se). So, I'd rather get a giant abstraction layer (Oracle) get those costs out of the way early and THEN worry about my app.

      If I find that I'm constrained by the database's throughput, I might well choose to use something like this as a cache store and perhaps as a caching proxy for writes. But, that happens after you get the application working. Anything else is premature optimization, and is thus the enemy of efficient development.

      Now, in general, I'll ACTUALLY choose MySQL because I don't care about database performance enough to buy a giant machine that I can stuff the entire DB into RAM on (which is the only way Oracle outperforms anything). MySQL is fast in the normal case, far easier to admin, flexible in terms of which features I want to suffer performance penalties for or not and in my 5 years or so experience with it, rock-solid in every case except total media failure (Oracle has burned me several times just because the machine it was on crashed, which is not supposed to be possible, but there it is).

    20. Re:3000 times faster is somewhat misleading by blancolioni · · Score: 1

      Yep, block reads, sorry. My point was that the block read doesn't happen if it already resides in memory, so there's no question of it going to the kernel. I'm not talking about the kernel's disk block cache, but the database application's. Whether MySQL implements this sort of caching, or whether it relies on the OS, I don't know. It's clear that the latter technique will lead to performance degredation.

      I understand, from further reading, that Prevayler uses hashed lookups. This is clearly faster than a tree search, but not useful for partial key searches or key scanning.

      I think we're both arguing the same point: that Prevayler is not much faster than MySQL, except by virtue of the fact that its database resides in RAM. I was just trying to explain the 300,000% discrepancy between the claimed speed of Prevayler and the speed of MySQL with a RAM backing store

      Yep. I think a hash table instead of a B tree would account for the difference, but that's such a particular case (retrieve the record with this exact key) that to me it seems worthless as an indicator of general speed.

    21. Re:3000 times faster is somewhat misleading by Xeger · · Score: 1

      I wonder if the only sort of indexing they apply is a hash. Seems like that would rather limit the power of their query language.

      If I were implementing an in-memory DBMS, I'd keep several indices of every "primary key" for a table. A hash table, for equality and membership tests. A balanced search tree, for comparison and sorting. Maybe others.

      Of course, if I understand Prevayler's approach, any bean property can serve as a key -- that means indexing all of the properties. That'll eat quite a bit of memory, in addition to all of the objects already filling core memory.

  18. Broken link by Otter · · Score: 3, Informative

    Correct link for the previous Slashdot article -- important, since it provides the lucid, straightforward explanation of what the hell this thing actually is that today's pointless-link-filled, cutesy bit of Astroturfing neglects to offer.

    1. Re:Broken link by untulis · · Score: 1


      And the broken 1.x link and the differently broken, but still redundant 2.0 alpha link... wow, you'd think you might actually try links out before you publish something. Oh right, I'm reading /. Who was I kidding?


      Why should I "Check those URLs!" when slashdot editors (and/or "ninejaguar") don't know how to? Second graders do a better job of proofreading...

  19. Modding of Articles by OYAHHH · · Score: 5, Funny

    I'm,

    Not sure what the proper term for referring to the articles that appear on Slashdot should be but I can say that this article is about the worst I've ever seen in terms of promoting a pet project.

    Slashdot needs to go one step further with it's moderating functionality.

    Slashdot needs a way that crappy articles like this one can be moderated into the bit bucket and I don't have to see it anymore!

    --
    Caution: Contents under pressure
    1. Re:Modding of Articles by batkiwi · · Score: 4, Informative

      Not to start the crosssite flamewars, but you're looking for http://www.kuro5hin.org/

      or another slash-esque site running scoop software http://scoop.kuro5hin.org/ if kuro5hin doesn't jive with you

    2. Re:Modding of Articles by Anonymous Coward · · Score: 1, Insightful

      Oh dear, here I go OT again.

      Not a flame, but... while I like K5's article moderation system and /.'s comment moderation system, why doesn't any site seem to combine the two?

      k5 often has interesting articles but the comments are just pages full of trolls and flamebait, with the occasional interesting comment thrown in that I can't be arsed searching for in all the garbage.

      OTOH I can browse /. at 4 or 5 and get mostly interesting discussions and reasonably thoughtful commentry (depending on the article), but I have to wade through the duplicate articles, blatant product promotions and stuff like this that smells strongly of astroturf (hmm, does Astroturf smell of anything?)...

    3. Re:Modding of Articles by Emil+Brink · · Score: 1

      Um, scoop.k5.org seems to be solely about the development and use of Scoop itself... I would guess that makes its audience a bit smaller than that of Kuro5hin, so I don't quite understand the recommendation.

      --
      main(O){10<putchar(4^--O?77-(15&5128 >>4*O):10)&&main(2+O);}
    4. Re:Modding of Articles by Anonymous Coward · · Score: 0

      k5 often has interesting articles but the comments are just pages full of trolls and flamebait, with the occasional interesting comment thrown in that I can't be arsed searching for in all the garbage.

      OTOH I can browse /. at 4 or 5 and get mostly interesting discussions and reasonably thoughtful commentry (depending on the article), but I have to wade through the duplicate articles, blatant product promotions and stuff like this that smells strongly of astroturf (hmm, does Astroturf smell of anything?)...


      For me it's vice versa. :P

    5. Re:Modding of Articles by cehbab · · Score: 1

      It was an interesting update on the status of prevayler for me. I use it, and im happy with it. Sure, my apps that use it dont handle gigs of data, and never will, so prevayler is a niche for applications like mine. No database at all is required, just prevayler jar and some disk space to persist it for future use. If you dont want to read about this kind of technology, then please just skip articles your not interested in, I for one AM interested in the evolution of this technology, and id say there are a lot of others that would like to know about such things.

    6. Re:Modding of Articles by batkiwi · · Score: 1

      I meant to look for another site running the scoop software, and gave a link to the scoop software since the site also has links to other scoop-run sites, not to post/read the actual scoop site :)

  20. Why Java? by Fred+Nerk · · Score: 2, Insightful

    I'd be very interested in this, except for the single fact that's it's Java?

    I may be offending some people here, but I hate Java. After having worked with it for a couple of years I hate it even more.

    I've often had the need to store objects in other languages (Perl, PHP) and I'd have to say I've had a bit of difficulty mapping the data into an RDBMS, but not enough trouble to make me want to switch languages.

    Actually, I don't have a huge problem with the Java language itself, just that it has to run in a VM, it's slow, takes ages to compile, has crappy string handling (compared to Perl/PHP but better than C)..

    Yuck!

    --
    Anything is possible, except skiing through revolving doors.
    1. Re:Why Java? by frankmanowar · · Score: 1

      I agree. One of my favorite things about MySQL is that I can use as many languages as have a plugin for connecting to it and sending queries, and many of them also have lots of bundled modules, packages, pear and cpan, if you get my drift. Hell i could even use java if i was feeling especially masochistic... I haven't found anything on their site like an API or protocol for connecting, just Java. Blech.

      --

      "Other bands play, but Manowar KILLS"
    2. Re:Why Java? by Xeger · · Score: 2, Insightful

      Prevayler doesn't map data into an RDBMS. Prevayler removes the RDBMS entirely.

      In Prevayler, your "database" is represented natively as a collection of objects, which reference each other by holding pointers to each other, just like any other God-fearing object in core memory. It builds indices, also in memory, to support query operations on this big collection of objects. The whole shebang is periodically serialized to disk, to make it persistent between invocations of your application.

      So: Prevayler is natively an OODBMS, and not a tool to map between OO and relational databases. Any language that supports introspection can support prevalence, and hence Prevayler. Such languages include Perl, Python and C#.

      Even for languages that don't support introspection, you could still implement a prevalence system, but it would be rather awkward and not seamless. Your objects would all need to know how to serialize and deserialize themselves, and also provide indexing information about themselves...a clunky and unwiedly approach. Which is why you're unlikely to see Prevayler for C++ any time soon.

      I disagree with Prevayler's approach for more fundamental reasons, having to do with the fact that the whole database must always exist in memory. But I won't get into that here.

    3. Re:Why Java? by alext · · Score: 1

      Really?

      Have you found that all Oracle datatypes were supported in your Perl DB driver? They weren't when I last used it. And forget trying to catch deadlock or timeout exceptions consistently and concisely.

      In fact, the quality and completeness of common JDBC drivers is probably one of Java's biggest assets.

      Java generally runs pretty quickly these days - can you point to a benchmark we can try? The Jikes and Borland compilers are very quick - did you try either of those? And JDK 1.4 has full regexp functions, if that was what you were missing from Perl.

    4. Re:Why Java? by period3 · · Score: 1

      Try defining your database FIRST, then writing your application code.

      The database is the core of the application - define that, and THEN write your application. If you can't define your data, you can't define your application.

    5. Re:Why Java? by Anonymous Coward · · Score: 0

      And it will take you five times longer to write.
      Vroom Vroom SUV driver coming through!!! Weeee!!!!!

    6. Re:Why Java? by MSBob · · Score: 2

      How do you effectively query that thing? OO links are not efficient to follow unless you set up hashmaps all over the place which would make your object model absolutely horrible to maintain...

      --
      Your pizza just the way you ought to have it.
    7. Re:Why Java? by angel'o'sphere · · Score: 0

      Unfortunatly there is currently no mainstream language which has the technical possibilites Java has, to make a prevalyer lookalike.

      E.g.: PHP and Perl have no build in object serialization and deserialization.

      PHP and Perl have no build in thread synchronization on language level.

      Your comments:
      just that it has to run in a VM, it's slow, takes ages to compile, are all wrong. Java is as fast than c++, since years. PHP and PERL run in a VM as well. Java compiles far faster than C or C++ or PHP.
      Try compiling a 500.000LOC C++ project with GCC and then do the same with Java, on a java VM with the build in Java compiler ... using jikes would be cheating :-) but Jikes (for Java)is about 100 times faster than gcc for C++.
      The only thing which is true about your statement is string manipulation ...
      However, in that case your "appliaction" is likely not a multi player persistant online world, is it?
      Because that is the perfect case where you want to use a prevalent system ... distributed over as many servers as you need to scale ... and no RDBMS behind it.
      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    8. Re:Why Java? by Fred+Nerk · · Score: 2, Informative

      E.g.: PHP and Perl have no build in object
      serialization and deserialization.

      Perl:
      use Storable;
      my $string = freeze $bighash;
      my $anotherhash = thaw $string;

      PHP:
      $string = serialize($bighash);
      $anotherhash = unserialize($string);

      Both of these are built-in (or close to it).

      --
      Anything is possible, except skiing through revolving doors.
    9. Re:Why Java? by Fred+Nerk · · Score: 1

      Wonderful. I could quote college programming texts too if I wanted.

      Even if I believed that 100% of the time your short statement was correct, it has nothing to do with my comment.

      --
      Anything is possible, except skiing through revolving doors.
    10. Re:Why Java? by angel'o'sphere · · Score: 1

      Does that work on objects, or only on Strings?
      Thanx for teh enlightment anyway :-)
      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    11. Re:Why Java? by jafac · · Score: 1

      I disagree with Prevayler's approach to "replacing" RDBMS' for the simple fact that it fails the ACID test.

      --

      These are my friends, See how they glisten. See this one shine, how he smiles in the light.
    12. Re:Why Java? by entartete · · Score: 1

      python has pickle to do serializing also to round out the P's.

    13. Re:Why Java? by entartete · · Score: 1

      serialize in php works on objects (sessions will also handle serializing stuff for you too but you can use serialize to make your own persistant object stuff too)perl most likely does though i've never worked with objects in perl much at all so I can't say for certain.

    14. Re:Why Java? by Lu1g1 · · Score: 1

      If you have problems mapping objects from PHP (or Java) to SQL database, I suggest you to try DaoGen. You can find it here.

    15. Re:Why Java? by LizardKing · · Score: 1

      The poster you're denigrating was right, even if he looks like he's quoting from a textbook. If you can't write a simple frontend for your database using Java and JDBC, then it suggests either your database design is poor, or that you're an appalling programmer. I find Java, JDBC and a RDBMS to be a an excellent combination - far superior to embedded SQL with a lower level language. As for Perl and the DB modules, they're great for small or stopgap systems, but are disastrous for complex systems unless very strict coding standards and thorough peer review are employed[1]. Don't know how Python compares though ...

      Chris

      [1] one man's Perl code is another mans line noise

    16. Re:Why Java? by Fred+Nerk · · Score: 1

      "As for Perl and the DB modules, they're great for small or stopgap systems"

      That same argument again? It does matter what language you write in, you can still get appalling code if you don't know what you're doing.

      I am still yet to see a good reason why Perl cannot be _effectively_ used for anything other than a small/stopgap system.. Can you provide one?

      --
      Anything is possible, except skiing through revolving doors.
    17. Re:Why Java? by LizardKing · · Score: 2, Interesting

      That same argument again? It does matter what language you write in, you can still get appalling code if you don't know what you're doing.

      I am still yet to see a good reason why Perl cannot be _effectively_ used for anything other than a small/stopgap system.

      Perl encourages bad coding style in the same way that C++ does. Both languages have a number of idioms for coding the same thing, and that often leads to highly "personalised" code. I have seen too many projects where Perl was chosen as the implementation language, and then the whole thing became unmaintainable once the original coder(s) moved on. In fact I used to make a living from going into companies as a contractor and fixing such abortions. The fact that I was in such high demand suggests this is a common problem. Ultimately I got sick of doing it, as it's not a very satisfying job. I then expunged the word "Perl" from my CV.

      In contrast, Java enforces a more limited set of programming idioms. Some people rail against this, claiming (wrongly in my view) that the limited syntax and lack of things like a preprocessor make coding considerably harder. However I see far less spaghetti code written in Java than I ever saw Perl programmers produce. Ditto for C compared to C++.

      Perl may be a good choice as long as you can enforce good coding standards and peer review, but how many typical software houses do that? I've worked at a large number ranging from small to massive, and very few have either policy and even less actually enforce them.

      Now you're most likely going to come back with the tired "you're blaming bad programming practices on Perl". But the reality is most companies have bad programming practices, and Perl excacerbates them.

      Chris

      (Who once believed Perl was the panacea to everything, but nowadays isn't foolish enough to think that either it or Java is).

    18. Re:Why Java? by LizardKing · · Score: 2, Informative

      I thought I'd amuse myself by checking out your website, and came across this gem:

      Funny Code

      ... which starts off by cataloging some Perl atrocities. Then under the C/C++ section you write:

      haven't got any good examples of C/C++ funny code yet

      ... and you still felt the need to question my own dislike of Perl?

      Chris

    19. Re:Why Java? by joib · · Score: 1

      Here's a port of prevayler to python: PyPerSyst. The basic concept is rather simple, so I don't think it would be very hard to implement in language X, in case you're interrested.

    20. Re:Why Java? by Fred+Nerk · · Score: 1

      Excellent! A coherent argument :)

      Actually I quite agree, Perl does allow really bad code to be written, and makes it quite easy.

      I believe that this is a strength when you're dealing with small tools, and definately a hinderance when working with large projects.

      However, I don't see it as an argument why Perl can't / shouldn't be used for large projects. If, as you say, there are coding standards, peer review and some decent programmers working on it, then some wonderfully concise, efficient and maintainable code can come out of it.

      What I'm sick of, is people criticizing my use of Perl for various projects, with statements like "You should use a *standard* enterprise scalable development architecture such as J2EE, not Perl which is only good for prototyping".

      I realise it's not you, but I really do want to know why people say that.

      --
      Anything is possible, except skiing through revolving doors.
    21. Re:Why Java? by Fred+Nerk · · Score: 1

      Stabbed in the back by my own website..

      tsk tsk.

      That's an easy one to explain.. Where I work, the only C/C++/Java code I have access to is strictly confidential.

      --
      Anything is possible, except skiing through revolving doors.
    22. Re:Why Java? by Fred+Nerk · · Score: 1

      Oh.. and in one of the C source files I have access to, is a 74 line function to remove a trailing " ".

      You don't want to know what the rest of it is like.

      --
      Anything is possible, except skiing through revolving doors.
    23. Re:Why Java? by Anonymous Coward · · Score: 0

      Bahahahaha wahahahaah bahahaha! Funny, you're one of those DB Zealots. Nice. Well, how do you know what data you need if you haven't defined your PROCESSES? That's why, I would suggest changing your philosophy from Data-tier centric to Business Tier centric. Why? Because the business tier (in the 3 tier model) is adjacent to both the presentation tier and the data tier, hence it has the best perspective on the entire system architecture....starting at the presentation layer (which I will laugh has as hard at those people as I do at you) removes you 2 layers from the data tier. Same thing with the data tier to the presentation tier. In the business tier (where the processes are defined), you are adjacent to the two other tiers, and you can better design your applications.

      -Chris

  21. Untested, difficult to get this right, skimpy docs by Anonymous Coward · · Score: 0

    Judged by existing work in this area, OO-->RDBMS is a very difficult problem to get right.

    Solutions such as Castor and Hibernate have been used on something more than the sample databases that came with Access.

    Also, why even call attention to your WIKI when it has so little useful information? Objections to Prevalyer - it probably won't work for my complex data because there isn't an indication that it has been used on real world problems.

  22. Nothing Better To Do... by inertia187 · · Score: 3, Funny

    I'm just going to assume their site uses Prevayler to store the page counter and revision information at the bottom of the linked page. Here's what I saw (times are Pacific):

    [16:47] : This page has 10151 hits and 60 revisions
    [16:50] : This page has 10156 hits and 60 revisions
    [16:52]*: This page has 10170 hits and 60 revisions
    [16:53] : This page has 10194 hits and 60 revisions
    [16:54] : This page has 10220 hits and 60 revisions
    [16:55] : This page has 10261 hits and 60 revisions
    [16:56] : This page has 10311 hits and 60 revisions
    [16:57] : This page has 10353 hits and 60 revisions
    [16:58] : This page has 10413 hits and 60 revisions
    [16:59] : This page has 10454 hits and 60 revisions
    [17:00] : This page has 10503 hits and 60 revisions
    [17:01] : This page has 10539 hits and 60 revisions
    [17:02] : This page has 10578 hits and 60 revisions
    [17:03] : This page has 10623 hits and 60 revisions
    [17:04] : This page has 10666 hits and 60 revisions
    [17:05] : This page has 10713 hits and 60 revisions
    [17:06] : This page has 10748 hits and 60 revisions
    [17:07] : This page has 10792 hits and 60 revisions


    * - The Mysterious Future

    Oh well. It did seemed to peek around 16:58, but I guess Slashdot users really didn't click on that link all that much. Too bad, that would have been fun ad-hoc to test.

    --
    A programmer is a machine for converting coffee into code.
    1. Re:Nothing Better To Do... by pajama · · Score: 1

      DONT CLICK ON THE PREVLAYER LINK!

      Now is redirected to http://goatse.cx/

    2. Re:Nothing Better To Do... by pajama · · Score: 1

      Hummmmm Forget it. It works now.

      I swear it redirected me to goatse, really!

      Maybe it was a way to take revenge for the slashdotting... Maybe just randomical click throughs?

      Nevermind.

    3. Re:Nothing Better To Do... by Anonymous Coward · · Score: 0

      Or maybe you're smoking something.

  23. How innovative, a bunch of objects in RAM by Anonymous Coward · · Score: 0

    I don't see why there's excitement over a bunch of Objects in RAM that are checkpointed to disk every once in awhile.

  24. Another reason not to use it: by Anonymous Coward · · Score: 0

    Here's another quote:
    To avoid losing data, every night, or in any reasonable period, your system server saves a snapshot of all business objects to a file using plain object serialization.

    I'm sorry, but if you sync every night, you're not even close to ACID compliant. ACID implies that when I say "Commit", it's commited to persistent store in such a way as to survive most hardware crashes (maybe not the computer room catching on fire, but certainly a disk head crash). That's the D in ACID, Durability.

    I'm sorry, but you have yourself a nice little data access mechanism, not an ACID compliant database.

    Eric

    1. Re:Another reason not to use it: by isoga · · Score: 0

      RTW - You synch every so often, but write a log of acions to a backup server that you can replay if needed

  25. Serialize once a night? by autopr0n · · Score: 1, Insightful

    Geez, this just seems stupid. They want you to store all your data in RAM and save it to disk once a night via 'plain object serialization' If they really are using 'plain object serialization' in java then all data-access functions are going to lock, which means you won't be able to update anything during the serialization stage. And if you have a system crash, you lose all your data for the whole day.

    If they had any sense then they would have everything saved to disk (like a journaled file system) and the 'serialize once a day' thing wouldn't be an issue.

    And lets not forget the fact that object serialization is slow. I once tried to build a website using java collections and serialization, and it would take nearly half a second to save the whole sites data, with a 'database' of only a few thousand entries. I can't imagine long it would take to save the hundreds of megs of data autopr0n uses.

    Maybe they've solved some of these problems, but it still sounds stupid. There are "real" OODBMs that let you keep your data in an OO system and let you keep that data on a hard drive, like a sane person.

    --
    autopr0n is like, down and stuff.
    1. Re:Serialize once a night? by batkid · · Score: 3, Informative

      I'd say RTFA, but the article is just a very plain website with very little information. However, if you look into it, all the transactions are actually SAVED so you don't have to worry about losing data in the middle of the day (i.e. a journaled file system). The daily serialization is just a snapshot of the system so you don't have to start from the beginning every time you restore the system.

    2. Re:Serialize once a night? by MSBob · · Score: 1

      The snapshot is made on a backup server. RTFW (Read the F**endly Website).

      --
      Your pizza just the way you ought to have it.
    3. Re:Serialize once a night? by Elwood+P+Dowd · · Score: 4, Informative

      At all times, they serialize commands to log files. Those commands are sent to every machine in your cluster. (A clock tick is one of those commands.) When you backup at night, one of those machines serializes it's objects to disk, and racks up commands to complete. Once it's done serializing to disk, it runs through the commands and catches up.

      If all your servers go up in flames, you take your object serialization, and reload it. Then you run through the command logs, and you're right back where you were when the machines died. (Assuming you've got your command logs)

      So no, they don't have their heads up their asses in that respect.

      --

      There are no trails. There are no trees out here.
    4. Re:Serialize once a night? by angel'o'sphere · · Score: 2, Informative

      This post is not INSIGHTFULL this post is STUPID, the author did not read the web site of prevayler.

      e.g. he claimes:

      And if you have a system crash, you lose all your data for the whole day.


      Thats wrong. You lose nothing. Hint: before images(not really but similar). Hint: Command Pattern.

      ARG, need holy water, a design pattern, the pure EVIL of OO geeks .... yeah forget it ...

      angel'o'sphere
      P.S.
      I think if you needed half a second fore some few 1000 entries to serialize, yopu should have tried how long it takes with a million? One second more I guess. If not, consider using a BufferedWriter ...

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    5. Re:Serialize once a night? by MikeBabcock · · Score: 1
      You can always work with the opposite assumptions; everything is a disk file and its up to the OS to do the caching for you.

      In either case, you're throwing out intelligence; with an RDBMS you've got the possibility of making intelligent decisions about what gets cached in memory and what doesn't. You get to decide what needs indexing, and what doesn't. You get to make real decisions about your data storage.

      Psst, and SQL/OO programming isn't that hard with high-level languages ... and no, I'm not using Pickle ;-)

      class Customer:
      def _sql_load(self, custid):
      row = self.dbconn.do("select ... from Customers LEFT JOIN ... WHERE CustID = %d" % custid)
      self._fname = row["fname"]
      self._lname = row["lname"]
      self._title = row["title"]

      ... and so on, and so forth. Its not that hard to serialize *just* your data and create new objects based on it. If you want lots of fun in Python, build yourself a meta class that builds classes from your database data.

      --
      - Michael T. Babcock (Yes, I blog)
    6. Re:Serialize once a night? by angel'o'sphere · · Score: 1

      Thats easy and boring and ends with: I have my objects in an RDBMS ...
      So I prefere trying to make myself a meta class ... if that indeed is possible in Python, wich organizes transactions and rollbacks and serialization in a python prevalent system.
      But ... I dont know if python supports "synchronize" or something similar like java does. I asume it does or the Zope guys had a hard day.

      The only advantage using an RDBMS has is being able to access the same RDBMS from python and Java and C .... if you dont need that and if you have enough RAM, a prevalent system is easyer.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    7. Re:Serialize once a night? by Anonymous Coward · · Score: 0

      You really seem to be taking all this rather personally, angel. Chill out.

    8. Re:Serialize once a night? by angel'o'sphere · · Score: 1

      Yes,

      I take it personal. 50% of the insightfull modded posters have no clue, and the moderator even less. And: 5 from my posts got modded down ... one even "flaimbait", how silly.

      I can not understand why the people on /. need to bash something wich is new instantly .... just because it dos not fit into their picture of the world.

      The idea of "prevalent systems" is old, a lot of our day systems in use ARE prevalent system. E.G. most of the embedded systems in your car ...

      What really pisses me, that I corrected some of the worst posts here(some rated insightfull ... tzzz) , by cut/copying some citates and commenting them, and I get TROLL and FLAIMBATE ratings where the original commenter not even was able to read the web site of prevailer correctly ... the term ASSHOLE, which appears in my post is a citate of the guy I comment. He called the pevayler guys: assholes. For that he gets an interesting or insightfull ... how silly.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  26. Please, enough of the hyperbole bullshit by tstoneman · · Score: 4, Insightful

    Please don't go around saying, "Could this be the end of RDBMSes?" That is just a crock of shit, and it really bugs the hell out of me. How stupid do you think we are to have a tagline like that?

    Please watch "Bowling for Columbine" and it says that this type of exaggeration by the media, and most notably US media, is driving the Americans crazy paranoid with fear. It seems like the editors have fallen for the same thing, and it should stop now!

    Let's have a modicum of dignity and avoid all the hyperbole, please. We are all somewhat tech-savvy, please treat us with the respect that we deserve!

    I'm sure the technology is good, but for crying out loud, mainframes are still around 40 years later. RDBMSes are going nowhere for the next 20+years until true AI comes around.

    1. Re:Please, enough of the hyperbole bullshit by scubabear · · Score: 4, Insightful

      Actually, the technology isn't even that good. What you have is a bunch of objects in memory, the ability to rollback "transactions", and in-memory changes are checkpointed to disk every once in awhile. This has "amateur" written all over it.

    2. Re:Please, enough of the hyperbole bullshit by dAzED1 · · Score: 0, Troll
      US media?

      Slashdot is a canadian thing, dude...don't blame their crap on us ;)

    3. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 2, Informative

      I agree that this was a pretty shameless "story", but your comparison to "Bowling For Columbine" is somewhat ironic, since Michael Moore is at least as manipulative as the mass media he decries.

      Here is a list of gross inaccuracies in Bowling For Columbine

    4. Re:Please, enough of the hyperbole bullshit by TheSunborn · · Score: 2, Interesting

      Can they rollback? Their documentation is poor(Or I could just not find it) but based on the description i found on the site, they said that rollback was not posible.

    5. Re:Please, enough of the hyperbole bullshit by TummyX · · Score: 2, Insightful


      Please watch "Bowling for Columbine" and it says that this type of exaggeration by the media, and most notably US media, is driving the Americans crazy paranoid with fear.


      LOL. Don't you see any irony in that (psst fear mongering) statement at all?

    6. Re:Please, enough of the hyperbole bullshit by angel'o'sphere · · Score: 0, Troll


      And if you have a system crash, you lose all your data for the whole day.

      Well, then kindly explain, how you would have done it and how a modern RDBMS does it.

      I think the way you would have done it would fail under real work conditions and a modern RDBMS works exactly as a prevayler system works, except that the programmer of the system has FAR MORE controll about what is going on ... and does not support SQL, of course.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    7. Re:Please, enough of the hyperbole bullshit by molarmass192 · · Score: 5, Insightful

      There's no rollback because there's no concept of a transaction and they even go so far as to try to justify not having transactions. What if a transaction depends on 3 objects getting serialized or none at all, guess you're out of luck. Label this project for what it is, a small non-transactional in-memory db like hsqldb but with less features. The very premise that this could replace a relational database is just a cheap laugh for anybody who has worked with or programmed for an enterprise class database.

      --

      Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
    8. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      Why did you get modded to troll? Is it a secret that /. is Canadian? Or were they bought out by an Iranian sheih (sp?)?

    9. Re:Please, enough of the hyperbole bullshit by scubabear · · Score: 2, Insightful

      You're right, you can't rollback - it took me awhile puttering about to find it on that damnable wiki. After reading in depth, it would appear that they don't support transactions at _all_.

    10. Re:Please, enough of the hyperbole bullshit by Delirium+Tremens · · Score: 3, Informative

      Please do not compare this to hsqldb. The hsqldb project at least offers some drivers for remote connections to the persistent store.

    11. Re:Please, enough of the hyperbole bullshit by TheSunborn · · Score: 1

      I begin to understand how they get to be much faster then MySQL and Oracel :-}

    12. Re:Please, enough of the hyperbole bullshit by jafac · · Score: 1

      Could this be the end of advertisements disguised as press releases disguised as informative articles?

      --

      These are my friends, See how they glisten. See this one shine, how he smiles in the light.
    13. Re:Please, enough of the hyperbole bullshit by angel'o'sphere · · Score: 1

      oops, was reffering to this line: This has "amateur" written all over it..
      And I wanted to say:
      Well, then kindly explain, how you would have done it and how a modern RDBMS does it.

      I think the way you would have done it would fail under real work conditions and a modern RDBMS works exactly as a prevayler system works, except that the programmer of the system has FAR MORE controll about what is going on ... and does not support SQL, of course.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    14. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      no idea. lol. My guess would be that a canadian took offense...lol

    15. Re:Please, enough of the hyperbole bullshit by leecho · · Score: 1

      Hey, you *can* rollback. Get the new version and read the docs/code. It's one of the new features in 2.x.

    16. Re:Please, enough of the hyperbole bullshit by AntiOrganic · · Score: 0, Flamebait

      Especially considering how Michael Moore is one of the most sensationalistic "filmmakers" ever. This is, of course, when he's not flat-out trying to deceive his audience to further his agendas.

      This isn't to say that he's wrong, but his attitude is a discredit to his message.

    17. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      Indeed, you have "FAR MORE control" so that you can re-implement the functionality of the relational model by hand, minus transactions.

    18. Re:Please, enough of the hyperbole bullshit by Jerry · · Score: 0
      What if a transaction depends on 3 objects getting serialized or none at all, guess you're out of luck.


      It seems that you are not alone in your failure to read the information on the website, or read it more carefully.
      See: http://www.prevayler.org/wiki.jsp?topic=RollbackIs Needless


      "Rollback is not a feature. It is a workaround for limitations in database technology.

      Prevayler provides all ACID transaction properties without using rollback logic. Since traditional databases, on the other hand, have to use rollback logic to implement ACID properties anyway, they also offer you rollback to use if you want.

      People use rollback to undo the operations that they have speculatively applied to the database until one of the following happens:

      The user (or the master in a distributed transaction cenario) decides to give up.

      They realize the transaction would produce an inconsistent state.

      The reason why operations have to be speculatively applied is that transactions take time to execute in traditional databases. The database cannot simply wait until commit to start applying the operations.

      With prevalence you no longer need rollback. Instantaneous Transactions simply eliminate the need to speculatively apply operations to the system before the user (or the master) commits.

      To deal with the committing of inconsistent transactions, you just have to determine wether the transaction is inconsistent BEFORE starting to apply it. Every operation that could possibly fail must have explicitly verifiable pre-conditions (good practice anyway).

      Some people suggested every business object could provide an undo operation for every operation. Having to implement undo methods for every change (and propagating those undo methods through the business object trees) is impractical for the amount of work and is extremely error-prone, though.

      Object-oriented databases try to make everything "transparently" undoable. Changes are made to clones of the real business objects; on commit the changes are synched and the clones discarded. This is pretty complex to implement if you want it to be minimally invasive, however, and extremely slow because every single variable access (including reads) requires indirection.

      That is why Prevayler is so much faster and simpler than OO databases even. "

      --

      Running with Linux for over 20 years!

    19. Re:Please, enough of the hyperbole bullshit by GISGEOLOGYGEEK · · Score: 1

      Your response link is BS, fabricated by someone who doesnt like the truth exposed. Yes yes, bowling for columbine is very biased and manipulative, but is a lot more truth in it than any gun loving bastard would admit to.

      Here is a list of the submarine launched nuclear ballistic missiles MADE BY LOCKHEED-MARTIN

      KABOOOM

      Gee I thought they only made rockets to launch satellites!

      Well now since thats the first big chapter of that page debunked as false, There's no point trusting any of the rest of it. The author was merely using the same tactics he accuses Moore of using.

      --
      George Bush + Linux = "I will not let information get in the way of the fight against Windows"
    20. Re:Please, enough of the hyperbole bullshit by jvagner · · Score: 1

      I'm pretty sure most people didn't understand the movie. Anything he did was predicated upon the shooting death statistics that started the movie. We have 10K+ deaths a year, most countries have, at most, hundreds. Everything he did afterwards, in the movie, is gravy.

    21. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0
      You're right, there's no need for a rollback, but you could at least try the rollback in 2.0 alpha before judging it.

      Cheers

    22. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 1, Informative

      These guys need to read the LRVM paper - a poor attempt by the OS community: PDF (by Satya and Co. at CMU). Of course, as a database researcher I don't think much of Prevlayer .. mainly because the database community went through this in 1990. Great paper to read is Carey and Dewitt's Of Objects and Databases: A decade of turmoil - it won the "Test of Time" award in VLDB 1996.

    23. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      Yes, but the plant near Columbine does not produce these rockets. And Moore tied the Columbine shooting to the nearby WMD production. That manipulative POS lied.

    24. Re:Please, enough of the hyperbole bullshit by eyeye · · Score: 1

      Its a cheap trick to get our attention I suppose. If this wasn't a geek site it would probably have said "hot chicks in here!" ;-)

      --
      Bush and Blair ate my sig!
    25. Re:Please, enough of the hyperbole bullshit by GISGEOLOGYGEEK · · Score: 1

      no, that kind of tie is a supposition, not something you can prove as fact or fiction so you can't say its a lie. How can you be sure that people werent 'a little off' just from knowing many of their neighbours worked for the company that profits from the chance of destroying all life on earth?

      for example, we all know smoking causes cancer, but you can not say absolutely that a specific case of cancer was definately caused by the person being a smoker. There is an obvious tie, but no way you can prove it in any specific case.

      On a similar topic, how to you feel about your president crawling back to the UN begging for assistance now that the US can't handle the mess he caused in Iraq? After demanding that the UN stay out of it, to either jump in and fight or get out of the way, stating that the UN is irrelevant, suddenly now he's running back crying that the US can't actually handle it after all.

      what a typical american way to do things. destabilize a messed up country where the people already don't like you, never find the evidence of WMD's that were supposedly an imminent threat to the US - the entire reason for the war (of course the reasons changed later when the WMD's werent found) ... but now when the responsibility of cleaning up the mess is getting heavy, try to drop it back on the UN.

      I have no doubt the US will give up and pull out of Iraq far too soon, leaving it in ruins with no real government system .. as a breeding ground for terrorists way worse than anything hussein had and everyone of them begging for a chance to die by taking innocent lives with them... somewhere in the distance a clueless aging Dubya in his rocker asking what it was we ever did to deserve it.

      with rolemodels like Dubya its a wonder you don't have way more psycho mass killings.

      --
      George Bush + Linux = "I will not let information get in the way of the fight against Windows"
    26. Re:Please, enough of the hyperbole bullshit by ed1park · · Score: 1

      I'm annoyed by how this gets modded as insightful when it seems that most of the people posting quickly attack the technology without trying to understand how Prevayler achieves ACID compliance.

      It may not replace most databases today, but don't be so shortsighted. Your dismissive remarks sound like early comments on Linux. The hardware landscape will be quite different with the advent of ubiquitous 64bit+ systems in the years to come.

      Anyway, here's a link that sheds some light on transactions.

      http://www.prevayler.org/wiki.jsp?topic=Rollback Is Needless

      --------------------
      I'm still trying to wrap my head around object prevalence, but it seems to me that it's the previous comment's assumptions that are invalid. In an RDBMS each select, insert, update, etc. is a single atomic command, thus you need to use explicit transactions to group several operations in an atomic way. And in a prevalent system (to quote Klaus), "Only one command is executed on a prevalent system at a time." What I'm thinking (someone correct me if I'm wrong) is that executing a (synchronized) command in a prevalent system might be a call to a single method which contains all needed business logic and does (or doesn't do, or undoes, or...) data modifications as appropriate.

      Unless you're talking about using transactions with ad-hoc queries, in which case it's more an issue of how to handle ad-hoc queries (discussed elsewhere) than how to handle transactions.

      - Joel Fouse

      So if I understand this correctly, every single ACID transaction that a particular system requires gets implemented as one of these Prevayler command objects, and these objects are globally synchronised (ie. only one of them can execute at once). This would enforce globally serialised access to your "data model", and hence eliminate a lot of the concurrency related problems that traditional RDBMS transactions attempt to solve. In a traditional database, global serialisation would guarantee truly abysmal performance, but I'm guessing that because everything happens in memory, this isn't an issue with Prevayler?

      If I've got it right, that makes a fair bit of sense actually... ...although I must admit that I'm not particularly satisfied with the answers that have been given for some of the issues that others have raised. In particular:

      1. 2PC (in the case where your transactional boundary encompasses more than just your PrevLayer? "data model")

      2. rollback support (to avoid having to manually guarantee ALL preconditions BEFORE modifying any of the "data model" objects)

      etc.

      -- Peter Monks

      You are right regarding the speed of globally synchronized transactions in RAM (Instantaneous Transactions) and the fact that this eliminates concurrency problems among them. Before they are executed serially, mind you, they are written to disk in parallel. Prevayler 1.03 does that, although that was not yet migrated to the 2.0 architecture.

      As for 2PC see Two Phase Commit Is Unnecessary.

      As for not being able to guarantee all preconditions for your transactions, please keep a secret: thanks to coding by Jon Tirsen, Prevayler 2.0 will actually only execute transactions which are guaranteed not to throw Runtime Exceptions! If a transaction would throw a Runtime Exception, Prevayler just does not execute it on your system. "How on earth does Prevayler know wether a particular transaction would throw a Runtime Exception?" Download the 2.0 code from CVS and try it out. It is pretty cool to see that working and, as most of Prevayler, is based on an anticlimactically simple idea brought up by several people on the Prevayler Team.

      --Klaus Wuestefeld

    27. Re:Please, enough of the hyperbole bullshit by sdcharle · · Score: 1

      I know I bought a better lock for my door and loaded up the shotgun at the prospect of the anarchy an RDBMS-less world would bring...thanks for putting things back in perspective for us all. Now I'm off to buy a new pair of pants. Damn you slashdot and your scare tactics!

    28. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      Yea, it's pretty obvious that tstoneman recently watched Bowling For Columbine, thought it was insightful, and is now applying the ideas presented in it willy-nilly. I don't think Michael Moore would consider announcing a potential improvement in DB technology an example of the media promoting fear. He/she gets an "A" for effort, though.

    29. Re:Please, enough of the hyperbole bullshit by Anonymous Coward · · Score: 0

      no, that kind of tie is a supposition, not something you can prove as fact or fiction so you can't say its a lie.

      Michael Moore implied that the Lockheed facility produced weapons, when in fact it did not. His supposition was about the kids' thoughts, not about what the facility produced. He was intentionally misleading the viewer in order to propose his supposition and make it sound more reasonable. That _is_ something that one can say is a lie.

      How can you be sure that people werent 'a little off' just from knowing many of their neighbours worked for the company that profits from the chance of destroying all life on earth?

      The LM representative handled that comment fairly well. No sane person would make a connection between school shootings and missile production.

    30. Re:Please, enough of the hyperbole bullshit by GISGEOLOGYGEEK · · Score: 1

      look at the poor 'anonymous coward' hiding behind his country's weapons of mass destruction!

      face it, the truth hurts and you are in denial.

      --
      George Bush + Linux = "I will not let information get in the way of the fight against Windows"
  27. From the faq by FreeLinux · · Score: 4, Interesting

    Although MySQL is about 2.8 times faster for transaction processing, Prevayler retrieves 100 objects among one million 3251 TIMES FASTER than MySQL via JDBC, even when MySQL has all data cached in RAM!

    Now many different people will interpret this statement differently. But, my interpretation is that under very specific circumstances it is 3000 times faster than MySQL. However, for transaction processing, which is the primary and most common role of a RDBMS, MySQL is 2.8 times faster than Prevayler.

    Bottom line... For normal circumstances, MySQL is faster and many commercial SQL database servers are faster still.

    1. Re:From the faq by j3110 · · Score: 4, Interesting

      I guess in your development model you write more than you read?

      I bet you even are going to say that you use more transactions than you query.

      Finding/Reading/Loading data is always going to be the key to the best performance. Transactions are second to that. 3000X faster at reading affords it a lot of breathing space when it comes to transactions because everyone visiting slashdot is reading, but only a few post. This is the real world model.

      I'm skeptical when it comes to easily retrieving and indexing data for reporting. You need to be able to query aggregate (yes, this is easy enough to code) but you need to join related objects. Do I have to do my own query planning/joining? What's the transaction API like? Do I lock objects then update them? What about deadlock? (Easy enough to avoid by anyone smart enough to know any of the algorithms like having to sort the order in which you lock resources, but still a hassle.) So many questions!

      --
      Karma Clown
    2. Re:From the faq by Anonymous Coward · · Score: 0
      You're right on the mark with your questions as I've seen answers to them. Takes a while digging around in that lousy wiki though, and I didn't save links. There is another link I found that has some answers.

      One thing I remember reading is that you can use anything you like to query your objects, as long as it understands objects efficiently. One answer is to use Java, or if you like you can use XPath or XQuery as suggested here.

      Cheers

    3. Re:From the faq by arivanov · · Score: 1

      Can you cut the crap? Prevayler is faster when it can fit the object store in memory and it tries to fit the entire object store in memory which is not the answer to 90%+ of real world tasks.

      It is OK for dealing with configuration data. It is OK for dealing with ephemeral data that shall be discarded after processing. It has no place whatsoever if you have to store data long term and the size of data will exceed the size of RAM on the machine.

      Try prevailer once the machine has burried its head into swap and talk bulshit again.

      --
      Baker's Law: Misery no longer loves company. Nowadays it insists on it
      http://www.sigsegv.cx/
    4. Re:From the faq by Anonymous Coward · · Score: 0
      Don't be afraid. Try it, and make it break. Then come back here and tell us. Or, make it work and tell us. You don't have to use the Java version, if you don't like Java. There appears to be other versions for Ruby and Python. There may be more.

      By the way, it also appears to be less than 1000 lines of code (at least for version 1), so it shouldn't be too tedious to port it to whatever language you prefer that supports features like serialization and reflection.

    5. Re:From the faq by julesh · · Score: 2, Interesting

      What's the transaction API like? Do I lock objects then update them? What about deadlock? (Easy enough to avoid by anyone smart enough to know any of the algorithms like having to sort the order in which you lock resources, but still a hassle.)

      Its pretty simple. You create command objects to represent each kind of transaction you can perform. They all implement a fairly simple interface. You present them to the persistence layer, which executes them 1 at a time. No locking is necessary. No deadlocks are possible.

      In fact, its so simple I see no need to use their code to do it. In fact, in one of my applications I have recently used the same model with my own implementation. I used my own implementation because I didn't want to use Java's serialization API (I find using a self implemented system that doesn't rely on reflection is generally much faster).

    6. Re:From the faq by Glock27 · · Score: 1
      It has no place whatsoever if you have to store data long term and the size of data will exceed the size of RAM on the machine.

      One acronym: VM (memory not machine).

      I'm actually rather curious how this would perform vs. a traditional DBMS, simply using the page file to replace all the traditional filehandling a DBMS does. You could of course specify a 100 GB page file for your 16 GB RAM Opteron box (presumably with a 64-bit IBM Java VM). A 116 GB database is not inconsiderable.

      What you are missing is that Prevalayer is very desirable in it's simplicity and low software development overhead. That same simplicity also gives it speed and inherent ACID properties.

      You are also being very shortsighted in another regard. It wouldn't take too much to park a layer on top of Prevalayer (no, not called Prevalayerlayer) that would distribute objects across a farm of Prevalayer boxes (high-reliability boxes with ECC, redundant power supplies, and so on)...then you have a very fast, large, scalable database.

      With sane, reliable software (like Java) such things are easier. I find Prevalayer to be very interesting. :-)

      --
      Galileo: "The Earth revolves around the Sun!"
      Score: -1 100% Flamebait
    7. Re:From the faq by William+Tanksley · · Score: 1

      Prevayler is faster when it can fit the object store in memory

      The benchmark claimed to be against MySQL with all its data in memory. That's a fair race.

      and it tries to fit the entire object store in memory which is not the answer to 90%+ of real world tasks.

      That statistic was made up from thin air and is _utterly_ false. Most tasks don't require very much data online, and I can't even imagine why you'd claim that they do. For those that do require large volumes of data, keeping it all in RAM is actually possible for a large subset. In fact, for the very largest tasks (petabyte systems), all the hard drives are directly facing equal amounts of memory -- booting the system consists of copying all the hard drives into their memory mirrors.

      There is a "midrange" (well, it's high-end, but compared to petabyte systems it looks like a midrange :-) where buying and addressing enough RAM is prohibitive, but hard drives are manageable. In those cases, and in those cases alone, your argument holds.

      There are, of course, other reasons to prefer a relational database manager over an object prevalent solution. Many of them, such as "my customers need truly ad-hoc queries, and they know SQL," are powerful and apply to many people. But your argument applies to only a few.

      -Billy

    8. Re:From the faq by William+Tanksley · · Score: 2, Informative

      One acronym: VM (memory not machine).

      I'm pro-OP, like you, but I have to point out that this isn't a good stance. Virtual memory doesn't help object prevalence; memory pagers aren't smart enough to handle the demands, and your OP system will fall behind a proper RDBMS.

      Now, an OP system doesn't have to keep all its objects in its working set (i.e. in memory) at all times; intelligent design of this will result in the ability to use OP with a much larger problem than you have memory for, without a significant speed loss. But don't expect to be faster than a quick'n'dirty pseudo-RDMBS anymore.

      A farm of prevlayer boxes is precisely one of the applications that 2.0 is intended for.

      -Billy

  28. whoah by Anonymous Coward · · Score: 0

    I got all excited until i found out it was for Java only.

    1. Re:whoah by Anonymous Coward · · Score: 0

      You mean sexually excited?

    2. Re:whoah by Anonymous Coward · · Score: 0

      yeah... even as i type this, the warm sensation in my trousers is giving away to cold loneliness once again.

    3. Re:whoah by Anonymous Coward · · Score: 0

      Well you know what those Prevaylance Java programmers say...
      "The angle of my dangle is inversely proportional to the heat of my meat".

  29. Speed, ACID and harddrive by vlad_petric · · Score: 3, Insightful
    The durability constraint of ACID implies that each transaction will be written to hdd when before the commit returns. This is why I don't buy the 3000x faster claim - you can certainly make everything go fast, but you'll still need 1 hdd access per transaction (granted, a db could try to coallesce 2 commits into one write, but that still won't fix much; furthermore, the DBs that I know of simply don't do it).

    If they just benchmarked reads ... then the results don't tell much.

    --

    The Raven

    1. Re:Speed, ACID and harddrive by Anonymous Coward · · Score: 0

      there is a big difference between writing log files (sequential appends) and updates to a random access block-natured file, and updating correspting indexes.

      PERVayler dismisses rollbacks, indexes and load times as "not our responsibliity". It's not ACID compliant, period. If you bounce your server, the load times are very expensive, and since indexing is the responsibility of your application, you get to handle that all by yourself.

      So, yes I can see how sequential appends are 3000 times faster, because that's the ONLY THING they are doing. No transactions/ACID. No index updates. Nothing. Nada. Zero.

      PERValence is NOTHING MORE than a memory queue with disk logging. Whupedee doo.

    2. Re:Speed, ACID and harddrive by angel'o'sphere · · Score: 0


      The durability constraint of ACID implies that each transaction will be written to hdd when before the commit returns. This is why I don't buy the 3000x faster claim - you can certainly make everything go fast, but you'll still need 1 hdd access per transaction (granted, a db could try to coallesce 2 commits into one write, but that still won't fix much; furthermore, the DBs that I know of simply don't do it).


      And what about read access?

      For write acces one has to understand how a RDBMS accesses a disk. At first keys and data are organized in trees, B-Trees or B*-Trees, or what ever. The data itself is organized in records. Records are collected in pages. Pages are oneor several disk blocks.

      For a write acces on a RDBMS, you need:
      a) insert the new data into the tree(with searching for the correct place if needed, that allready my include disk access)
      b) creating a record and inserting the record into the list of records ... depending on indices and clustering at a certain position, that might include allready disk access as that position might be inside of a block not which is not in memory
      c) writing out to disk: (1) the data, (2) the tree, (3) cluster information (4) index information, if necessary.

      With a prevalant system, you open a file, write the "change comamnd" into that file, and if it succedes, you execute the change command in the context of the prevalent system.

      Thats one write. And that write is similar to: "change attribute income of employee vlad to old income plus Euro 1000".
      Of course that is not a string but a serialized Java object which can only do 2 things: find "vlad" in the "list" of employees and call a method for his new sallary.

      As 90 percent of your application is likely READ access and as you as appliaction writer know your read access patterns perfectly, its no problem to use the correct data structures for every situation, hashmaps, treesets etc.

      BTW: I'm working with that prevayler since nearly 2 years .... and if it would not exist I had written my own.

      All my Java projects use prevayler .... its so simple and intuitive to set it up and write your first app ... RDBMSs are for my private work completely obsolet.

      As I do either "real programming" in Java and scripting in bean shell http://beanshell.org, serialized java objects ... living java objects in JVMs, RMI is all I need.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    3. Re:Speed, ACID and harddrive by rtaylor · · Score: 1

      granted, a db could try to coallesce 2 commits into one write, but that still won't fix much; furthermore, the DBs that I know of simply don't do

      PostgreSQL does. Due to WAL, an fsync on a block may commit more than one transaction to disk at the same time. Of course, the second transaction STILL issues an fsync request but the kernel treats it as a NOOP.

      That said, it doesn't seem to make a noticeable difference in speed -- but a few megs in battery backed write cache sure does ;)

      --
      Rod Taylor
    4. Re:Speed, ACID and harddrive by William+Tanksley · · Score: 1

      The 3000x benchmark only covered reads (although it was versus in-memory databases). That's still a useful benchmark; it's just not correct to quote it without its context.

      The more general benchmarks show a much smaller advantage, of course. But it's still impressive and useful, within its domain -- and since it requires MUCH less code, its domain can extend to include things that we'd never use a RDBMS for.

      Oh, and prevlayer does provide durability -- each command is journalled before the command executes.

      -Billy

  30. I'm ACID compliant.... by Anonymous Coward · · Score: 0

    ...if I have the next day off. Might even be faster than MySQL to boot.

  31. compare to berkeley DB (sleepycat) by Anonymous Coward · · Score: 0

    How does this compare to the established
    leader in embedded DB ????

  32. Apple WebObjects by KyleW · · Score: 0

    Apple WebObjects solves the supposed complicated OO to RDBMS problem quite eligantely. I've actually used it for a huge project and it worked quite well.

    --
    1st known failed CIA coup in South America : http://www.chavezthefilm.com/index_ex.htm
  33. You hate it because you're stupid by Anonymous Coward · · Score: 0

    or you configured it wrong

    or you were using Microsoft J++ 95 Alpha

    or you had a bad IDE

    or you're a bad coder

    or you're stupid.

    Or so the Trolldots will tell you.

    Oh wait -- you're stupid by default, and you can pick another reason at random.

    Flame completed.

  34. Zope by SlightOverdose · · Score: 4, Informative

    This sounds a lot like the Zope ZODB. For those who are still stuck in the stone age, Zope is a python based application server that essentially uses object serialisation to store its data.

    Imagine if every page in your website was an object- with methods, properties, Access Control, etc. You have different classes for different types of documents, and each document internally knows how to render itself. The ZODB is essentially one big persistant object orientated namespace- You dont have to parse your data into SQL and back again, it's always just there, elimenating a huge amount of work (and bugs!). Having worked with it for a year, I can certainly testify that it is leaps and bounds over relational databases for most things.

    1. Re:Zope by period3 · · Score: 1

      What about ad-hoc queries? Data integrity? Portability?

      (I haven't used Zope)

    2. Re:Zope by Evan · · Score: 3, Informative

      Like the ZODB, except that the ZODB has pluggable storage backends, so that your objects can live in a FileStorage, DirectoryStorage, OracleStorage, etc. Except that ZODB has true transactions, with rollback and two-stage commit (allowing transactions to span other systems, such as an RDBMS). Oh, and except that the ZODB doesn't force all of your objects to live in memory at once; you set the cache size and it dynamically loads and unloads objects as necessary. Oh yeah, it also has ZEO for client-server access to object databases, so that you can spread your object processing across more than one computer. Did I forget anything? Sorry, the overdone Prevayler hype got to me :-)

      By the way, ZODB is completely independent of Zope, although Zope relies on ZODB.

    3. Re:Zope by SlightOverdose · · Score: 2, Informative

      The first thing you need to remember about the Zodb is that it's NOT a synonym for a relational database. You can use it to store the same kind of data, but you have to approach the problem from a completely different point of view.

      At first people try and grasp how they would simulate tables, SQL queryies, etc. The answer is, you don't. If I want to store a large amount of records, I create a python dictionary (Think Java Hashtable, only better). I've written a 'product' called Shelf, which provides some simple APIs to do this. I can put dictionarys within dictionaries within dictionarys ad infinum, as well as lists, tuples, string, ints, whatever.

      The 'query' language in this case, would be Python itself. Using list comprehension, I can search a dictionary of several hundred thousand records in a few hundred milliseconds.

      i.e. return [(person['username'],person['password']) for person in staff if person.department in ['Marketing','Legal']]

      Seems complex, but once you get the hang of it its more powerfull than SQL. (I can also write a normal python script to parse the data if need be).

      Python supports several ways of allowing runtime parsing of code (ad-hoc querys, in this case).

      When you modify data in zope, it records all transactions. If something fails, it rolls back the whole operation. You can also manually roll back any operation at a later date if you want. It also doesn't store the entire database in memory- it only loads whatever you access, and caches it for a period of time. This can all be tuned.

      Zope supports spanning the ZODB over multiple servers. I've heard (although I'm still trying to confirm) of a Zope database containing over 300 gigabytes of information with no problems. I'll try and find a url.

      The Zodb can only be accessed by zope, but all the code to do so is in a seperate module which can easily be imported into a standalone python session. On several occasions I've manually accessed the data using a python shell. You can also access the Zodb via FTP and WebDAV.

      You can print a dictionary out as a string, save to a file, etc, and import into another python program at a later date using str() and eval(). This is trivial. Porting to other languages would require a little parsing, but is not out of the realms of possibility.

    4. Re:Zope by MattRog · · Score: 1

      But you haven't mentioned anything about integrity, which is quite possibly the most important job a DBMS has: ensuring the data is correct.

      Also, of course, how would you perform a JOIN (e.g. relate two lists)?

      --

      Thanks,
      --
      Matt
    5. Re:Zope by SlightOverdose · · Score: 1

      I did mention data integrity. the Zodb records all transactions, and rolls back to a known good state if something goes wrong. I presume this is what you were referring to. As for the Join- This would depend on the circumstances. You could just make a call to a seperate dictionary/list to get the data using a field from one db as the key. Dictionarys do not equate directly to Relational Databases, so not everything has a direct analogy. The Zodb is not a direct replacement for a Sequal database, however it can be used in most simple circumstances. I certainly wouldnt recommend storing 300 million accounting transactions in it.

    6. Re:Zope by MattRog · · Score: 1

      Integrity generally means a whole lot of things - mostly 'logical' (think referential, domains, etc.) and 'physical' (ACID transactions, writing to disk, etc.).

      You, perhaps inadvertently, mentioned the biggest advantage to the relational DBMS - declarative constraints/queries/etc. It's better (simpler, faster, less error prone) to be able to write declarative statements (e.g. 'Get me X') than procedural ('Here's how to get X') to do anything with data management.

      --

      Thanks,
      --
      Matt
    7. Re:Zope by SlightOverdose · · Score: 1

      Indeed. Object Databases will never replace Relational databases for that very reason (At least not in the forseeable future).

      In the end, it comes down to the right tool for the right job. I can do things with Python Dictionarys that would be an absolute nightmare in J2EE + SQL, but I certainly couldn't maintain 30 tables of data with relationships and constraints and hope to have anything near an O(log n) search time..

      I'm not suggesting people drop Mysql and start throwing all their data into the ZOBD- that would be a very stupid thing to do. what I AM suggesting is that people get out of the mindset of throwing everything into a database. In many projects, the database layer is the single most common point of failure- it's all too easy to make an error parsing data. An object persistance layer is quite often a better choice for many projects.

    8. Re:Zope by axxackall · · Score: 1
      What is referential integrity in RDBMS? It's a hidden "BEFORE" trigger checking the constraint that the refered obejct does exist. Same thing about explicit logical constraints.

      In ZODB you store you Python objects, which are instances of Python classes, which can have pre-coded constraint-triggers as well.

      So, ZODB does support "logical" integrity. Without it Zope would not be capable to bring a real content management in a such consistent way. I worked with several other content-management implementations and whenever it's build without acarying about logical integgrity - the content becomes a mess in no time after such management.

      --

      Less is more !
    9. Re:Zope by axxackall · · Score: 1
      The ZCatalog is Zope's built in search engine. It allows you to categorize and search all kinds of Zope objects. You can also use it to search external data such as relational data, files, and remote web pages. In addition to searching you can use the ZCatalog to organize collections of objects.

      The ZCatalog supports a rich query interface. You can perform full text searching, and can search multiple indexes at once. In addition, the ZCatalog keeps track of meta-data about indexed objects.

      You can do even named and nested queries with ZCatalog thus building ad-hoc queries.

      Searching the ZCatalog works a lot like searching a relational database, except that the searching is more object-oriented.

      So in some extent ZODB has ad-hoc queries.

      --

      Less is more !
    10. Re:Zope by axxackall · · Score: 1
      Also, of course, how would you perform a JOIN (e.g. relate two lists)?

      There are at least one known effort: ZSQLCatalog: querying Zope Catalog with SQL.

      ZSQLCatalog is an extension to the traditional Zope ZCatalog and Indexes. It currently implements an Index which uses an SQL database as external storage. It allows to query a Zope Catalog with a combination of traditional Zope Catalog queries (field based, text based) and with complex queries implemented as SQL methods.

      By using ZSQLCatalog, it is possible to develop a whole system with an object oriented approach and forget about external relational databases yet provide to users the usual experience of SQL queries.

      --

      Less is more !
    11. Re:Zope by Tailhook · · Score: 1

      As for the Join- This would depend on the circumstances.

      This is another way of saying "write more code".

      Please don't be offended; Zodb, and it's lack of a query mechanism, isn't your fault. Let's just not paper over the fact that object stores have no widely used and well understood means of returning results. Each result is the product of some custom code written by a programmer. You must code imperative logic that hunts through the object model, hopefully correctly (which is hard to prove.)

      --
      Maw! Fire up the karma burner!
    12. Re:Zope by Lodragandraoidh · · Score: 1

      I started out playing around with ASPDB - but that was a pain in the butt - and not very intuitive for a programmer. Additionally, it was expensive and only ran on windoze.

      I just recently found Zope, coinciding with the dipping of my toes into python (I'm a Perl/Java/C++/Lisp/Fortran kind of guy...) The thing I found most interesting about it was the ease, out of the box, with which you can get some working code up and running. No tweaking mysql tables; no cryptic ASP/PHP script; no windoze ODBC services to manage. Its clean and simple to use.

      The sweet thing, imho, is the scalability. You have the option of using zcat objects to create dynamic large scale applications; or, you can integrate it with a relational database if you positively, absolutely, must use an RDBMS. I have yet to get to the point where I needed that extra sliver of performance an RDBMS provides.

      I think alot of the issues surrounding holy wars are the result of people being used to doing things a certain way, from an architectural standpoint ("By God we must have an RDBMS or it isn't a real application!"). I think alot of people have a tendency to 'gold plate' every application - when that is absolutely NOT necessary. So, how should we determine what to use? I would recommend the following:

      a) How much data, and what kind of data are we talking about? (lots of small records, a few blobs, lots of blobs etc...)
      b) What is the uptime needed on the data (be honest...can we be down for several hours, or must we be 24-7?)
      c) Can uptime be ensured with hardware (RAID, mirroring, network fail-over [HP Service Guard for example]), or will automated backups be enough?
      d) What tools will do the job well enough and cheap enough? Corallery to that: what do we know now, and what will we need to know to make new tools work?

      Some time should be spent learning new tools and deciding for yourself if one or more is right for you. I would urge you to do this, because it will make a big difference in your performance over time. Having a well stocked tool box is no different than knowing the strengths and limitations of various tools.

      Unfortunately, we can't 'know it all' - but we can make informed decisions based on experiences with a wide variety of ways and means of doing things. If a shell script will suffice - by all means, write a shell script. Don't be stuck writing a full blown java RDBMS application, when all you need is 'grep'.

      --

      Lodragan Draoidh
      The more you explain it, the more I don't understand it. - Mark Twain
    13. Re:Zope by Anonymous Coward · · Score: 0

      ... Which is why an Object database will never replace a relational database for serious storage of relational data. There are a lot of circumstances where an Object database is more apropriate however. The two are not mutually exclusive.

    14. Re:Zope by platypus · · Score: 1

      Excellent summary. I'd like to add that the ZODB guys also don't go around telling everyone how their product will make Oracle/Postgres/DB2 obsolet.
      IMO, that's a big plus for them, as it shows they know their stuff.

    15. Re:Zope by g_braad · · Score: 1

      But please, take note: ZODB is NOT ACID compliant.

      http://zope.org/Wikis/ZODB/FrontPage/guide/node3 .h tml
      ZODB doesn't provide Consistency

      --
      F/OSS & IT Consultant
    16. Re:Zope by MattRog · · Score: 1

      It only 'supports' *some* logical integrity if you code it that way -- which means you have to do more work, it's more succeptible to bugs, you can forget to do it, etc.. Of course, there is more to integrity than foriegn keys.

      --

      Thanks,
      --
      Matt
  35. Yippee by Anonymous Coward · · Score: 0

    Wow, this is great news!

    But what is a RDBMS?

  36. SQLite by Electrum · · Score: 2, Interesting

    SQLite is tiny, fast and ACID compliant. SQLite is a public domain embedded SQL database library. It is similar to BDB, but provides a complete SQL database.

  37. Not so... by Phil+John · · Score: 1

    read the FAQ

    Does Prevalence Only Work In Java.

    No.

    You can use any language for which you are able to find or build a serialization mechanism...

    --
    I am NaN
  38. How about a radically different solution? by MSBob · · Score: 1
    Maybe we don't really need a better match between OO and RDBMS? If OO has such a strong impedance mismatch with Relational technology perhaps it's OO that is really flawed and not RDBMS?

    It once struck me that one could hypothetically develop a language that is table based. Not a language that is table friendly but a language that is built on tables. Sort of like Lisp treats everything as a list this language would treat everything as tables and have a built in capability to evaluate and modify tables. Of course every table 'eval' would return another table that could be 'evaled' just like lists in lisp.

    Maybe such a language is not practical for a variety of reasons but it certainly would suffer no impedance mismatch with an RDBMS. As a matter of fact its runt time would be an RDBMS.

    Silly? Maybe. But I think everyone who's worked on enterprise OO application has this feeling that something between these two just doesn't click. Right now, for a java developer at least, the least painful option seems to be Hibernate. Great implementation even if the whole paradigm is flawed :)

    --
    Your pizza just the way you ought to have it.
    1. Re:How about a radically different solution? by Anonymous Coward · · Score: 0

      hahahahhahhahahh ha

      hahfa
      hfdsa

      you are joking right?

    2. Re:How about a radically different solution? by Anonymous Coward · · Score: 0

      nope

    3. Re:How about a radically different solution? by Anonymous Coward · · Score: 0

      Lisp hasn't treated everything as a list for about 20 years. Try Common Lisp with Uncommonsql sometime. Illustrates that the impedance mismatch between RDBMS and OO is really between RDBMS and lame-ass Java-style OO, not an intrinsic problem of full OO like CLOS.

    4. Re:How about a radically different solution? by MSBob · · Score: 1

      Why would CLOS be easier to use with a RDBMS than Java? That's a very strong statement. Please explain.

      --
      Your pizza just the way you ought to have it.
    5. Re:How about a radically different solution? by Anonymous Coward · · Score: 1, Insightful

      Because the MOP means CLOS is infinitely mutable, and therefore you can mould the properties of CLOS to fit better with relational theory, with accessor methods capable of arbitrary joins and whatnot?

      Because CL has restartable conditions, not mere exceptions, thus making preservation of transactionality orders of magnitude easier?

      Because CLOS is multiple-dispatch, so you don't have the conceptual problem of methods "in" classes, to confuse you when you try to operate on the results of an SQL join?

      Because a few lisp macros let you merge an sql sublanguage into lisp?

      Seriously, check out uncommonsql!


      (sql:def-view-class employee ()
      ((emplid :db-kind :key :type integer :initarg :emplid)
      (first-name :accessor first-name :type (string 30) :initarg :first-name)
      (last-name :accessor last-name :type (string 30) :initarg :last-name)
      (email :accessor employee-email :type (string 100) :nulls-ok t :initarg :email)
      (companyid :type integer)
      (company :accessor employee-company :db-kind :join :db-info (:join-class company :home-key companyid :foreign-key companyid :set nil))
      (managerid :type integer :nulls-ok t)
      (manager :accessor employee-manager :db-kind :join :db-info (:join-class employee :home-key managerid :foreign-key emplid :set nil)))
      (:base-table employee))

      ;; Employees of Widget's Inc.
      (sql:select 'employee :where [and [= [slot-value 'employee 'companyid]
      [slot-value 'company 'companyid]]
      [= [slot-value 'company 'name]
      "Widgets Inc."]])

    6. Re:How about a radically different solution? by Anonymous Coward · · Score: 0
      It's not about being table-based or object-based. It's more of the fundamental paradigm. SQL and relational algebra is great for specifying what you want and separating out how it should be satisfied - relational algebra is almost functional. It's, however, not good at procedural code and you typically do have that in your app.

      BTW, I don't really see how to do things like fancy aggregates in prevlayer. I think they seriously underestimate the value in separating access from storage model.

  39. Prevayler sucks. by Anonymous Coward · · Score: 0

    No, really. RDBMS are many times more powerful. If you're doing something mickey-mouse, then fine, use prevayler. I won't stop you using it or ZODB.

    Then, when $business wants to ACTUALLY DO SOMETHING USEFUL with the data that $oo-weenie didn't think of, you can pay $consultant to migrate it to an RDBMS anyway.

    Personally, I'd much rather use an RDBMS->OO binding layer like (Un)CommonSQL anyway, even if I were programming in OO (and I'd only settle for CL-style OO, too).

    1. Re:Prevayler sucks. by yerricde · · Score: 1

      If you're doing something mickey-mouse

      Then Disney will come after you for trademark[1] infringement.

      [1] Disney owns no copyright on Mickey Mouse.

      --
      Will I retire or break 10K?
  40. business programmers make a database by Anonymous Coward · · Score: 1, Insightful

    Nice of you to mention Crystal Reports. I still am able to sell dBaseIII and ParadoxDOS programs, and I do quite well. They're great for implementing business rules.

    I've never been able to make heads or tails of the Python content management systems. I read all that stuff Rueven Lerner publishes in Linux Journal, what the hell is he talking about?

    I write programs to manage volunteers, clients, keep track of both inkind and dollar donations, MySQL and php work OK. I'll never figure out Zope and any of that other OO stuff. It's all Scientology to me.

  41. Swapping out? by ciroknight · · Score: 1

    I'm not sure about this, because I'm not exactly sure how the program works, but from what I understand, the main whoop about it is that it simply uses the ram as a hard drive to highly increase speeds. I saw some users on here talking about how it would end up being slow, especially for millions of users, where most of the data on those users would just sit in the ram and eat up space. Well, wouldn't any well designed operating system swap out the memory pages that haven't been accessed in ages? It sorta defeats the purpose of having it in ram, but at the same time, it works. Also, a well maintained database wouldn't keep records that were that old, but instead would store them to a more permanate solution such as a Tape Backup or a hard drive array.

    Furthermore, ram is dirt cheap, and with the advent and steady rise of Flash RAM and mram (not sure if this is what it called, but it performs like dram, but like flash ram, won't lose data without being refreshed every so often by converting the electrical impulses into magnetics), but you should be able to fit enough of this ram into a machine (ie, look at the virginia cluster, cut it in half, and you should have about the power), back it up to a hard drive array every so often, and poof, there you have an enterprise solution. I really like this idea.. good work Klaus!

    --
    "Victory means exit strategy, and it's important for the President to explain to us what the exit strategy is." G.W.Bush
  42. benefits of an RDBMS by jadavis · · Score: 4, Insightful

    I'm not about to give up PostgreSQL.

    An RDBMS:
    * Allows a wide variety of applications to operate on the data, in a wide variety of languages, at different times or simultaneously.
    * Allows you to manipulate the data inside the database before you get it.
    * Allows for a lot more storage, which is sometimes important when you need the memory for some other task.

    What I like about an RDBMS (like postgres) is that my requirements constantly change. I try something for a while, then we have better ideas, but we need to work with our existing data. An RDBMS allows me a huge amount of flexibility with my data (also the reason I don't use MySQL...) and I've been able to drastically change the way my application works while still making use of the data that I have.

    Maybe this is an OK database for some applications where you have the entire thing laid out in a perfect spec with no chance of a change. However, when I need to get at my data with another language, or it takes up more space than I thought, or I figure out that my application needs to change the way it works, I have no clue where to begin with a huge collection of "objects" that now happen to be obsolete. If I have relations, I have a solid representation of my data that an RDBMS can manipulate efficiently according to a fairly mature mathematical model. I'll take that over a collection of persistant objects any day.

    That said, I think this has application in areas where you just need some persistent objects, and they need to be fast, and they don't take up much room. I don't encounter that very often, and when I do I usually just use postgres because it seems fast enough when the tables are cached. I suppose if the objects are really intricate this would be a nice system, because you wouldn't have to spend so much code on a mapping. It just seems so much more narrow as far as usefulness.

    --
    Social scientists are inspired by theories; scientists are humbled by facts.
    1. Re:benefits of an RDBMS by William+Tanksley · · Score: 1

      Great post, I agree (and I like and use object prevalence). I just have one question:

      What does your statement, "Allows you to manipulate the data inside the database before you get it," mean? How can you manipulate data you haven't gotten yet?

      -Billy

    2. Re:benefits of an RDBMS by jadavis · · Score: 1

      Oops, a little unclear. I just meant that you can manipulate the data through SQL and stored procedures before sending it to the application. The basic idea is that you only get the data you need immediately in the application. This also means that the way your application sees your data can be entirely different from the way it's actually laid out in tables (i.e. maybe you have a view).

      This method is in contrast with the method of reading more data than you need (or data in a different format than you need) and processing the data further within the application. It's common in MySQL to do something like this because there aren't subselects or constraints, or a few other things that would help people process the data in the DB server.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
  43. Distributed environment by Lysol · · Score: 5, Informative

    I tried Prevayler and even loaded in 50k records from an old product table and object-ized them.

    Yah, it was fast. Searches were great. I even figured out how to do complex object joins.
    But I started having trouble when I tried to figure out how all the transactions worked. This was complicated by the wiki they're using, which was quite useless to me. It lead to many dead ends.

    However, the real reason I found that I could not (possibly ever) use Prevayler is becuase it seemed the approach was for one machine and one machine only. There were no distributed mechanisms at all. Or at least, not how I'm used to working.

    All the systems I've worked on in the past five years have all been with clusters of app servers. If all the objects on one machine were all in memory, then I couldn't think of an easy way to get them into the memory of the other machines. There was some talk about using Java Spaces, but that's kinda where I dropped off.

    And the other issue was getting to the data from non app server machines. Like stuff to do back end reporting and things like that. I bascially figured out that for n-machine access, I needed something that, well, acted like a database.

    I thought the idea was very interesting and maybe these things have been addressed. But when I really sat down with it for a few weeks, it just didn't pan out for me.

    1. Re:Distributed environment by Anonymous Coward · · Score: 0

      Actually (and we did this as an experiment), Prevayler should work fine in a distributed environment. Have one machine be the gatekeeper nd distribute the data through a bunch of other machines, each of which has it's own Prevayler based system.

    2. Re:Distributed environment by Anonymous Coward · · Score: 0

      There's a clustered in-memory product in Java from Tangosol.

    3. Re:Distributed environment by Anonymous Coward · · Score: 1, Informative

      For in-memory distributed database, please have a look at Mnesia (http://www.erlang.org and http://www.erlang.org/doc/r9c/lib/mnesia-4.1.4/doc /html/index.html)

      --
      Mickael Remond

    4. Re:Distributed environment by onash · · Score: 2, Informative

      this combined with JavaSpaces is really intresting, like http://www.j-spaces.com/database1.htm . I don't understand why Prevayler has reached Slashdot two times now, when its nothing new..

      also, this is more an DBMS alternative than a RDBMS as you have to make all the relations in you'r own code, but not in the "DBS".

    5. Re:Distributed environment by julesh · · Score: 1

      However, the real reason I found that I could not (possibly ever) use Prevayler is becuase it seemed the approach was for one machine and one machine only. There were no distributed mechanisms at all. Or at least, not how I'm used to working.

      Having looked at the architecture back in the v1 days, I'd say its key strength is its simplicity. It might not have any distributed features, but you can add them yourself fairly easily.

      First level of distribution: separate data storage from business logic (easy; just use RMI to pass your transactions / fetch requests to a simple back end that interfaces pretty much directly to your object storage).

      Second level of distribution: too many queries to handle in a single server? Implement object caches that communicate directly with the server. The object caches can have the same RMI interface as the original data storage server, so this can be transparent. Transactions are forwarded to the actual data storage server, which can be arranged to invalidate modified objects on the caches through simple updates to your command classes.

      Third level of distribution: need failover? Have multiple data storage servers and make them pass transactions retrieved to all the others. They'll have to agree on the order to execute them which will slow things down a litte, but probably not horrendously.

      Anything I've missed?

      Of course, I reckon it'd be almost as easy to start this from scratch as to use their architecture. Last time I looked at their code (back when the last /. article was posted), it was something like 200 LOC. And the idea's very easy to understand.

  44. Change the headline. by Anonymous Coward · · Score: 1, Insightful

    Of course it will suck if your project doesn't fall in those categories. Everyone can see that.

    Sure, everyone except the person that posted it and the editor that let the story through. I'll admit I got sucked into reading more because of the overly generalized claims. "Bye RDBMS?" in the headline? Gimme a break. Prevayler is an incredibly specialized tool that won't be able to solve many real-world problems currently solved by an RDBMS.

    Prevayler seems like a great idea. It doesn't need the deceptive hype. How about "Bye RDBMS for projects with fit-in-RAM databases?"

  45. Obviously enough .. by theefer · · Score: 1

    .. you swap !

    --
    theefer
  46. What about EOF? by eweu · · Score: 1

    "If there are so many after-the-fact solutions attempting to simplify relational database access and manipulation from OO, isn't it reasonable to think that there is something generally wrong with trying to cobble-together two disparate concepts with what are essentially high-caliber hacks?"

    No. EOF and WebObjects solved this problem nicely years ago.

    1. Re:What about EOF? by ninejaguar · · Score: 1
      Thanks for the links, but what you're offering as a solution is apparently Apple's version of Enterprise JavaBeans. I don't have to pay Apple for that. I can download EJB for free from Sun, but I'll still have to deal with an Object-to-RDBMS-to-Object issue at a particular location within an application.

      Also, I'm not sure about this part, but it seems to me that WebObjects = Web-Services. Just the names of the innocent have been changed. There's nothing stopping a Prevayler built app to perform or utilize Web-Services, or even EJBs.

      = 9J =

    2. Re:What about EOF? by eweu · · Score: 1

      Apple is unfortunately marketing WebObjects as part of the WebServices and EJB scene. It most certainly is not, though. EOF is far superior technology to EJB. It is exactly as I described: An object-oriented model of a relational database. It's extremely powerful. The learning curve is steep, but the reward is worth it.

      I would never suggest EJB to anyone unless I wanted to cause great suffering on their part.

  47. Re:RDBMS makes *BSD look alive and kicking by the_mad_poster · · Score: 1

    Are you trolling or are you actually dumb enough to believe what you just said?

    You are aware, I assume, that hierarchical databases are an older concept than relational databases and were ditched as far as mainstream implementation went ages ago? You are aware, I assume, that these concepts are not new - just old technology that has long been dismissed as being useful in niche situations only that's being dusted off for no apparently good reason?

    You're aware, I assume, that none of the DBMSs you mentioned are truly relational, and, if they were, they wouldn't suffer from the problems that are most commonly complained about?

    You are aware, I assume, of the difference between SQL and "relational *"?

    You are aware, I assume, that your comment was utterly ludicrous?

    --
    Alito: A vote for Alito is a punch in the eye to put that bitch back in her place!
  48. Multiuser? by __past__ · · Score: 1
    How does that work when you have multiple processes, potentially implemented in various different programming languages with different object models, that need to access this data concurrently? Will my "database" still work after I modify my persistent classes, or do I have to convert it somehow? What about access control that is guaranteed to be shared by all database-accessing apps?

    This might be nice for a certain class of applications, but unless that all (and more) works - and I can't see how it could - I wouldn't be too frightened if were Larry Ellison.

    1. Re:Multiuser? by jadavis · · Score: 1

      Agreed.

      I just had the thought that this software will make people who just need object persistence "wake up" and figure out that they don't need to carry around a big RDBMS if all they have is a straightforward app that needs persistence.

      I think there are a lot of MySQL users out there that could get by with just a persistence system like this. That statement isn't made to reflect poorly upon MySQL (disclaimer: I don't like mysql), but that MySQL has a tendency to market their database, and position it, for similar tasks. They can't have that large a market share without some people using it for the wrong reasons.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
  49. Well, when you operate on the atomic level... by BigRare · · Score: 2, Funny
    In the prevalent design, every transaction is represented as a serializable object which is atomically written to the queue (a simple log file) and processed by the system.
    Taken from: Here

    And I thought Quantum Computing was still part of the distant future...
    1. Re:Well, when you operate on the atomic level... by pivo · · Score: 3, Informative

      Atomic, The A in RDBMS ACID (Atomic, Consistent, Isolation, Durable) transactions.

      Atomic transactions consist of grouping of changes to tables or rows such that all or none of the changes take place. A rollback operation can reverse all the actions of the atomic transaction.

      From the Greek atomos for indivisible

    2. Re:Well, when you operate on the atomic level... by Anonymous Coward · · Score: 0
      From the Greek atomos for indivisible

      And people wonder why the ancient Greeks never got the bomb.

      aYLFI

  50. Can't run reports by kpharmer · · Score: 2, Insightful

    A quick search on the wiki showed no hits for the word 'report'.

    Note that the classic problem with object databases is that they focus on transactional queries, and that DSS or reporting queries are either too slow or too difficult to perform.

    So, yeah it sounds nice if you want *both* an object database and a relational one. Not a bad solution if you already have a data warehouse on the side. But if you don't it just a lot of extra work.

    Next...

    1. Re:Can't run reports by Joseph+Vigneau · · Score: 1

      A quick search on the wiki showed no hits for the word 'report'.

      Did you try clicking on "Find Page", and typing in "report" (sans-quotes) in the "Search by topic content" field? I found this pretty easily:

      Creating Reports With Prevayler

    2. Re:Can't run reports by kpharmer · · Score: 1

      No, I just did a find on the main page.

      But since reporting is about 50% of what databases are used for, it should be very easy to find.

      Unfortunately, the link you discovered was simply to a question and speculation about using XML for reporting, rather than any actual solution.

      Until they can actually solve the problem, it's just an curiosity.

  51. ACID - what about the C ? by MaxTardiveau · · Score: 2, Interesting
    Consistency? Admittedly, most databases barely address that (domain checks and referential integrity are only a start).

    Not having a SQL interface closes so many avenues... For a nifty (and remarkably solid) light-weight database, take a look at McKoi.

    Max

  52. OJB doesn't compete, really by Anonymous Coward · · Score: 0

    Thomas Mahler of OJB has almost finished back-end support for prevayler.

    So, in addition to many commercial and open source RDBMS's, OJB also supports this great OO platform.

    cheers,
    Matthew Baird

  53. BINGO!! by Anonymous Coward · · Score: 1, Funny

    My proactive leadership must be working.

    So if I understand you correctly you want software that will B2B edutainment portal internet enterprise mission-critical?

    Yeah.

    The buzzword-compliant expansion of "enterprise" is:"scalable enterprise PPP2P pan-galactic redundant XML warp drive," but it's "enterprise" for short.

  54. Whew... by Anonymous Coward · · Score: 0

    "Despite fear, doubt, and memory concerns, it has reached 2.0 alpha."

    Whew! I'm sure there's no problems with uncertainty, otherwise I would think the project is doomed.

    Interestingly, I know developers can submit patches to solve "memory concerns," but what kind of work can they do to solve "fear" and "doubt" ???

  55. How can we say goodbye to RDBMS by kfg · · Score: 1

    When we haven't said hello to one yet?

    I'm not sure how you can say your new technology is better than the old one when you haven't even bothered to check out a fully implemented version of the old one.

    KFG

  56. Call me irrational, by M.+Silver · · Score: 1

    but I don't buy from companies who market unethically.

    If you haven't got the guts to admit you're connected to a project you're pimping, you've lost any respect I might have had for the project.

    --

    Slashdot's token middle-aged housewife
    1. Re:Call me irrational, by ninejaguar · · Score: 1
      Actually, I ran into this project about a day before I posted the article. I found a reference to it in a previous slashdot article, and read as much as I could find on the project. I was impressed enough by the range of applications this could be used in, that I wanted to let slashdot know it had been developed further since its first coverage. I'm not sure what can be meant by "marketing unethically" as I wasn't "marketing" for personal gain other than information and opinions. I'm happy to say, that there are some gem responses in the rough.

      I have no connections with this project, and never claimed to have anything to do with it. However, the first batch of comments making various unverified assumptions in slashdot, is a study in sociological responses to what is conceived as an attack on an age-old belief (RDBMS is good, anything else is bad). This can be construed as conservatism. True, Slashdot as a whole has never claimed to be a liberal thinking body. It is easier to see in this article, more than most, the fundamentalist nature of quite a few slashdotters. Introduce a possible new perspective, and a small percentage of knee-jerkers claim first post, followed shortly by the more rational thinkers. The project's author writes about such responses at his wiki (which needs to be replaced by a more cohesive website).

    2. Re:Call me irrational, by M.+Silver · · Score: 1

      I have no connections with this project, and never claimed to have anything to do with it.

      You probably should have said so up front, while you were pimping it.

      It's amusing that you credit the assumption to an "age-old belief." If you'd come in here claiming relational databases were the Second Coming, I'd have given you the same response. And, you know, you *still* haven't given me any reason not to assume you're astroturfing. If you're not associated with this magic bullet, who *are* you?

      --

      Slashdot's token middle-aged housewife
    3. Re:Call me irrational, by ninejaguar · · Score: 1
      You probably should have said so up front, while you were pimping it.

      In hindsight, you're probably right. Although, there's no guarantee it wouldn't have sounded false to those who flame first and ask questions later, which encourages the same response from others of similar temperment; at least until the patient-explainers and the truly-curious start posting. Let's hope you don't make the same mistake when your first article gets accepted.

      "who *are* you?"

      A heavy question. No one could give you a satisfactory answer to that one, so I'll just have to allow my article's questions to define for you who I am.

      I also can't prove to you that I'm not *astroturfing*. As your questions are honest ones, I'll explain something about the article. You'll note that the first paragraph is different from the ones that follow. The reason is simple; slashdot wouldn't allow me to submit a book-sized article and I had to fit all my questions into an unfortunately cramped format. The result is an unappealing, marketoid style. Though, as it turned out, quite effective in eliciting responses.

      The knee-jerk reactions from the crock-o-shitters clearly had more to do with the style than the content of the piece. People were posting responses immediately after the article was made available, not having had much time to look into the subject in depth (or the working links). As much as I regret the waste of eye-bandwidth from the first-posters, I actually empathize with the strong emotional need to conserve the status-quo. We all have convervative and liberal elements in our character. It's just a matter of perspective. To make an analogry, one man's conservationist is another man's tree-hugger. Here was what appeared to be inflamatory statements made about a fundamental aspect, even cornerstone, of modern-day development. Something that all developers had to expend tremendous mana to gain an understanding of. Who wouldn't want to grab a torch and pitchfork?

      The article's intent was very simple, and it wasn't to be a focal point for furious discussions. Wait, that's a lie; of course it was. I didn't post it to be ignored. I wanted to learn more about the product and its place from others.

      I'll share with you some findings (thanks to some very perceptive slashdotters). Simply stated, the tool has very good qualities (I won't go into the specifics, you know where to find that), and some qualities that require further work. It can be used as of today, but it will come into its own in a few years. If I were forced to hazard a guess, I would say somewhere between 2006 and 2009. It may not even be this product, but something like it. If it were to be used today, it's best niche would be to replace the countless FoxPro, Access, FileMaker Pro "departmental" file-based database applications with a web-based solution. You won't see many 1 gigabyte .dbf or .mdb files out there due to easy corruptibility, and Prevayler can step in to take their place. Its biggest flaw, and there aren't many, is that once an application has been structured, it's difficult to alter the "database" design (or schema) within the application. This also happens to be the flaw in file-based database applications made in Clipper, dBase, or Paradox. There may be a way for Prevayler (and its clones) to get around this, though at the moment I can only guess that Aspect Oriented Programming practices might be of use.

      I wish the Prevayler team thanks for thinking outside the box, and giving us something interesting to think about.

      = 9J =

  57. Hey Fag, Listen Up by Anonymous Coward · · Score: 0

    Join the HFLU association today!

    Learn some english, you sound like gap-toothed romanian trash.

  58. Are these questions rhetorical? by Fnkmaster · · Score: 1
    Can we predict the death of the RDBMS? Is it time for Oracle to roll over and play dead? Do I really know that the questions I'm asking are ridiculous? Is it possible that I'm just begging the question here? Do I realize that plenty of people have built systems to handle queries from memory without hitting the disk? Do I realize these are only appopriate for a very limited domain of problems? Could we come up with a worse name for a project than "Prevayler"?


    And most importantly, was Cliff smoking something when he posted this, and if so, where can I get it?

    1. Re:Are these questions rhetorical? by f00zbll · · Score: 1

      OODBMS is an old concept that is only practical in limited domains. The best domain for OODB is directories. For most other business applications, OODB is very difficult to change on the fly and often requires recompiling/rebuilding the whole database. Basically static models that never change. If your model has to be flexible, OODB is horrible. I know this from first hand experience trying to use LDAP.

    2. Re:Are these questions rhetorical? by Anonymous Coward · · Score: 0


      And most importantly, was Cliff smoking something when he posted this, and if so, where can I get it?

      Smoke my Cliff and some of my genes can get absorbed into your body, thus making you less stupid.

  59. Don't use it by www.microsoft.com · · Score: 0

    What do you do if you have a nice big data set that won't fit in memory?

    Don't use it. There is diferent software for diferent needs.

  60. You own shares in Prevalayer, angel'o'sphere? by Anonymous Coward · · Score: 0

    A dozen posts by you defending this braindead in-memory persistance scheme - why? Have fun developing your non-multiuser easily corrupted Prevalance-based systems.

  61. zero bugs? by JsTwO · · Score: 1

    Features

    Transparent Persistence for native Java business objects.

    3 to 4 Orders Of Magnitude Faster than databases via JDBC.

    ACIDTransactions.

    Zero Bugs.

    could this be a world record?

    1. Re:zero bugs? by Anonymous Coward · · Score: 0

      Zero Bugs.

      could this be a world record?


      No. TeX has been bug free for years.

  62. It will solve all of our RDBMS OO woes! by commonloon · · Score: 0

    ...and better yet, it has "Zero bugs." Ummm....

  63. How about Jasmine [Computer Associates/Fujitsu]? by Anonymous Coward · · Score: 0

    Does anyone have any experience with Jasmine? [I think the marketing droids renamed it to some bland, drab, politically correct gobbledygook like "Advantage Integration Server" or some such nonsense.] We are thinking about giving it a test drive for our new database.

    We would like to use it in a medical setting where we will be bringing in lots of multimedia samples [digitized video of surgeries, digitized electrocardiograms, digitized blood pressure readings, and the like], together with a handful of traditional ASCII parameters [name, rank, serial number], and Jasmine seems very intriguing.

    Any anecdotes or insight would be most appreciated! Thanks!

  64. TummyX, I cannot mentor you for free on Slashdot by Anonymous Coward · · Score: 0

    There's a lot of information about distributed database integrity on the net. Take a look at it sometime when you pull your head from your ass.

  65. OO-to-RDBMS complexity? by Kurtv · · Score: 1

    "OO's rough courtship with Relational databases", I must be missing somthing.... Do people think that RDBMS is that complex? Or are these the same people using MS Access.

  66. Counter Hypothesis by ogren · · Score: 2, Interesting

    From the Wiki:

    Prevalent Hypothesis:
    That there is enough RAM to hold all business objects in your system.

    IMO, this hypothesis doesn't hold water for 99% of business applications. Prevalent proposes that even if this hypothesis doesn't hold today, it might soon hold true because of breakthroughs in memory technology. But historically these types of ideas are flawed, as the real world has clearly shown that memory and disk needs will grow even faster than our ability to use those resources.

    Sure I can take a 1998 application and run it with breakthrough performance by caching the whole application in memory. But I don't want a 1998 application, I want a 2003/2004 application. Do you think that the entire Slashdot comment database would fit into a couple of gigs of memory? How about the enite customer database for an average enterprise?

    Frankly, if my database is so small that it fits into memory then I probably don't have performance as a primary concern anyway. Plus, do I really want to subject my entire database to constant mark and sweep garbage collection if performance is an issue?

    --
    ogren
    .no sig

    1. Re:Counter Hypothesis by ninejaguar · · Score: 1
      I suspect you could replace most file-based databases with this application, and at the same time offer a web-based solution. Wherever there are Access, FoxPro, dBase, FileMaker Pro databases, this can take their place.

      = 9J =

  67. RDBMS != Object Store by Frater+219 · · Score: 5, Informative
    It's true that an RDBMS doesn't map well to the object-oriented ideology. That's because an RDBMS does not store objects, or anything like them.

    The object-oriented ideology as instantiated in C++ and Java is founded upon breaking data into objects, bearers of identity, which belong to classes, bearers of structure and behavior. (C++ and Java make little account of metaclasses, which are used in more dynamic object systems such as Python's class system and Common Lisp's CLOS. Templates are not metaclasses.) Objects have identity, so they can be equated; they are the unique bearers of attributes about themselves; and each object's structure is dictated by the class to which it belongs.

    When object-oriented partisans look at a database, they see its relvars (or table headers) as bearers of structure and think of classes, and its tuples (or rows) as bearers of identity and think of objects. They see a database as a place to store objects persistently.

    But this is not what an RDBMS does. An RDBMS isn't an object store; its relvars are not classes and its tuples are not objects. So what is an RDBMS? What is "relational" anyhow? Relational databases are founded upon relational mathematics, which is what you get when you cross set theory with predicate calculus.

    Set theory is the branch of math that deals with collections of elements which behave according to formal axioms. Set theory lets you say, for instance, that if you have a non-null set R and a non-null set S, that you can construct a set R*S of all the possible pairs of elements from R and S.

    Predicate calculus is the branch of logic that deals with quantified statements about entities. It lets you formalize logical arguments such as the syllogism: All men are mortal; Socrates is a man; therefore, Socrates is mortal. Predicate calculus deals with generalizations and instantiations of those generalizations.

    What do we get by combining set theory and predicate calculus? We get a system that allows us to operate upon sets of tuples of values satisfying predicates. A relation holds tuples of values which make some predicate true. For instance, consider the predicate "Person x owes me y dollars." Tuples which satisfy this predicate will be pairs (x,y) for which the sentence is true. For instance, if Fred owes me 40 dollars, (Fred, 40) satisfies the predicate. It could thus be a tuple in the relation described by the predicate -- the one relating people's names to how much they owe me.

    With the relational algebra (or an RDBMS) we can do operations upon this relation and others. We could, for instance, select a result set of all those people who owe me more than 50 dollars -- or join this result set with those people's addresses. Whatever result set we ask for will be calculated from the facts in the database. We might get back this result set:

    (Barney, 75, 40 Elm Road)
    (Megan, 60, 9 High Street)

    Now, are the elements of this result set objects in the object-oriented sense? They are not. They do not have identity. The tuple about Barney is not Barney himself, or even a machine representation of him. It doesn't uniquely store attributes of Barney -- after all, we created it by joining tables which also contain such attributes. It is not even, truly, a fact about Barney exclusively -- for it is also a fact about the number 75, and about the address 40 Elm Road. It isn't an object; it's a tuple value, and values do not have identity as objects do.

    Moreover, note that by joining, we can construct new relations from old ones. Thus, not only are tuples not objects, but relvars are not classes. After all, in OO we do not create new classes by joining, but by inheritance or encapsulation of old ones -- and creating a new class does not cause it to be instantiated into known-correct objects.

    So what does this matter to OO people faced with RDBMS as a

    1. Re:RDBMS != Object Store by KyleW · · Score: 0

      This fact plays well in a scientific computing environment such as MIT. It does not match what the majority of systems do today: Solve a business problem. OO languages make it easier to develop business solutions and RDBMS are indeed ideal object stores for this purpose. I love computer science and computing theory about tuples, facts, lists, relvars and all but, once you leave university you might as well flush all that crap back down the toilet. Try telling a manager that they should consider using an object relation database for this project or using a lisp interpreter and they'll tell you to STFU and go back to your desk.

      --
      1st known failed CIA coup in South America : http://www.chavezthefilm.com/index_ex.htm
    2. Re:RDBMS != Object Store by MattRog · · Score: 1

      You seem to know a bit on relational ideas, but really don't know much about the relational model.

      The relational model is a general model of data -- it can model anything, including what one would think of as a typical object. Remember that no SQL product today is a RDBMS.

      Rather than wasting my time typing it out, check out this site:
      http://www.dbdebunk.citymax.com/page/page/627014.h tm

      --

      Thanks,
      --
      Matt
    3. Re:RDBMS != Object Store by Anonymous Coward · · Score: 0

      uh...dude...what you're saying is that barney owes you some money?

    4. Re:RDBMS != Object Store by MattRog · · Score: 1

      And, of course:
      here and here.

      --

      Thanks,
      --
      Matt
    5. Re:RDBMS != Object Store by Anonymous Coward · · Score: 0

      Excellent, excellent post.

    6. Re:RDBMS != Object Store by telbij · · Score: 1

      Actually, you are oh so wrong! Just because he explained it in a scientific way doesn't mean that it doesn't apply to business problems. I can't tell you the number of times I've had to hack together some new function for my existing databases that had never occurred even occurred to me. If you have yourself a fully normalized relational database, then unexpected data needs tend to be a snap because you can query for whatever you need. Object-oriented programming makes a lot of sense for certain types of problems, but the added organization you get by putting your code and your data into rigid structures makes it very easy to do what you plan for, and painfully difficult to do a large number of things you didn't plan for.

      Even though you might find the flexibility of a relational model confusing and more difficult to work with than objects, the benefits are undeniable in academia or in business.

    7. Re:RDBMS != Object Store by telbij · · Score: 2, Interesting

      Great post, thanks for saving me the time. It's amazing how the hype of OOP has caused so many programmers to just believe that it's 'better' without any kind of understanding of what OOP really provides. Now it's to the point that people are ready to blindly replace RDBMSs with Object-Oriented Databases without stopping to think why RDBMSs have been such a great tool to begin with.

      Citing incompatibility due to SQL variations is the biggest red herring I've ever seen. Designing a relational database to store company data has always been a much more straightforward process than desiging a system of classes. The importance of keeping your data clean and flexible can not be overestimated. If you have good data you can build unlimited apps on top of it without running into the kind of brick walls that rigid object structures can impose. Sure even normalized databases sometimes make tradeoffs based on how they will be used, but you aren't cutting off possibilities at anywhere near the rate you are the minute you try to cram your data into a class tree.

    8. Re:RDBMS != Object Store by Anonymous Coward · · Score: 0
      And, of course: here and here.

      More than one? Man, you need to normalize your website.

    9. Re:RDBMS != Object Store by Frater+219 · · Score: 2, Insightful
      The relational model is a general model of data -- it can model anything, including what one would think of as a typical object.

      Having trotted out "Database Debunkings" before myself, I agree with you in part. Certainly a relational database can store facts about objects. This is, however, not the same as storing objects themselves. The difference is one of identity.

      Chris Date's articles on "OODBMS" seem to deal mainly with the need not to throw away the relational model simply because OO users want more complex data types in order to model objects. This is of course eminently reasonable -- regardless of what data types you are working with, the relational model still makes sense and indeed is required to make your database make sense. It also is orthogonal to the point I was trying to make above.

      The crux of my point is that tuples do not carry identity. Tuples are values, not objects -- they are more akin to the number 5 than to the variable x in the C statement int x = 5; The relational model precisely does not let us talk about their position, address, or pointers to them -- it lets us talk about them only as values, and relations as sets of values.

      You can have tuples about things which have identity -- after all, customers have identity. To represent customers' identity, we may use unique keys. (Incidentally, because they are not unique, SSNs do not form a candidate key.) However, this is "representing facts about entities which have identity", which isn't what OO users want. They want to store data objects that have identity -- because their objects in core do have identity, and all they want from the database is a persistent object store.

      Again: the OO person wants to store objects with identity. The RDBMS offers him the ability to represent facts about objects with identity.

      What do I mean by "identity"? Good question. One simple way of putting it is that objects with identity are unique; references to them can be stored, and they can be addressed and updated uniquely by them. References to them (e.g. pointers) can be compared by comparing the references only. The C++ reference variables (or C pointers) first_customer and current_customer point to the same object iff they are themselves equal. We can store a reference to that object by copying a reference variable -- and when we indirect through it later, we know we will get the same object, not merely one with the same values. The relational model does not admit of such objects -- it has no pointers, only values in sets.

      (Those familiar with Lisp are reminded of EQ vs. EQUAL.)

      Objects in OO can store references to other objects. Tuples in databases cannot; they can only store common values (like foreign keys). A foreign key is not a reference to another tuple; it is simply a value that is noted as being in common with another tuple, which tuple is in a set wherein that value is unique. So when you store facts about an object into a database, how do you store the fact "this object contains a reference to that other one"? Serial numbers as foreign keys? Then how many passes does it take to reconstitute the pointers in core from the serial numbers in the database?

      The problem of discerning identity out of facts is not simply hard in computing. It is hard in the real world -- that is why it is a major subject of metaphysics in philosophy. (Which has nothing to do with "metaphysics" in the sense of "supernaturalism".) Those who sweep it under the table as "academic theory" or "irrelevant to business" will get bitten by it later in ambiguous results.

  68. Three Words by Anonymous Coward · · Score: 0

    What Not How

  69. Because by autopr0n · · Score: 1

    With C++ alocators you can create data structures right on the disk. You don't need to write your own persistence layer.

    --
    autopr0n is like, down and stuff.
    1. Re:Because by Xeger · · Score: 1

      And with memory-mapped files -- a feature common to all modern OSes -- you can do the same in any language. But that won't really help us, since it would run abysmally slowly. You can't just read an object from disk every time you need to perform an operation on it -- that's taking the worst of both worlds.

      Furthermore, you can't index your objects and query them according to the properties of their fields -- unless support for introspection (enumerating the methods and fields available from a class) is built directly into every class you write. That's a lot of code bloat, and it's ugly and slow. Think of implementing COM IDispatch for EVERY class you want to be part of your database. Ugly!

      No; in C++, you should talk to an RDBMS. In fact, if you're even representing your business objects as C++ objects, you should be taken outside and shot.

      C++ is best for writing lean, mean applications with a moderate amount of UI. I should know, as I'm primarily a C++ prorammer.

      But, really, this is all aside the point. We can have a C++ vs. Java holy war elsewhere. This discussion is about Prevayler vs. disk-based RDBMS.

    2. Re:Because by Anonymous Coward · · Score: 0


      Furthermore, you can't index your objects and query them according to the properties of their fields -- unless support for introspection (enumerating the methods and fields available from a class) is built directly into every class you write. That's a lot of code bloat, and it's ugly and slow. Think of implementing COM IDispatch for EVERY class you want to be part of your database. Ugly!


      arrrgh ... think c++ man, not java! and most certainly not the stupid COM! ms had to use something their silly compilers could handle and that threw templates out of the equation completely.

      so templatize your hierarchy. you can even register every bloody method through that and get some consistent access interface. and the beauty of it is that the compiler generates the bloody code for you. no hassle, a lot easier to maintain. provided that you think ahead when designing the tree. granted, it's not a child's play, but it's quite doable.

  70. Prevayler works at the subatomic quark level by Anonymous Coward · · Score: 0

    Prevayler is not composed of matter or energy. It is unlike anything you've seen before.

  71. And a DB does not make a DBMS by Lucas+Membrane · · Score: 1
    ACID has nothing to do with in-memory, on disk, on paper or WTH. Use a real DBMS if you need one. If you don't, keep playing with this stuff.

    What makes this pre-value-or any better than metakit, gigabase, dybase, mnesia, dbisam, sqlite, or any number of other pretty good data storage contrivances that also can make advantageous, expeditious and efficacious use of memory?

    1. Re:And a DB does not make a DBMS by Roger_Explosion · · Score: 1

      Ergo! Vis-a-Vis! Concordantly!

    2. Re:And a DB does not make a DBMS by Anonymous Coward · · Score: 0

      What makes this pre-value-or any better than metakit, gigabase, dybase, mnesia, dbisam, sqlite, or any number of other pretty good data storage contrivances that also can make advantageous, expeditious and efficacious use of memory?

      From the Prevayler FAQ:

      "Because it just is! Okay? Don't you get it yet? It's better! SQL is for losers! I'm going to hold my breath until you admit that Prevayler is better."

  72. Seperation of data from code? by autopr0n · · Score: 1

    People always talk about seperating presentation from code, but isn't it a good idea to save your data seperate from your code? With a Relational Database, you have a nice sensible collection of data that's easy to understand in any programming language. This object stuff is complex and language dependant. Maybe code and data should stay seperate.

    --
    autopr0n is like, down and stuff.
  73. howto make $$$ with open source by Anonymous Coward · · Score: 0

    1. download latest postgresql
    2. fork it, changing only the name
    3. build a beowulf cluster, with a couple TB of memory
    4. run your database in RAM
    5. ???
    6. profit!!!

  74. very naive by koehn · · Score: 3, Insightful

    These folks are either very naive, or very silly.

    They claim there's no need for two-phase commit (2pc), as though the only systems they need to interact with are (or will be) prevaylor.

    Umm, hello. How about that 50TB database with all our transaction history? You gonna put that in your RAM-based database? No? Well, what happens when you need to do an insert into it, but commit only if the insert and the local transaction succeeds?

    Hell, forget the 50TB database, what about the little Oracle database the guys down the hall use? Or the asynchronous queue that you post into?

    It's a much bigger world than just your little project, guys, and you have to fit into it. 2PC is not an option. It's a requirement.

    The whole "let's keep it in RAM" is cute, and for a lot of projects is probably all you need, but for any kind of large data set you just can't buy enough RAM to hold it all. Once it goes to disk, there's a whole new set of problems.

    Also, the fact that you're responsible for defining and managing your transaction boundaries is really lame. It's not that hard to build check-in/check-out logic that can be used.

    Come back when you have a real system that can handle real load with real datasets. Until then, I'll keep my RDBMS. You may have performance beat on the tiny systems, but who cares? THEY'RE TINY SYSTEMS!

    1. Re:very naive by Anonymous Coward · · Score: 0
      How about that 50TB database with all our transaction history?

      Dude forget about 50TB. Just try a database a table with 2 million rows of data. That will easily eat up 3-4Gb of RAM. This whole prevayler thing is fine for toy apps with less than a million rows of total data. anything requiring real data storage would die with prevayler.

    2. Re:very naive by psyconaut · · Score: 1

      I totally agree. So much in their webpage just makes me think "have you guys actualyl developed or run a commercial database?".

      -psy

    3. Re:very naive by Anonymous Coward · · Score: 0

      From an interview with Google CEO, Erich Schmidt:
      "At Google, for example, we found it costs less money and it is more efficient to use DRAM as storage as opposed to hard disks -- which is kind of amazing. It turns out that DRAM is 200,000 times more efficient when it comes to storing seekable data. In a disk architecture, you have to wait for a disk arm to retrieve information off of a hard-disk platter. DRAM is not only cheaper, but queries are lightning fast."

    4. Re:very naive by julesh · · Score: 2, Interesting

      While I have to agree with some of the things you're saying (like RDBMSs are the way to go for most real world applications), I have to disagree with some things you've said:

      They claim there's no need for two-phase commit (2pc), as though the only systems they need to interact with are (or will be) prevaylor.

      The design decision they've made regarding transaction implementation is kind of orthogonal to their storage decision, although it is a design that works better in memory than it does on disk.

      But, rather than 'begin transaction, update some stuff, check some stuff, if its all ok commit', they do 'prevent any updates that would change the outcome of the precondition; evaluate precondition; if its true, do the updates; allow other transactions to be processed'. Mathematically speaking, these two are equivalent[*], although the latter way is a more difficult way of thinking about the problem that will slow development down.

      The whole "let's keep it in RAM" is cute, and for a lot of projects is probably all you need, but for any kind of large data set you just can't buy enough RAM to hold it all. Once it goes to disk, there's a whole new set of problems.

      The only real problems I can see are 'how do we reliably store this on disk, how do we load it back transparently'. Admittedly, that's a big problem, but its not one that hasn't been addressed before.

      [*]: I can't prove this. It just feels like they must be.

  75. Hurray! End to DBAs on the horizon! by Anonymous Coward · · Score: 0

    DBAs are the most uncomprimising people in the software industry. They seem to think their databases are at the center of the universe and that we programmers need to bend over backwards to make their work easier.

    It's the other way around. The business process comes first and the database has to be modelled around that. OOP is definitely one of the best ways to model software based on the real world processes and has withstood the scrutiny by DBAs. I agree that RDBs and OOP cannot get along in peace and I'm overjoyed now we have something on the horizon that may end the need for RDBs and the evil DBAs that promote them.

    I will contribute heavily to this project and promote it after determining if it really does what it promises.

  76. Generic Prevayler by _wintermute · · Score: 2, Informative

    A little while ago, inspired by helpful members of the Prevayler mailing list I created a generic Prevayler system for object persistence in one of my current projects.

    Basic objects implement a 'Persistent' interface and can also be 'Containers' which are simply Persistent objects that contain other Persistent objects. Basic CRUD operations can then be performed with a couple of simple Prevayler transactions. The system maintains the object graph hierarchy, aloowing you to perform transactions and queries using a 'path' that maps through the various containers. The code below shows the creation of a new persistent object (myItem) and Adds this to an object at the path 'item/subitem' (so there is a Container object located at 'item' which Contains a another Container called 'subitem' - myItem will be placed in the 'subitem' Container. The code then executes a 'select' , which will return the 'subitem' Container, which we can then use to access our newly created object if we so desired. We could also execute select("item/subitem/myItem.id") to access directly the object we just created.

    Persistent myItem= new Persistent( id,. .. );
    AddPersistent addSub = new AddPersistent("item/subitem", myItem);
    Container container = store.selectItem("item/subitem");

    There is also a Prevayler Transaction to Update Persistent objects, using a similar path methodology. After we make changes to myItem, we can then use code like that below to execute the Update.

    UpdatePersistent update = new UpdatePersistent("item/subitem/myItem.id", myItem);

    Notes: the query language is obviously begging for XPath.

    As the whole system is generic, it means that after a select you have to cast to the correct type, which can be a pain. For example, you may have a Customer object which implements Container. The Container returned from a select will have to be explicitly cast to Customer. I guess you could write a typed wrapper.

    Generic typing also means that if you want a single Container to maintain more than one collection of Persistent or sub-Containers in a transactional manner, you may have to have the one actual Map behind the scenes, and have accessor methods that grab objects from this Map and cast to the correct type. I haven't quite worked this part out in much detail..

    I think I will publish the source code after I have done some refactoring and come up with a robust Exception mechanism. Although I must admit that Exceptions often do my head in. It seems that a lot of the time if your system breaks, you are simply fucked and there is often not a lot that you can do other than get out as gracefully as you can.

    http://www.info-architects.net/vapourized/

    --
    technoshamanic resistance within hyper-transgressive ontology
  77. Um.. yeah, right by tandr · · Score: 1

    I will consider this 2.0 Alpha when Slashdot will be running off it.

    Have a nice day.

  78. Re:Hurray! End to DBAs on the horizon! by Anonymous Coward · · Score: 0

    Whatchu talkin 'bout fewl? All da programmars and dbaz been outsourced to Bangalore. All dere's left is just me tha janitor and dey got me pullin cables and hookin up routers and shit too.
    Shheesh! Get with da timez already mon!

  79. Backups by yerricde · · Score: 0, Redundant

    By that logic you might as well assume that we will all have huge amounts of NV-RAM soon, and if that's true, wtf is the point of Prevayler again?

    If an app dies, its RAM will be reclaimed by the OS and erased. Backing up data to some other form of storage is useful even with non-volatile RAM for several reasons, one of them being the ability to take a backup off-site.

    --
    Will I retire or break 10K?
  80. PyPerSyst - Prevayler-like system for Python by golden+spud · · Score: 1

    Python users may be interested in PyPerSyst, a project that began as a Prevayler port to Python, but is quickly turning into a very "Pythonic" OODBMS with a full-featured object management system on top of the core transaction manager, which is also improving rapidly. The PyPerSyst Sourceforge page and the PyPerSyst Wiki are where to go to get the skinny. As far as having the whole database in memory, there seem to be plenty of situations and application domains where it is very feasible to do so and is thus not a concern.

  81. These folks don't know what a database IS by hey! · · Score: 4, Insightful

    I don't mean to say anything against their product, which as far as I know is the greatest object persistence scheme ever hatched.

    But they clearly don't know what a database actually is; they're confusing the issue with services that an RDBMS happens to perform as part of its job. It has always been possible to write procedural code that is faster than database queries because underneath a query is turned into a sequene of operations. When building a system to answer a single question, the system will always be faster without the database layer. Building a hash table or B-Tree to do a simple lookup simply can't be beat.

    People have lost sight of history. Years ago, we used to keep our data in indexed files, and guess what? They were faster than databases of the day at doing the tasks they were designed to do.

    However while databases are slower, in many cases much slower, than procedural code, they have an important property: they can be used to answer unanticipated questions acceptably quickly. How quickly is acceptably quickly? Well, if the database can come back with an answer faster than it takes a skilled programmer to come up with a special purpose program to answer the question, it has done its job. Compare this to their answer to the querying problem: write a java program. And that's a fine answer if having to answer an unanticipated question is a relatively rare event, which no doubt it is for many applications.

    This gets to what a database is: it is a collection of information that that is organized to make reuse simple and efficient. This is different from business object re-use, which is about re-using logic; this is about re-using facts. Relational databases are unequaled at this task because they are based on sets and mathematical operations that are closed on these sets. This allows both the user, but more importantly the system's optimizer, to create sequences of operations that meet the user's requests.

    These people may have a wonderful system for a lot of purposes, but they're really talking about a particular set of applications, for which their system might be better than storing object data in a database. Probably is, as far as I know. But really. No need for rollback because "transactions are instantaneous"? Well, they would be right if transactions really were instantaneous. HOwever, while their test case may be so fast they appear instantaneous, that's a long way from actually being instantaneous. In the real world bound by the laws of physics, transactions take finite time. Given enough objects to update, or high enough system load, or both, you will have to either (1) accept a possibility, albeit small, of inconsistent transactions being processed or (2) lock all the objects that might affected by a transaction, with attendent possibilties of deadlocking.

    In short, I wish them luck; it sounds like they are producing some interesting and useful stuff. However, it isn't a database or a replacement for a database.

    --
    Post may contain irony: discontinue use if experiencing mood swings, nausea or elevated blood pressure.
    1. Re:These folks don't know what a database IS by platypus · · Score: 1

      I don't mean to say anything against their product, which as far as I know is the greatest object persistence scheme ever hatched.

      It isn't. Please see the thread about the ZODB, also tagged to this story, to read about at least one other object database which doesn't have many of the shortcomings of their product.

    2. Re:These folks don't know what a database IS by Anonymous Coward · · Score: 0

      Update commands run one at time, so there is no deadlocking.

  82. Typical Java approach by davi_slashdot · · Score: 4, Interesting

    I really appreciate the idea of a RAM targeted object repository layer, but as often happens, the Java guys tend to present their solutions as panaceias to every single application domain that slightly ressembles the problems they are attacking. I am really curious about how Prevalence compares to more naive in-RAM data storage approaches. Despite raising attention to the large quantities of memory not used in high end servers (and to the project itself), I simply can't see the point to compare it with mysql.

    Furthermore, I can't avoid noticing the curious culture that has emerged with Java that you always have a single application/application instance for each machine. The dedicated server concept came to give reliability and CPU power, but WTF, do I really need a dedicated server to every application I run?

  83. Concept != implementation by yerricde · · Score: 1

    Though prevalence the concept works in any language that supports Serializable, the Prevayler(tm) brand implementation is for the Java(tm) platform.

    --
    Will I retire or break 10K?
  84. OO and RDBMS by Pedrito · · Score: 1

    I don't see how these are incompatible, particularly with languages with introspection, as someone else mentioned. Using a template based class generator that generates my classes from my database, and reflection in C#, I have a pretty seemless way of moving my classes to and from the database. And the really cool thing is I don't have to keep ALL THOSE OBJECTS IN MEMORY!

  85. Dunno if this link has been brought up before... by Kalzus · · Score: 2, Insightful

    Y'all may want to take a look at for some better (even better than the Prevayler website) information on the problem space that Prevayler is good for.

    It seems to me (in agreement with every commentor who has mentioned that this parent (Slashdot) article's title is misleading and inappropriate) that Prevayler's strength is in making it easy to persist *business objects*, not do away with the RDBMS entirely. If you've a strategy that involves tabular data as well as objects, and doesn't absolutely require a closer-than-reference coupling of the two, then Prevayler might help you out. Particularly if the business objects mutate very often during runtime.

    I can envision, for example, raw data stuck in normalized tables in an RDBMS, with the *roll-ups* stored in Prevayler objects persisted elsewise.

    --
    "The Devil does not know a lot because He's the Devil, He knows a lot because he's old." -- unknown
  86. Re:Dunno if this link has been brought up before.. by Kalzus · · Score: 2, Informative

    Nutz. Slash ate the link because I am a moron. The link is: [http://www-106.ibm.com/developerworks/library/wa- objprev/]; referenced by the original Slashdot article.

    --
    "The Devil does not know a lot because He's the Devil, He knows a lot because he's old." -- unknown
  87. Thank you! by jamesmartinluther · · Score: 1

    Having just started on a struts/ibatis project in which a relational database is used to populate objects, your explanation really provided me with some great theoretical background.

    I wish that I had the power to mod you up to a 6.

    - JML

  88. goatse a go-go by indole · · Score: 0, Offtopic

    thats all

    --
    (2,3-Benzopyrrole)
  89. Instantaneous Transactions? by brokeninside · · Score: 1

    Sounds like one big race condition waiting to happen to me. Even with the entire data base in RAM, transactions take time. If the number of transactions goes high enough, sooner or later a race condition will apply.

    1. Re:Instantaneous Transactions? by Anonymous Coward · · Score: 0

      Doesn't happen as write commands are executed one at a time.

    2. Re:Instantaneous Transactions? by julesh · · Score: 1

      Actually, not a race condition. I looked at the architecture a while ago, and all updates are pushed through a single thread (don't know if they've changed this at all). So rather than race conditions you get a bottleneck that won't scale with additional processors...

    3. Re:Instantaneous Transactions? by abe+ferlman · · Score: 1

      So any change to the database does the equivalent of locking the entire database rather than locking a single row or even table? This seems like where the biggest problem might lie.

      --
      microsoftword.mp3 - it doesn't care that they're not words...
    4. Re:Instantaneous Transactions? by julesh · · Score: 1

      Yep, that's the nail, and that there is its head.

  90. bad FAQ by robotbebop · · Score: 1

    the prevayler FAQ took me to goatse.cx. I'm not joking; i wish i was however. http://www.prevayler.org/wiki.jsp?topic=SystemPrev alence

    1. Re:bad FAQ by nobodyman · · Score: 1

      Yeah, same here. Looks like someone was able to add a redirect tag into their wiki. I'll have a fun time explaining that one to the proxy log monitors.

      Perhaps they aren't the braintrust that they think they are.

    2. Re:bad FAQ by ninejaguar · · Score: 1
      There are plenty of Open Source project websites that have been hacked (and source code compromised). No surprise that with attention comes mischief.

      = 9J =

  91. Oh nice by webperf · · Score: 1

    some kiddie modded the website so it goes to goatxx.cx

  92. Website Hijacked? by Angelwrath · · Score: 1

    I don't know about anyone else, but when I clicked on the link to:

    http://www.prevayler.org/wiki.jsp?topic=Starting Po ints

    I got the disgusting goatse.cx website. Is this a case of hijacking a website, or is Prevayler a hoax?

    I know websites can be stolen from others, thus we have the term "cyber squatters", is this a case of that?

  93. Use Open for Business and forget OOP by almax · · Score: 2, Informative

    I have been doing OOP for over a decade, but then I stumbled on Open for Business (http://www.ofbiz.org) which has an entity engine that basically throws out the OO model all together. At first I was offended, but as I thought about it, it makes sense - a bean class for each table just bloats things. Instead, OFBiz's entity engine handles the persistence and the service and event modules handle the business logic.

  94. Don't blame Java for bad programming by Anonymous Coward · · Score: 0

    nio allows memory mapped files and shared memory with native applications so anything can be written in Java. In proof there are other DB's in Java that don't take that approach.

  95. Silly Project by cartman · · Score: 5, Insightful

    The "Prevayler Team" has written a persistent HashMap with a redo log, using the command pattern. This is exceptionally trivial and is in no way comparable to a database. A database has things like: 4GL query language, referential integrity constraints, data integrity, queryable metadata, separation of logical and physical layers, data independence, declarative rather than imperative querying, dynamically assembled queries, and gazillions of other things. These are the real features that we mean when we say "database." These features are absolutely necessary. Prevayler includes none of them. It is an extremely trivial persistent HashMap, that's all.

    Thus, when the prevayler team says "throw away your database," I must assume one of two things. 1) They're trolling for publicity by saying outrageous and purposefully stupid things. Or 2) They are shockingly, mind-numbingly naive, and they don't know what a database is or what it does.

    The author of Prevayler wrote this about himself: "Carlos Eduardo Villela is a 19-year old Brazilian graduate in Information Systems... almost 8 years experience has made him a Java and Python enthusiast."

    Thus, I have to assume that the authors are mind-numbingly naive. Don't get me wrong, I'm sure the authors are very bright, and I know that some good insights that went into the implementation of prevayler. But let's not throw away our databases quite yet.

  96. Anything's better than MySQL by Anonymous Coward · · Score: 0

    I find just about anything to be a better solution than MySQL....

  97. Bubble Memory Wanted by Tablizer · · Score: 2, Interesting

    A good object oriented database, like GemStone (for Java or Smalltalk) allows the objects to remain "alive" while in storage.

    I have concluded that what OO affectionados really want is the concept of bubble memory. Bubble memory was being heavily researched in the late 80's and promised to create a kind of RAM that would keep memory even when the power was turned off. You only needed power to change state, not keep state.

    This is more or less what Prevayler-like tools seem to do: give one the illusion of bubble memory.

    Sure, we would all like bubble memory, but it seems that OO needs it more because it depends on behavior as the primary communications conduit between system/application parts, whereas relational approaches use data and meta-data for such communication. It is easier to recreate data messaging between boot cycles than behavior.

    I don't know what happened to bubble memory. It never seemed to take off like promised.

    1. Re:Bubble Memory Wanted by RevAaron · · Score: 1

      In a lot of ways, you are totally correct, but not quite.

      I've done work with both a couple different kinds of OODBs as well as SQL-based RDBMS. Most of the OODBs I've used simple keep your data persistent. What do they do beyond this? All of those Database-Manager-Systems things. If I just had bubble memory, the current state of the changes I made to the objects would always be persistent and up-to-date. That may be fine for some things, but if you get into a multi-user or even just a bigger database. A system like Prevayler or other OODBMs like GemStone/S or Magma (my object database of choice) doesn't just save and load your objects to disk in a transparent fashion- they also have transactions, commits/aborts, logs, the ability to roll-back the database to what it was N commits ago.

      Again, I can't say anything about Prevayler, not knowing anything about it, but Prevayler seems a bit more like simple bubble memory. That is, you have to keep your whole DB in RAM, which baffles me some. Why not write it to disk, or at least have that option? Anyway, most OODBs I've used are somewhere in between the simple persistence of Prevayler and a traditional relational database.

      If I were writing an application in a non-OO language, I personally still think I'd prefer using some transparent persistent storage system like bubble memory, but a lot of procedural languages would need a library to make searching your data/structs a little better. A lot of OO language, especially Smalltalk, has a really good group of Collection classes built-in, and the language has the semantics such that searching a Dictionary (map) or an OrderedCollection (vector) of elements is just as efficient as writing an SQL statement.

      In C, however, things are a lot dirtier, and you usually have to write a lot more code just to search your data. I suppose that's why SQL was born in the first place, but it's nothing that a well written library might not accomplish in languages that don't have a first-class collections system built-in.

      --

      Working toward a usable PDA environment in the spirit of Newton OS: Dynapad
    2. Re:Bubble Memory Wanted by Tablizer · · Score: 1

      but a lot of procedural languages would need a library to make searching your data/structs a little better. A lot of OO language, especially Smalltalk, has a really good group of Collection classes built-in, and the language has the semantics such that searching a Dictionary (map) or an OrderedCollection (vector) of elements is just as efficient as writing an SQL statement.

      I think what procedural languages need is a "nimble" relational database. Tools like dBase and Paradox had built-in semi-relational databases that were fast and lite. One just about never needed arrays or linked lists.

      But, SQL killed most of that because it has such a bloated grammar. SQL is not optimized for programming use in many ways. I wish relational language alternatives were pushed. SQL is the COBOL of relational languages imo.

  98. Found a serious bug already by cartman · · Score: 4, Insightful

    The somewhat naive authors of prevayler confidently announce the following on their website:

    "No one has yet found a bug in Prevayler in a Production release. Who will be the first? [bold in original text]."

    I already found a serious bug in the current production release. From the prevayler source:

    ObjectOutputStream oos = logStream();
    try {
    oos.writeObject(command);
    oos.reset();
    oos.flush();
    } catch (IOException iox) {

    ObjectOutputStream does not guarantee atomicity. If your command object is larger than the page size of your disk, the "transaction" will take at least two page writes. A software failure between those page writes will lead to "half a transaction" being committed and a subsequent corruption of data. Once data integrity is lost, it is often difficult or impossible to recover. Prevayler has nothing to handle this case. Thus, prevayler does not correctly implement ACID, because it doesn't guarantee atomicity (half a transaction can be committed), consistency (referential integrity would be destroyed in such a case), isolation (this failure wouldn't be isolated to a single transaction) or durability (the problem would only show up upon reloading).

    Finding this bug took very little searching. I am apparently the first person ever to find a bug in prevayler. Do I get a prize?

    1. Re:Found a serious bug already by Anonymous Coward · · Score: 0

      I suspect that the more serious case is when the previous command took 1/2 page and was successful (thus the user had a successful commit) and the current command takes 3/4 page and fails 1/4 of the way into it, possibly corrupting the page that the last command was stored on. This probably won't happen, but who knows what bits are being written when the lights go out? However, any application (including Oracle, DB2, etc) that is writing to disk has to contend with the same issues. On some file systems, it might be necessary to make sure that a page (or file allocation unit) is always fully used at flush time, but most file systems are probably fairly resilient to this type of trouble. Thus the lights go out, the current transaction does not succeed, and the last transaction is recovered on restart.

      So, did you find a bug? Possibly, but not yet demonstrated SFAICT.

    2. Re:Found a serious bug already by angel'o'sphere · · Score: 1

      Well,

      your post and the thread is old, but I answer anyway.

      Your analyzis is wrong. The code above you show is no "the transaction". The coe above is BEFORE the transaction, writing the "before image". In terms of prevayler, it writes the command object to disk.

      That means if the write crashes ... the transaction is completely lost. And the business objects are all unchanged. AFTER the write above succeedes, the comand is executed on the data base.

      The execution of the command is the transaction, not writing the command to disk, like you think.

      angel'o'sphere

      P.S., no did find nothing, so you gain nothing. However, prevayler has a serious bug .... If commands get serialiezed to a disk on a NFS server, likely the timestamps are not accurate. And when you are in development/debugging, serialized commands get read where the timestamp on the file is in the futur in relation to the server executing it. The persisence engine refuses to execute such commands, claiming they "can not be valid".

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    3. Re:Found a serious bug already by cartman · · Score: 1
      That means if the write crashes ... the transaction is completely lost. And the business objects are all unchanged.

      You're mistaken about this. If the system fails during a transaction that requires more than one page write to disk, the result could be an incomplete or corrupted command being written to the log. Java.io.ObjectInputStream does not guarantee transaction semantics, and neither does Prevayler running on top of it. From the java.io javadoc : "All exceptions are fatal to the InputStream and leave it in an indeterminate state; it is up to the caller to ignore or recover the stream state. ". Prevayler never recovers the stream state. Prevayler contains no logic to handle this case.

      The code above you show is no "the transaction". The coe above is BEFORE the transaction, writing the "before image".

      The code I show is of a command being written to the log. There is no logic to handle the case of failure during the writing of commands that are more than a single page in length. Thus, an incomplete transaction can be written to the log, and prevayler has no way of recovering in that case.

      The execution of the command is the transaction, not writing the command to disk, like you think.

      A transaction is always what is written to disk, otherwise you don't have a durable data store, and the 'D' component of "ACID" is not fulfilled. If there is any possibility that what you have on disk is inconsistent, and cannot be recovered, then you do not have a durable data store. Prevayler has a case where what is written to disk is inconsistent and cannot be recovered, because it has no logic to handle the case of failures in the middle of writing a multi-page command. Therefore, prevayler is not a durable data store, as was claimed.

      P.S., no did find nothing, so you gain nothing.

      I did find a bug, a serious one, and I deserve a prize!

    4. Re:Found a serious bug already by cartman · · Score: 1
      I suspect that the more serious case is when the previous command took 1/2 page and was successful (thus the user had a successful commit) and the current command takes 3/4 page and fails 1/4 of the way into it, possibly corrupting the page that the last command was stored on. This probably won't happen, but who knows what bits are being written when the lights go out? However, any application (including Oracle, DB2, etc) that is writing to disk has to contend with the same issues.

      Oracle & DB2 have logic to deal with the case of transactions that were half-written before system failure. Thus, Oracle & DB2 can recover no matter when the lights go out. Prevayler contains no logic to recover if a corrupted object is written to the stream because of a failure during the write. From the java.io javadoc: "All exceptions are fatal to the InputStream and leave it in an indeterminate state; it is up to the caller to ignore or recover the stream state." Prevayler has no capacity to do this. Java.io does not guarantee transaction semantics and neither does Prevayler that runs on top of it.

    5. Re:Found a serious bug already by angel'o'sphere · · Score: 1


      The code I show is of a command being written to the log. There is no logic to handle the case of failure during the writing of commands that are more than a single page in length. Thus, an incomplete transaction can be written to the log, and prevayler has no way of recovering in that case.


      The command does not get executed if the write to disk fails. So a failure *IS* handled. The transaction is aborted.

      The prevalent system is not a database system, thats why it is simpler and thats why ACID is implemented different and more easy. You still have all requirements of ACID fullfilled.

      If you can not see it at the code, then use the sample application, change the data directory to write to a "removeable media" and remove it during operation. Use your debugger if reading java code is to difficult.

      angel'o'sphere

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    6. Re:Found a serious bug already by cartman · · Score: 1
      The command does not get executed if the write to disk fails. So a failure *IS* handled. The transaction is aborted... You still have all requirements of ACID fullfilled.

      No, the failure is not handled. If the write fails in the middle of command serialization, then "junk data" is written to the end of the log. I have tried this by running Prevayler and simulating a failure during command serialization, and "junk data" is created. Prevayler never recovers this "junk data"; it remains in the log forever. Whether deserialization works correctly at that point is dependent on how the VM implements deserialization, but the correct behavior is not guaranteed (see the serialization spec from sun). Deserialization could just as easily throw an exception which Prevayler does not catch. If an Exception is thrown, then Prevayler's logs are corrupted and Prevayler becomes unable to start again.

      Thus, Prevayler is not a durable data store. I have verified that Prevayler doesn't clean up this "junk data" and that this leads to a serialization stream which is not guaranteed to work.

      There are other serious bugs in Prevayler as well. The most important is: prevayler never recovers or reuses any of its logs. After a snapshot, the prior logs are never used again and are unreachable. But they are simply forgotten by Prevayler, and are never "cleaned up." Thus, prevayler "leaks" disk space over time. The demo they provide leaks about 100 kilobytes a second, even after snapshots. This is not the same as using more disk space with new data. If you have "create" and "delete" commands and continually create and then delete the same object over and over again, then take a snapshot, the database will be empty, and the snapshot file will be very small, but there will be gigabytes of "garbage logs" that Prevayler has forgotten about but which are left lying around on your disk.

      Prevayler also leaks temporary snapshot files if a snapshot creation is interrupted, but this is rare enough that it's not critical.

      I've now found 3 bugs. I should get 3 prizes.

  99. Not ok for ongoing development by Anonymous Coward · · Score: 0

    The tool is cool at first sight.

    When the object model needs to be revamped (add new fields, references etc), the whole "big file" becomes irrelevant as the serialized objects are not compatible with the new definitions...

    After using it for a simple product of mine, I went back to RDMBs that knows what a technology-independent representation is (and real things, supported by vendors, not mySQL crap).

  100. Metaobjects? by Kakemann · · Score: 1

    Can anyone explain to me how on earth it is ACID compliant from the user's viewpoint?

    I think the real solution to the DB/OOP problem is somthing like this.
    That is - modify the object system itself to support transparent database access. Doing this, you'll be able to write the rest of the application pretty much without worrying about the database backend.

    -K

  101. Not neccessarily by Simon · · Score: 2, Interesting
    You are assuming that when Prevayler restarts it reapplys the "half transaction" and corrupts the data. What is more likely to happen is that Prevayler applies the transaction log, sees that the last transaction is incomplete/corrupt, and then stops. Result: consistent DB state. (Actually the state just before the software failure.)

    --
    Simon

    1. Re:Not neccessarily by cartman · · Score: 1
      What is more likely to happen is that Prevayler applies the transaction log, sees that the last transaction is incomplete/corrupt, and then stops. Result: consistent DB state.

      Prevayler doesn't appear to have any logic to handle this case. Java.io.ObjectInputStream doesn't have logic to handle this case either. Therefore, what would likely occur is: a failure of the application.

  102. If it's so good by bataras · · Score: 1

    If it's so good why are they using the dumb filesystem to persist their own wiki?

  103. Re:I LOVE TO EAT MY WIFE'S SHIT by Anonymous Coward · · Score: 0

    I concur. Eating your significant other's feces is very exciting and can bring you deep into a submissive state. You might want to introduce the subject of a FemDom relationship to your wife. I did this with my girlfriend and life has never been better. I've signed the slave contract with her and now she owns everything including me. Brown showers happen once a week and golden showers are nightly. There is nothing more satisfying than my girlfriend's sweet golden nectar in my mouth and on my face. For more info on the whole FemDom relationship angle of brown showers, visit this site. Elise Sutton discusses the topic quite nicely and allows for lots of approaches. This is the way that the world is shaping up. Women are more in charge every passing year and their superiority over men will eventually be the mainstream way. I can't tell you how much more sexual pleasure I get from orgasm denial and cuckolding. My girlfriend hasn't had sex with me in two months, but she fucks her new lover every week. Sometimes I am present, and other times she locks me in my cage in the basement leaving only an intercom on so that I can hear her moan with pleasure as she gets fucked. I know a lot of this probably sounds odd to most folks here, but this really is an awesome way of life. Check it out and comment folks!

  104. yes, it has sped up development, yes it's great. by Zeno+Davatz · · Score: 3, Informative

    I posted a news item some days ago about oddb.org (see also linuxmednews.org). The complete 'datastructure' of oddb.org is done with Madlaine - a prevayler solution as mnemonic. Yes it has sped up development, yes the search queries are delivered faster, yes we are very happy with this new technology. You can have a look at our source at download.ywesee.com/ruby/oddb.org. You can test online at http://www.oddb.org. We are using Madlaine also on other mission-critical projects and it also works great there.

  105. I don't need software to store objects in memory! by thenerd · · Score: 1

    So this is an OODBMS that doesn't allow me to query, that holds all objects in in memory.

    Right.

    And how is this different to just storing my objects in memory? In some kind of data structure, like I usually do? Ok, then it serializes them. This functionality is pointless.

    If I need lots of data to be persistent I want to use Oracle, SQL Server, SapDB, and maybe even MySQL so that other applications can see the data.

    Otherwise, then I can just hold it in memory. If I'm just holding it in memory, I don't need another product to do it.

    --
    The camels are coming. I'm in love.
  106. Incompatable Serial ID's by Anonymous Coward · · Score: 0

    I wonder what happens when you update your Java classes, and try to load the old serialized data from disk... incompatable serial ID version errors? All data lost?

    1. Re:Incompatable Serial ID's by Anonymous Coward · · Score: 0
      I would guess that you could parse it by loading the data/serialized objects into the old classes as part of the parsing technique, and have the new updated classes move the now live data into themselves. Then the outdated objects could be destroyed, and their classes removed. It's all in the initial design of your app. Keep in mind you wouldn't be doing this in production, as class changes occur in development/qa/maintenance stages.

      You could standardize the procedure as an interface.

  107. few thoughts by Pflipp · · Score: 1

    One could easily claim that while programming today is all OO, data storage is still left in the procedural era (in fact, there's indeed too much OO-Relational mapping to back this up).

    The biggest problem is of course to make an understandable and flexible solution. To be honest, at first sight, I don't understand sh*t of Prevayler, while other so-called OODB's I "know", never seemed to care much about (more or less) language-independent mapping; they just stored serialized objects. A product of my own just mapped some basic datatypes to an RDBMS (which works, BTW, just fine for data objects).

    I would welcome someone who would be able to answer these in only a few words:

    - Does Pv only store data objects, or also other program runtime objects (like with Smalltalk)?
    - Do they attempt language-independent storage?
    - Is the storage structure searchable/ readable?

    Thanks.

    --
    "We can confirm that Debian does *not* ship the version with the trojan horse. Our version predates it." [CA-2002-28]
  108. Ok, I'll bite... by DCowern · · Score: 2, Interesting

    Ok, I'll bite. I don't get it.

    I've developed several medium-sized projects using OO languages interfacing with a RDBMS. One used MSSQL, one used Oracle, and a couple used MySQL. (Just to be a bit more precise, by medium-sized I mean a few tens of thousand lines of code and up to 50 concurrent users per location to which the application is deployed.) I've never seen a "rough courtship with Relational database" or a problem with "OO-to-RDBMS complexity" and I would not call developing OO applications that interface with SQL databases "tedious".

    Secondly, the incompatibilities can easily be addressed by creating a database connection class. The SQL implementation aren't so different that you can't pass the implementation name (i.e. MSSQL, ORA, MYSQL, etc.) to the constructor or add some #ifdefs (or the equivalent) in appropriate places and pass the right implementation-specific SQL based on that. If you do it well enough, you can reuse this class across projects. At least SQL is somewhat standardized (haha, I know). By using Prevayler (which sounds like it's some 12 year old AOLer's screen name, btw), you're locked in to one vendor. What if, for example, I have a client who can't/won't run this software? There are enough SQL variants to make pretty much anyone happy with the platform.

    The poster talks about a lot of high-caliber hacks... if a developer understands the purpose of an RDBMS was supposed to do, they wouldn't need to resort to "hacks" (I was expecting an example or some useful supporting information from the poster's link... unfortunately, I was sadly mistaken). An RDBMS is a way of storing and retrieving data. The implementation of the RDBMS should have no impact on the design of a program. If it makes an OO-zealot feel warm and fuzzy, they can just think of the entire RDBMS as a giant object sitting off in never-ever land with connect and query methods (at the most basic level at least).

    Lastly, I see a lot of hot air on the Prevayler website. Things talking about freedom from query languages, support of any algorith, etc. They don't seem to have a lot of information on these statement. They don't say exactly how data is stored. They seem to claim that Prevayler will organize your data in the most optimal fashion since they seem to think DBAs are evil people who, for no reason whatsoever, come up with wicked database designs intended to make developers miserable. They don't say exactly how they store data. These kind of omissions scare me. I don't trust projects just because theyre open source. (Note: If this information is available, it wasn't obvious. Even if these guys are the most awesome OO developers ever, they suck at presenting information).

    What is the big deal here? Seriously... I'm just not seeing the problem.

    I'm sorry if something like this has been posted before but I really didn't see anything covering these questions. Also, if it sounds like I'm a bit mean in this post, it's because as I was writing the post, I tried to answer my own questions through the Prevayler website but was unable to find any useful information -- in fact, I ended up with more unanswered questions than I started with. In short, zealotry combined with lack of information makes me an unhappy camper.

    1. Re:Ok, I'll bite... by julesh · · Score: 2, Interesting

      I think you've probably missed the more relevant parts of their site. It is a bit of a mess.

      Prevayler isn't a database server. Its an object storage library. So its not a matter of a client not wanting to run it; you link it to your own app and manage your own data with it. The only reason a client couldn't run it would be (a) no support for Java (unlikely) or (b) not enough RAM (which is the big problem).

      Prevayler stores all of your objects in RAM while you're working on them, and at the same time maintains an (apparently) reliable disk backup. To do this, it uses the standard Java object serialization API. To maintain consistency, it requires you to perform all updates through serializable command objects. So you end up with two files; one is a snapshot of all the objects in your store at some point in time, the other is a log of all the commands executed since that point in time.

      The code is, apparently, only 335 lines long. It is very easy to understand. There can be no vendor lockin because of this simplicity. I looked at the version 1 code about a year ago and probably remember enough about it that I could write a program to load in the stored objects.

      The "organising data in a more optimal fashion" is probably simply a reference to the fact that you can use it with any serialisable Java objects, so you can have references between objects that don't need index lookups, use most of the standard Java classes to organise your data (so you're not constrained to tree indices, you can use hashtables or arrays or whatever you think most appropriate), stuff like that. Basically, because it does less for you, you have more choice.

  109. Whoa, AMD must love these guys by Anonymous Coward · · Score: 0

    Finally a non-scientific application that will actually make use of the totally insane and useless amounts of mem their x86-64 thing lets you address.

  110. Objections by Kj0n · · Score: 1

    The idea of Prevayler is good, but it lacks a few things:

    * How about really large databases? I know people who administer databases of 300 GB. There is no way you get that much RAM in a machine. Besides, I wonder how long the nightly snapshot would take.

    * How do you implement clustering, where different machines access the same data. This could be implemented using synchronisation protocols, but that would reduce the speed dramatically.

  111. ORDBMS and LDAP? by g_braad · · Score: 1

    Why not use the in between solution, like ORDBMS. PostgreSQL has a very fine implementation if this.

    eg. A Person { } and a User { extends Person}.

    I just started using Directories again and I don't know that much about it's internals. Isn't OpenLDAP based on the BerkeleyDB libs and isn't LDAP somewhat object-oriented?

    drawback for LDAP is that write calls are not very fast. A directory is better for few writes and many reads).

    --
    F/OSS & IT Consultant
  112. This is not really new by heironymouscoward · · Score: 1

    In 1992, we were supporting a large COBOL application that was trying to run on an undersized mini (some kind of nasty French system, a BULL/TDS) that tried to immitate an IBM mainframe but with pathetically little memory.

    The RDBMS was Oracle, which ran reasonably well because it had its own CPU, and about five times more RAM than the main system.

    But the applications had lots of problems getting their data into memory.

    So, we made a memory-to-disk serialization system, in COBOL with a few assembler subroutines. It was quite fun: swapping large amounts of data into large sequential files addressed by record number. It was also incredibly robust, mainly because it was so simple.

    It was also at least 3000 times faster than the Oracle database, and I'd reckon (since we never tested this) probably around 50,000 to 100,000 times faster. That's easy when you are basically acting as a memory swap system: 95% of your accesses are from live memory.

    But... but... this is _not_ a database product and it is an unfair and unwise comparison.

    A database holds long-term persistent data and (most vitally) makes this available to multiple readers and writers through various non-trivial locking mechanisms. Additionally, a relational database provides non-trivial mechanisms for indexing and searching and linking this data together.

    Lastly, and so very, very importantly, a database is independent from the application programming language. I am 100% sure I could read that same Oracle database today, in C, PHP, Perl, Java, or even COBOL if I could find a compiler.

    Separating the database from your application implementation is such a fundamental design principle for serious application development (along with separation of the UI) that this concept, however fast and neat, is something I'd reject out of hand for anything our company made.

    --
    Ceci n'est pas une signature
  113. Late Post by I8TheWorm · · Score: 1

    Call me a troll, but I have a huge problem with the problems associated with OO's rough courtship with Relational databases comment. I've worked with OO and RDBMS professionally for the last 12 years, and have never had problems with a rough courtship. Anyone care to elaborate?

    --
    Saying Android is a family of phones is akin to saying Linux is a family of PCs.
    1. Re:Late Post by cant_get_a_good_nick · · Score: 1

      Overhype. This is a product, and they need a selling point. People have been talking about object databases for years, how they'll crush those silly RDBMS like so many ants. But silly us, we're still hacking away at Oracle, DB/2, Sybase, and MS SQL server. I think the issue there are so many wrappers going from objects to RDBMS that it complicates the view. They don't mention that there generally are wrappers going from objects to OODBMS as well, and RDBMS are generally faster.

    2. Re:Late Post by BigGerman · · Score: 1
      What they mean is the fundamental problem of mapping the OO way of thinking to RDB way of thinking.
      for example, in "objects" you have Customer object which may hold collection of Orders so you can have nice way of working with it: myCustomer.getOrders().iterator() and so on.
      In reality that Customer and those Orders got to be stored somewhere so the questions arise: when you read customer from some storage (customer table?) do you also need to read all of his Orders and populate collection? Or just read order IDs and fill them as they needed (lazy initialization)? What happens if one of the orders is changed externally after you already associated it with your customer object? What if you have a nice deep Object hierarachy and you read top most object, are you going to drag the entire object graph in memory?

      What about the queries: objects enforce looking at the data along fixed paths, like customers to orders not the other way around. It is very common and unfortunate that in real life business people want to query data in new and elaborate ways - "find customers who placed orders on widget23 and where on average more than 60 days late in paying their invoices".

      There are tons of issues like that and there is no easy way to handle it.

      I personally believe that this problem is due for a major breakthrough. many people are working on the frameworks, eventually one of them will rule.

  114. Prevayler's REAL problems by Anonymous Coward · · Score: 1, Insightful

    Oh come on. You're making the same mistake as 90% of the Slashdotters: you judge something without even having looked at it.

    Prevayler 1.0 contains something like 8 classes with 400 lines of code. That's a dimension where it's still possible to code without errors if you are really really careful and test a lot. That's one of the main ideas behind Prevayler: Get rid of the enormous complexity of a full-blown database system.

    Most of the complaints about Prevayler are nonsense. It is neither vaporware, an "amateur" project (whatever that is) nor unreliable or unusable.

    I can tell, I have written a large web application with Prevayler, and it has been serving thousands of users 24/7 for more than a yer now.

    Prevayler does have its own share of problems of course. In particular, there are three that actually hurt:

    -There is no direct way to browse or manipulate the database. Everything must be done through Java code that is part of the application itself. You can also see this as an advantage though: Think about data integrity.

    -Schema evolution is a pain. Since Prevayler relies on standard Java serialization, you have to live with Java's schema evolution mechanisms. Which really suck.

    -Java lacks meta-programming facilities, so you end up writing the same code over and over again for simple things like a table with 10 different string fields (getter/setter methods etc). On the other hand, the complex parts that usually force you to write near-unreadable, slow SQL statements tend to become very easy and efficient.

    Regards,
    -Stefan Reich (www.drjava.de)

    1. Re:Prevayler's REAL problems by Anonymous Coward · · Score: 0
      Hey, I never judged anything. I was merely being humourous while pointing out something that could be a warning bell.

      I haven't used it, I don't intend to, and I won't say it's good or bad.

      -pVoid

  115. MySql *does* scale from disk to RAM storage by tartley · · Score: 1

    Wrong about MySql failing to gracefully scale to RAM storage, btw:

    MySql polymorphically implements several different types of table, all conforming to the same interface. One of those implementations (HEAP tables) is designed to store data entirely in memory:

    1. Re:MySql *does* scale from disk to RAM storage by Xeger · · Score: 1

      If the Prevayler benchmarkers were using a MySQL database whose tables were all forced to use the HEAP implementation, then I'd say the benchmark is valid and Prevayler really IS 3,000 times faster than MySQL.

      However, I strongly doubt this is the case. I'm assuming the benchmarkers were allowing MySQL to automatically select the table type, and using a RAM disk as the location of MySQL's database files. In that case, MySQL was using a disk-optimized table structure even though its backing store was in memory.

  116. The hierarchical object file system by master_p · · Score: 1

    I have been talking about this a long time now. Unfortunately, no one listens. Never mind, I will keep repeating it for as long as it takes for people to understand:

    We need to ditch our RDBMS/filesystems whatever. We need to replace all those with the Hierarchical Object File System. The system must store information into objects, and each object could be a container of other objects. Objects would be persistent. Each object should be managed by code handled automatically by the operating system, loaded on demand, and run either in the same process, different process or remote site. Its state would be automatically handled by the O/S, ala Prevayler. The programming language to back up this mechanism would be component/object-oriented and would run either statically compiled, dynamically compiled or interpreted as a script.

    The Prevayler system is getting close to it, especially regarding the persistence mechanism. The next step is to apply it all over the O/S. Remember, that we humans use information, not binary data.

  117. alternatively, use MySql HEAP tables by tartley · · Score: 3, Informative

    If you're tempted by the RAM-based performance of this, but you don't want to give up on all the good things a RDBMS offers, check out MySQL HEAP tables - they are a polymorphous implementation of MySql's tables that are designed to be stored in memory.

    1. Re:alternatively, use MySql HEAP tables by Anonymous Coward · · Score: 0

      Only InnoDB and BDB tables support transactions. Using any of the other types is insane.

  118. No rollbacks? No thank you! by Anonymous Coward · · Score: 0

    From the site:
    "Rollback Is Needless"

    What if an error occurs and the program needs to revert to a sane, consistent state? This is why I need rollbacks, not for contention resolution.

  119. Re:I LOVE TO EAT MY WIFE'S SHIT by Trolling4Dollars · · Score: 0, Troll

    All I can say is "EWWWWWWW!!!!"

  120. .Net Version.... by al701 · · Score: 1

    http://bbooprevalence.sourceforge.net/ I have been playing around with this one for a while now. It definatly holds promise with certain types of applications. Recently the sites we (company) have been building do not allow for such an architecture and we really needed to SQL Server. Otherwise, I wait for the day to use this in an architecture. It is blindingly fast and pretty easy to code against. If the XPATH queries ever work fully this would be amazing product.

  121. Who rated this wannabe coder (4, Interesting) ??!? by Anonymous Coward · · Score: 0

    Better shut up or port anonymously next time you write such nonsense

  122. My company is using it by nicestepauthor · · Score: 2, Interesting

    I would tend to agree that the website oversells Prevayler, but it does get your attention. I used Prevayler in a project for work where we wanted to distribute a decision support system using Java Web Start. The system downloads data from a central server and works with it offline, producing reports and charts. It is meant for laptop users who will not always be connected to a network.

    Without Prevayler we would have had to install a DBMS on each client machine. With Prevayler we were able to avoid that and create a fully cross-platform system in 100% Java, entirely deployed through Java Web Start.

    Since this project we have used Prevayler on other systems where the amount of data involved did not justify buying an Oracle license. We have even used it on the server in a few cases.

    Prevayler will never replace Oracle here or anywhere else, but it IS useful and well worth checking out.

  123. Skip this story by shibboleth · · Score: 1

    Save your time. I wasted two hours on their site w/o finding any serious answer to how they allow simultaneous processes to write to shared information (without lost-update-types of problems), so that's probably all one needs to know about Prevayler. They may have something good to use in certain situations but any project "documented" with over-the-top hype substituting for data and serious info is not being run in a trustworthy fashion.

    --
    "Be thankful you are not my student. You would not get a high grade for such a design :-)" - Minix pro
  124. Ideal for prototyping by DukeyToo · · Score: 1

    I evaluated prevaylor a few weeks back, to see if it was a fit for a current project. It was not. But as soon as I find a project for which it fits, I will definitely give it a go.

    As I see it, prevaylor is good for:
    * small single pc system, or web based system
    * no need for external queries
    * system that stays static once developed (because it is very hard to evolve a prevaylor system).

    It would also be great for prototyping, because that usually meets all 3 criteria.

    Incidentally, there is a .NET version, which is the one I would be using.

    --
    Most writers regard truth as their most valuable possession, and therefore are most economical in its use - Mark Twain
    1. Re:Ideal for prototyping by ninejaguar · · Score: 1
      I agree with your statements. The system appears to be perfect for replacing FoxPro, Access, dBase, or FileMaker type databases with a high-speed web-based application. Good project for OOP newcomers.

      When the more advanced RAM tech comes out, the only limiting factor will be "evolving" a Prevayler system. I wouldn't be surprised if the appropriate framework gets developed for it (Aspect Oriented Programming?).

      = 9J =

  125. Here we go again. by MagicMerlin · · Score: 1

    Every once in a while, a post of this nature appears on Slashdot. I haven't like at the Prevayler project recently, but as I understand it, it is more of a supped up object streamer than a database. These projects and the ideas that drive them are fueled by college students who overdosed on OO theory in college and try to fit information into their carefully defined view. XML has similar issues. OO streaming and XML have real applications, but IMO are absolutely no threat to 'Relational' Databases in the business world. While OO is a useful and interesting branch of programming, its application is orthogonal to database principles and information storage. True and correct information storage is based on logic, not on efficient language bindings. Since stored data is really just information, or more technically, a sum of all constraints, it can describe anything, including 'objects'.

    This is nothing new. In Microsoft's .net platform, I can use the built in serializers to stream objects to XML with very little programming. With some XSLT and some more programming, a general approach could be used with some features (i.e. querying) of a crude DBMS. While the performance can be stellar for writing and reading (Microsoft's XML serializer can a achieve 10 mb/sec output on cheap hardware), concurrency is a nightmare and scalability is worse. While this seems attractive to OO programmers who are put off by brokering objects in and out of a non OO storage, any type of useful data mining with this approach is realistically impossible. Even with infinite computer resources, the weakly defined logical model of serialized objects contrasts unfavorably to the SQL model (and SQL contrasts unfavorably to the relational model, but I'm nitpicking!).

    Imagine database objects serialized to XML and stored in Postgres as blob objects (but without mvcc and atomicity) and you have something similar to Prevayler. Obviously, since you cant make a useful index out of a blob object, ad hoc queries are impossible unless you introduce a 'meta parsing' stage for indexing, relating (such as it is) and performance optimization -- now destroying the 'generalness' of the storage. In SQL, all you have to do is type in 'create index', what sane db administrator wants to give that up?

    Generally, Postgres is more suitable in business environment in almost every way, but the common misunderstandings about databases (urban myths?) in the IT industry are so widespread that newcomers to the field must have terrible trouble getting correct information.

    Regards,
    Merlin

  126. Make it easy, but don't replace anything by PetoskeyGuy · · Score: 1

    I'm sure the technology is good, but for crying out loud, mainframes are still around 40 years later. RDBMSes are going nowhere for the next 20+years until true AI comes around.

    Think of it this way, we still use files to store data and there are lots of low level file operations we can perform, but RDBMS encapsulates all that so we can say "create table" and "select * from table" and not have to muck around with accessing the files ourselves, just get the data.

    In the same way, what this project should do is automatically USE an RDBMS on the backend to store all those transactions and retrieve updates. If there was some option to keep all objects constantly up to date with the database I would love it. No translating from objects to DB because it would all be done for me. No click here to save, because it would be done as things change.

    I'm sure that's what future libraries will do for you. I think this would be a great application if we already had that new magnetic memory that is supposed to replace hard drives, but for right now, if I have a power failure I don't want to suddenly lose my whole database.

    I wonder how this project would compare with a MySQL hash table.

  127. Re:yes, it has sped up development, yes it's great by Anonymous Coward · · Score: 0

    Thank you for a working example! I hadn't thought anyone would actually bother answering the article poster's questions. I'll check out the links.

  128. Transparent persistence is needed by presidenteloco · · Score: 2, Insightful

    We use prevayler and it's pretty good, but you still have to distort your Java code to accommodate the Command pattern to use it. I think the real solution is a well-designed new O-O programming language that provides fully transparent persistence via some kind of underlying object-relational db implementation.

    --

    Where are we going and why are we in a handbasket?
  129. Re:I don't need software to store objects in memor by Anonymous Coward · · Score: 0
    The biggest push right now in corporate IT is to link up all disparate legacy systems by using a BUS (TIBCO...etc).

    If you were starting fresh without disparate legacy applications, you would use this in a cluster and simply add functionality to it based on departmental needs. That way, everyone shares the data (which is exactly as fast as your CPU and RAM will allow without the Hard Drive lag). The more memory and cpu utilization you need, the more cheap Linux workstations you throw at the cluster.

    What you end up getting is an inexpensive supercomputer that can also load other applications not associated with the data in the original application.

    Or, as the author of the project has posted in his wiki, there's no reason why your objects can't feed other applications, or other applications be treated as input for your objects. Afterall, no application is an island. Input/output is required, it's simply up to you where it comes from and where it goes or copies to.

  130. Prevayler: can it work? by plaurila · · Score: 2, Interesting

    From my weblog:

    Could loading all your objects into memory, and keeping them there, possibly work? That's what the folks at www.prevayler.org think. Breakthroughs in memory technology, cheaper RAM, 64-bit computing, better JVMs -- all these instances of technological progress, we are told, ought to finally make it possible to keep all your domain objects in main memory. The advantages are obvious. Systems become simpler. The need for caches is all but eliminated. Performance can be enhanced dramatically as there is no longer need for expensive disk access or network communication with the database. No longer are you limited by the query language of your database; use whatever query mechanism that best suits your needs.
    Wonderful! But, does it work in practice?

    1. Cheaper RAM. While it is true that RAM has been getting cheaper and cheaper, the same is true of hard disks. A look at the web site of a nearby computer shop reveals that a 512MB RAM unit costs 84 euros; you can buy an 80GB hard disk suffering the same amount of monetary drain. It is not to be expected that this two-orders-of-magnitude difference would disappear anytime soon. Therefore, for large amounts of data, even if you could buy enough RAM, would you really like to?

    2. 64-bit computing and JVM support. Extensions like Intel Extended Server Memory Architecture aside, 32-bit computers can address only 4 gigabytes of data. In practice the number for an individual application is less, and for a Java application even more so. Java heaps on x86 platforms were restricted to approximately 1.5GB last I looked. This is not enough for many enterprise applications. It is not nice to be running at 1GB heap utilization, knowing that users are creating new objects all the time, fast...

    64-bit architectures get rid of the 4GB barrier thus carrying with them a promise of prevalence nirvana. Right now, though, all 64-bit systems are stratospherically expensive. Have you seen the prices of those Itanium 2 boxes? AMD promises to come to the rescue with x86-64, but the practical utilization of this architecture from Intel's chief rival in Java application is a little off, since there's not even a Java VM for x86-64 yet (though one has been promised to appear in 2004).

    3. Simplicity. I'd love getting rid of caches. Caches suck! And don't even get started on all that pesky O/R mapping stuff. Without a query language, though, the distinct possibility exists that the magic box full of promises will turn out to be half-empty. Writing queries in SQL is, well, convenient. If you have to manually construct hashtable-based indexes, then the value proposition of object prevalence diminishes. Fortunately, there are object query languages, though none of them seems to be widely accepted as a standard. However, there should be no obstacle in principle why such standardization couldn't take place.

    4. Performance. Queries from a hashtable-based index are fast. For updates the situation is different, as updates will have to be written to the command log; all in-memory indexes, too, will have to be updated. If such indices are not maintained, databases could in case of a huge data set turn out to be faster, even though they often have to access the disk to get to the data. The big performance advantage that I see coming from object prevalence is in the area of very complex, deeply-linked data structures: you can build them and still not worry, given the right combination of hashtables.

    Conclusion? If an application deals with lots of data, or if the amount of data grows fast or unpredictably, object prevalence won't be viable until 64-bit architectures establish themselves in the marketplace (which should take a couple more years). Regardless, you can look for subsets of data that could be kept in memory in their entirety. The more often that data is accessed, the more performance benefits will accumulate. For example, in a server-side business application, it might be possible to

  131. OBJECT PREVALENCE by The+Praetorian · · Score: 1

    Here is an interesting Q and A I ran into about Revalence

    http://www.advogato.org/article/398.html

    1. Re:OBJECT PREVALENCE by ninejaguar · · Score: 1
      It's a good one, and wish I had added it to the article. Kinda gives you the content of the wiki in one spot. I wish the product's author would change the Wiki into a more cohesive website.

      = 9J =

  132. One Problem by HiThere · · Score: 1

    The versions of Prevayler that I have made myself familiar with require that all data stored must reside in memory. I suppose that the data could be clumped into non-interacting sets, and those pulled in separately, but... well... I find the limitations unacceptable.

    That said, I was not able to determine whether or not this limitation still applied to the new version. The basic idea is excellent, but implementation is the key.

    (P.S.: If it's in Java, I wonder if it compiles with gcj. If so, then it may be quite useful to those with small enough databases, or even, assuming that they have fixed the all-or-none problem, to people with large databases.)

    --

    I think we've pushed this "anyone can grow up to be president" thing too far.
  133. Re:Ha Ha by Anonymous Coward · · Score: 0

    -1, Subject Troll

  134. Get the problem domain right by rkeene517 · · Score: 1
    Prevayler addresses a certain class of problem, the small application with a simple database. It does not address the same problem space that a relational database does.

    The problen space for prevayler happens to match several projects I am working on. They have the properties of a small database, single instance use, and load-all-and-flush-once-in-a-while. This matches pretty well most small web applications. If you look at .NET and C# the approach there is to load the entire database into memory, and flush the changes. This was chosen by the Evil Empire because it meets a certain need and class of web site application.

    I think that the rhetoric on the prevayler web site is a bit extreme, and may not be in the best interest of the project. The comments on slashdot are much more extreme, and rather insulting and poorly thought out.

    I, for one, am glad that Slashdot carried the article, and am thankfull for the team that wrote prevayler for making it open source. It is a good solution for a certain type of application.

    Prevayler is a horrible solution for some other types of applications where an RDBMS is appropriate. If you need the advanced capabilities of SQL than by no means should you use Prevayler.

    Once 64 bit Java VMs become common, then Prevayler will become appropriate for a broader class of application. Even then there will be some applications that need the features of a RDBMS. Maybe at that time Prevayler will gain more features that RDBMS's have, and probably be wrecked by code bloat. Lets just hope that Prevayler keeps it's simplicity and keeps targeting the application space it was intended for and does not try to compete with RDBMS.

    So, why all the harsh comments? Perhaps the people making the harsh comments simply never created anything usefull in their lives, and are attempting to agrandise them selves at the expense of others. My advice to them? "Get tharapy". Or better yet, the best tharapy would be to actualy work on an open source project and see just how difficult it is.

    --
    Inside every complex program is a simple solution trying to get out.
    1. Re:Get the problem domain right by Anonymous Coward · · Score: 0
      Excellent analysis. After reading some of "documentation" on that horrible wiki (the html file and readme files with the source were better), I've come to some conclusions myself, and would like to add a few things.

      Assuming that all their claims are true, there really are only two major reasons in deciding not to use Prevayler. When you can't fit all your data into memory (as your suggestion states: small projects), and if you're looking to easily change your object "schema" in Java on the fly because of poor user requirements or lousy functional specifications.

      To address the first, I've observed that the lower profile smaller inexpensive projects at large corporations outnumber the higher profiled medium-to-large expensive projects. The smaller projects also use smaller databases and quite a few of them to this day are not even client/server, let alone web-based (higher expense due to several factors like requiring multiple servers such as web and database - although, some companies reduce this cost by forcing departments to share servers).

      What I'm suggesting here is that you could use Prevayler wherever a FoxPro (.dbf), Access (.mdb) or FileMaker-Pro based application was being considered by a department. It's unlikely you'd see stable .dbf, .mdb or even .pst files getting larger than 1 GB without permament corruption (or if used frequently, without hourly indexing). So, if the .dbf files are only hundreds of megabytes in size because the department may not simply generate that much data, Prevayler would be a good choice to load that data into memory.

      Now, because Prevayler doesn't require the extra cost of a separate database server, you'd only need to have a low-cost webserver, and the departmental workstations don't require anything additional installed (like Foxpro, VB, or Access runtimes). The department saves money in the long run for not having to pay for tech visits each time VB, foxpro, or access crashes and causes data corruption and for other related reasons. Also, the webserver would be low-cost for the simple reason that it wouldn't need to use very expensive RAID, SCSI disk-arrays, or SANS. You'd only need an IDE drive approximately 5 Gigabytes for every Gigabyte of RAM your using. So 1 GB RAM, 5 GB HD. Now, we know that HD are ridiculously cheap, so why not a 80 GB drive just because it probably comes with the server in first place?

      As for the schema change problems, there's a couple of suggestions: 1) Use a Business Analyst and hold his feet to the fire for getting the requirements right the first time around (or at least minimize the impact of change on how the clients actually do their business). 2) If you can't afford a Business Analyst, then study XP-Programming and you'll see that iteration, refactoring, and testing with the user/domain-expert will minimize the need to do ad-hoc schema changes later on in the project's development. Admittedly, user requests for ad-hoc queries appear to be a part of the best designed system's life. So, in a worst-case scenario, you could always use any number of Java classes out there to serialize the data into a .dbf and give the users Crystal Reports or some Open Source variant to query it. Then, the queries that are used the most, could be migrated into version 1.1 of the Java application as "schema" changes.

      Multiple small projects that replace Foxpro/VB/Access specs would allow a Java newbie to cut his teeth and get up to speed on OOP development.

      For answers to other questions, I've also looked at this link:

      = 9J =

  135. Scalability by Dr+Rick · · Score: 1

    The web site is breathtaking in how it compares apples and oranges and then draws conclusions from that. I spent a lot of time in the OODBMS world and we could always come up with a benchmark that was arbitrarily faster than an RDBMS and there were many applications where this was proved out. But we would never say that OODBMS was going to replace RDBMS because we knew that there were plenty of applications where RDBMS would kick OODBMS butt. What these people seem to miss is that you need to use the right tool for the right task - some things work quite well is in-memory databases and some things suck wind big time; the same applies for all other database technologies.

    --

    Dr. Rick
    - "It's such a fine line between clever and stupid" (Nigel Tufnel)
    - Zort! (Pinky)
  136. OO is old news by Anonymous Coward · · Score: 0

    Why should I switch models of data storage to match a dying architectural style? The future is in SOA. Forget about this day-late-and-a-dollar-short product.

    1. Re:OO is old news by ninejaguar · · Score: 1
      As it turns out, OO isn't the only thing that's old news; so is Service Oriented Architecture. It's at least a decade old.

      In the "old" days, this was called RPC. Currently, in Java, you might recognize is as RMI. The recent buzzword for it is Web-Services. The new incarnation simply adds a long-missed feature: programming language independence. Java's RMI had already introduced platform independence.

      = 9J =

  137. Cult Like? by CHaN_316 · · Score: 1

    "With Prevalence we are finally free to create true object servers and use objects the way they were intended all along.

    We are able to use any algorithm, data-structure and query language we please. We are no longer constrained to the ones provided by database and application servers which must run on disk data-blocks.

    We believe the whole OO community is finally free to recover from the atrophy caused by database and application server restraints. We no longer have to distort and maim our object models to satisfy their limitations.

    We no longer have DBAs imposing us database layout restrictions. We have freed them to do something more useful.

    We have set fire to the table-models on our walls. We have deleted our database creation scripts. We no longer have to keep them updated.

    We no longer have to license, install, configure and maintain a database and application server every single time we want to develop, demonstrate or deploy our systems for any of our clients. Give us a Java VM and we are good to go."
    -- http://www.prevayler.org/

    All you need to add is "Now let us partake the mystical kool-aid, and we shall welcome our new Object-Orientated Overlords.", and you've got an official Jim Jones' approved cult with tax-exemption and fashionable robes.

    I'm sure Heaven's Gate had similar phrases to win converts.

    --
    "There is no spoon." - The Matrix
    1. Re:Cult Like? by ninejaguar · · Score: 1
      Cults in themselves aren't bad. It's only when they ignore facts that conflict with their dogma that they become dangerous or ridiculous.

      I wouldn't characterize this group as cultists as they don't ignore the facts, but appear to welcome them. Most projects tend to develop some degree of "core" fans as the base who are enthusiastic about their "cause" (i.e., Linux, Gnome, Apache). What's admirable about this project is that they take every challenge head-on and have successfully answered the questions posed to them at their wiki and other sites as honestly as I've seen any other group. If they don't have the answers, they admit it.

      I see Prevayler as a bit ahead of its time in the sense of hardware requirements (though that may change in a few short years). Also, it would benefit greatly if it gained a flexible schema framework; maybe by incorporating suggestions from Aspect Oriented Programming?

      On the other hand, I don't see why this couldn't be used to replace any file-based database app such as FoxPro, Access, Paradox, Clipper, FileMaker or dBase. 1 GB .dbf or .mdb files are rare, and often easily corrupted. A web-based Prevayler application would be a boon to this departmental application niche.

      = 9J =

  138. DBD::SQLite (was: Re:SQLite) by Pan+T.+Hose · · Score: 1

    SQLite is tiny, fast and ACID compliant. SQLite is a public domain embedded SQL database library. It is similar to BDB, but provides a complete SQL database.

    Let us not forget about DBD::SQLite [cpan.org] &mdash; a DBI [cpan.org] (Perl [perl.org] Database Interface) driver which, not being a driver per se, includes a *full* SQLite distribution, so when one needs to use SQLite in a Perl program, one is only perl -W -MCPAN '-einstall"DBD::SQLite"' away from $dbh=DBI->connect(q(dbi:SQLite:dbname=dbfile)); which is truely amazing.

    --
    Sincerely,
    Pan Tarhei Hosé, PhD.
    "Homo sum et cogito ergo odi profanum vulgus et libido."