Discussions

News: Cayenne ORM 1.0 Released

  1. Cayenne ORM 1.0 Released (6 messages)

    Cayenne ORM 1.0 was recently released. Cayenne was first introduced on TSS when it was still in Beta. Now Cayenne team is proud to announce the "gold" 1.0 version. Cayenne is a comprehensive OpenSource Object Relational Mapping framework. CayenneModeler GUI mapping tool sets it aside from comparable ORM solutions. Cayenne 1.0 is the production quality release and features the following:

    Environment:

      - Works on all Java-compatible development and deployment platforms: Mac OS X, Linux, Solaris, Windows.
      - Can be deployed with JDK 1.3 and higher. Development environment supports JDK 1.4 and higher.
      - Easy to deploy in various Java environments. Special support for deployment with web applications.
      - Supports all JDBC-compatible databases. Special adapters for Oracle, Sybase, DB2, MySQL, PostgreSQL, FireBird, HSQLDB. Generic adapter for others.

    Productivity:

      - Contains platform-independent GUI tool for Object-Relational Mapping.
      - Imports/Exports database schema.
      - Generates Java classes (both from UI and Ant tasks)

    Design Features:

      - Mapping of object properties as attributes and relationships (including many-to-many).
      - Object caching and lazy retrieval of relationships; prefetching.
      - Supports BLOB and CLOB; supports stored procedures.
      - User sessions keep their own isolated view of data changes.
      - Mappings and queries are database independent; porting to a different database is as easy as switching the adapter.
      - Supports multiple databases in one application, creating a single "virtual" data source.
      - Built-in connection pooling; supports DataSources provided via JNDI.

    It can be downloaded from http://objectstyle.org/cayenne/

    Threaded Messages (6)

  2. Cayenne ORM 1.0 Released[ Go to top ]

    I'd like to thank the Cayenne development team for all their hard work. We successfully released our cayenne 1.0 version of the National Hockey League web site last week (nhl.com). Great work! Keep it coming!
  3. Cayenne Feature Questions:[ Go to top ]

    I have a few questions about how Cayenne works:

    1) Does Cayenne have it's own query language? I suppose so, since it's
    database independent.

    2) How easy is it to do your own sql if you need to?

    3) Are the mapping files compatible with any of the other ORM's? Hibernate, Object Relational Bridge, CocoBase etc?
  4. Re: Cayenne Feature Questions[ Go to top ]

    Hi Jakob,

    1. Query Language:

    Cayenne queries are based on two Java packages, org.objectstyle.cayenne.query and org.objectstyle.cayenne.exp. To select a list of objects from a database, you would instantiate a SelectQuery object, and set its optional parameters: qualifier, orderings, etc. Queries are executed via a DataContext - an object for communicating with the database from the object layer.

    2. Raw SQL:

    one of the queries in the "query" package is SqlSelectQuery. You can use arbitrary SQL with it, and get back a list of Map objects (that can be later converted to the "real" objects too). There is also a SqlModifyQuery that allows running arbitrary DML statements.

    3. Cayenne Mapping Format:

    Cayenne mapping format is specific to Cayenne. It is stored in XML (duh!). Since conceptually most O/R mappers are close to each other, "bridging the gap" between the mapping is usually fairly simple. E.g. at the moment Cayenne implements an import function for Apple's EOF ORM framework. From some of the earlier discussions on our mailing lists, one may expect the contributions of converters from/to other ORM.


    Cheers,
    Andrus
  5. Thanks :-)[ Go to top ]

    Thanks Andrus,

    The reason I'm asking is that

    a) I have been looking at some different ORM tools lately, but found them hiding the database a little too much. Also, I couldn't get the config to work on one of them. I haven't heard of Cayenne until today :-/


    b) ... so I started doing my own little ORM tool, Mr. Persister, which
     - only uses SQL as a query language.
     - only works on Connection, Statement, PreparedStatement or String
       instances containing SQL.
     - doesn't need any manual object-database mapping. The api "guesses" the
       mapping iself (works quite allright). You can of course override the
       guessed mappings, or create a mapping from scratch yourself.

    That means that if you can create a connection to your database, you can use Mr. Persister. Nothing else is needed.

    That of course means no database independence, but that's okay for many applications.

    Now, I might not have started that little project, had I known about Cayenne :-) So I am of course interested in knowing if I should stop or continue, and if I continue, learn something about how other mapping tools work, and if they are easy to use etc.
  6. Exchanging Experiences...??[ Go to top ]

    ... maybe all of us ORM tool writers should "meet" one day, and exchange experiences, and maybe align the different products a bit :-)
  7. Re: Exchanging Experiences...??[ Go to top ]

    I am sure there is enough interest in the Java community to have a full scale conference on ORM. Public perception has gone the long way. Two years ago when we started Cayenne, you had to prove to virtually everybody thing like

     - ORM is not a replacement of JDBC,
     - ORM is not slow compared to handcrafted JDBC access with DAO,
     - the fact that Sun recommends EJB for persistcence, doesn't mean that you should actually follow this advise,
     - etc...

    While the conference idea is up to the bigger guys, on my part I can only suggest an ORM beer party for those in US, NYC area :-).

    Andrus