greenDAO 3 released

We are happy to announce greenDAO Version 3 today. Since its initial release 5 years ago, greenDAO has always been the fastest ORM for Android. It was also the first ORM to apply code generation for maximum performance. With greenDAO 3, we made code generation much more convenient: by adopting entity annotations you can drop the generator project. In its place comes the all new Gradle plugin, which automatically triggers code generation at build time. Like that, you can simply use greenDAO 3 annotations on your entities:

In summary, now you can have both: best in class performance and convenience. We compiled a greenDAO 3 documentation page with the most important information including how to upgrade from greenDAO 2.

In the coming days, we will also publish some benchmarks and work on the documentation. Stay tuned and sign up for our newsletter:

Spread the love
Posted in Release and tagged , , , , .

13 Comments

  1. Does GreenDAO 3 play nice with Google’s AutoValue project? Would be nice if they can be used together!

  2. I can’t get it work…can you please give full documentation about how to install from scratch? Thanks anyway!!!

  3. I tried…

    buildscript {
    dependencies {
    classpath ‘org.greenrobot:greendao-gradle-plugin:3.0.0’
    }
    }// In current version 3.0.0, this must precede the android plugin!
    apply plugin: ‘org.greenrobot.greendao’

    dependencies {
    compile project(‘org.greenrobot:greendao:3.0.1’)
    }

    But I always get error when sync gradle… Saying project org.greenrobot:greendao:3.0.1 not found in app…

    • For me, changing

      compile project(‘org.greenrobot:greendao:3.0.1’)

      to

      compile ‘org.greenrobot:greendao:3.0.1’

      works fine.

  4. Pingback: greenDAO 3.1 released - Open Source by greenrobot

  5. Hi,

    I think this is excellent. I want to use it a little bit more. But I have one problem: For now I did not find any way to make a 1:n-relation bidirectional. Please help me.

    Thank you!
    rootandy

    • greenDAO does not support bi-directional relations at this point. You have to do the management yourself.

      • Ok but thanks anyway. I was just thinking of it because it should be as easy as “targetEntityDao.findById(referencingColumn)”. And with m:n-Relations you already made it possible (with an Entity in between, what i think btw is great, because no other android ORM can’t do real m:n).

        Thanks again for your hard and great work.

      • Sorry, but in 1:n-Relations I got bidirectional relations to work: I combined the @ToOne annotation with the @ToMany(referencedJoinProperty=”..”) and it works like a charm. Now with order.getCustomer().getOrders() (according to your example in the documentation) I get all Orders of the customer.
        Thanks anyway; I really like your framework. (Even I think the m:n-relations are a little bit buggy).

  6. I’m very new to GreenDao and having difficulties even getting it running because of lacking proper docs for version 3. I don’t know what to do next after creating my entities with annotations. The example codes on github does not run after downloaded either.

Comments are closed.