--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To post to this group, send email to play-fr...@googlegroups.com.
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.
--
You received this message because you are subscribed to the Google Groups "play-framework" group.
It is a good answer. Scala itself is a great language, but Play-Scala
is not as documented, tuned etc. as Play-Java. Learning Scala because
of Play-Scala is IMHO not worth the time. (It will be probably
changed.) However, learning Scala because of another project (for
example, you have core in a Maven/SBT project and frontend in Play!)
is IMHO worth the time. It is much easier and much more fun than Java.
Regards,
Vít Šesták 'v6ak'
> Do you need to meet any deadlines for this project?
>
> If the answer is yes then go with Java. Otherwise, I would definitely
> recommend trying out scala. It's concise, it's powerful and it's worth it.
> But it's not ready for "prime time". Anorm can do native sql (in fact,
> that's all it does), and there are many other nice shortcuts here and there
> that you'll appreciate. However, things are not finalized and things are
> changing, sometimes dramatically. So be prepared to revisit your code with
> each new beta release.
--
You received this message because you are subscribed to the Google Groups "play-framework" group.
I also work on a rather big play-java application (5 months in the
doing) and switching back from the play-scala one feels like someone
just tied one of my hands behind my back.
Then again, I don't advise to rely simply on using play-scala to learn
the language. For this I can recommend "Programming Scala" by Venkat
Subramaniam.
Manuel
You should be able to integrate almost any other persistence
framework, see http://scala.playframework.org/documentation/scala-0.9.1/database#IntegratingotherexistingDatabaseaccesslibrairies
--
You received this message because you are subscribed to the Google Groups "play-framework" group.
actually I also needed to have access to JPA from the play-java
application which also has some parts written in scala (and thus needs
the play-scala module to be active). for this I needed to patch the
module to get rid of the ScalaModel type declaration which overrides
the java Model. see
http://play.lighthouseapp.com/projects/74274/tickets/17-playdbjpamodel-type-definition-leads-to-incompatibility-with-existing-java-models-applications
> --
> You received this message because you are subscribed to the Google Groups
> "play-framework" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/play-framework/-/wbrL7w65g9oJ.
If you like documented, standard conform things, you may have a look at
JPA.
regards,
R. Magnus
--
Robert Magnus
akquinet tech@spree GmbH
Bülowstraße 66, D-10783 Berlin
Tel. +49 (0)30 235 520 - 44 Fax. +49 (0)30 217 520 - 12
Geschäftsführung: Martin Weber, Dr. Torsten Fink
Amtsgericht Berlin-Charlottenburg HRB 86780 B
USt.-Id. Nr.: DE 225 964 680
First thing: you can use an ORM (or Mongo as you said) with
play-scala, you're not forced to use Anorm. It's just that JPA won't
work well. So if your data is inherently relational and you don't like
Anorm, you can pick a Scala ORM such as Squeryl for example. There is
pretty much no integration between the data layer to the rest of the
framework so it doesn't matter what you use underneath.
On Wed, Jul 20, 2011 at 21:17, Jonas <jlpett...@gmail.com> wrote:
> I was in the same situation as you a month ago. I did know Java well,
> but I'm more curious about learning Scala, and it has been nice to use
> with Play.
>
> But Anorm is far from mature. It may be easier to use JDBC directly
> with Scala. I find it hard to handle errors from the database when
> using Anorm, and it's not good documented, but as long it works it's
> nice. I use PostgreSQL, and some things aren't possible with Anorm
> when using PostgreSQL. E.g. you can not use Magic. And Anorm doesn't
> support all PostgreSQL statements like "Returning" on Insert.
There has been some progress in master compared to 0.9, especially
regarding error handling. In 0.9 most queries where returning an
Either so you had to look specifically to see if there was any SQL
error. Now it's throwing an SQLException so you get the same feedback
as if you were using JDBC directly. Additionally, there was a bug in
Anorm where field names were not escaped. That would break on MySQL if
you had reserved names in your columns names (user, column...) but
work on H2 (so you saw the bug in prod but not dev). This has been
fixed too.
> --
> You received this message because you are subscribed to the Google Groups "play-framework" group.
> To post to this group, send email to play-fr...@googlegroups.com.
> To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.
>
>
--
Erwan Loisant
There are things to concern when you use jpa together with scala (see
http://scala.playframework.org/documentation/scala-0.9/database). But:
JPA has a long history and its used in a lot real life applications and
you got (for the jpa part) a _lot_ of documentation - that shouldn't be
underestimated.
For your choice, just check:
- do you need a strong relational database or more a NonSQL database
- how many data you do have: 100, 10.000, 1.000.000
- do you have an existing db schema, possibly big and strange
- do you have blobs
regards,
Robert