I am trying to set up Ebean for a Play 2.4.4 project.
However, I seem not to be able to import Ebean and JPA using
import com.avaje.ebean.*;
import javax.persistence.*;
or just for the Model class
import com.avaje.ebean.Model;
since I always get a "cannot resolve import" leading to obvious compilation errors when I let my model extend the class Model or when I use annotations.
I followed the instructions from https://www.playframework.com/documentation/2.4.4/JavaEbean by adding
addSbtPlugin("com.typesafe.sbt" % "sbt-play-ebean" % "1.0.0")
to my project/plugins.sbt
and
lazy val myProject = (project in file("."))
.enablePlugins(PlayJava, PlayEbean)
to build.sbt in the projects root directory. I suppose "myProject" has to be replaced with the actual name of the project in the lines above (?). Also there already is a line
lazy val root = (project in file(".")).enablePlugins(PlayJava)
in the build.sbt and I tried just adding PlayEbean here as well as to delete it, when using the above code.
In the application.conf I added
ebean.default = ["models.*"]
However, I believe that should only allow ebean to find my own models.
I am not really a "programming expert" and have tried everything I can think of as well as reading everything I could find regarding Play and Ebean...however, when I read https://www.playframework.com/documentation/2.4.4/Migration24, I figure, that my problem has something to do with Ebean having been pulled into an external project.
I would be very happy about any support I can get.