playframework-2.3

Change proxy settings in play framework

落花浮王杯 提交于 2021-02-07 09:44:53
问题 I was behind a proxy when I setup play framework. I edited the ~/.activator/activatorconfig.txt file and it worked fine. Now I need to remove that proxy to work on a different network. I commented out the line but the activator script still tries to use the proxy for connection, when I run ./activator new (or ./activator ui). The file currently looks like this # This are the proxy settings we use for activator # Multiple proxy hosts can be used by separating them with a '|' sign # Do not

Change proxy settings in play framework

生来就可爱ヽ(ⅴ<●) 提交于 2021-02-07 09:44:29
问题 I was behind a proxy when I setup play framework. I edited the ~/.activator/activatorconfig.txt file and it worked fine. Now I need to remove that proxy to work on a different network. I commented out the line but the activator script still tries to use the proxy for connection, when I run ./activator new (or ./activator ui). The file currently looks like this # This are the proxy settings we use for activator # Multiple proxy hosts can be used by separating them with a '|' sign # Do not

Play framework redirect HTTP to https

对着背影说爱祢 提交于 2021-01-27 05:42:18
问题 I used play framework version 2.2.3 and I run activator using following command for accessing site using https. ./activator run -Dhttp.port=disabled -Dhttps.port=9043 and I typed URL in browser as below https://localhost:9043/signin Then it work fine and it redirects to https. But problem is that when I changed my URL as below http://localhost:9043/signin then I want to redirect above URL to https, how should this handled in play framework? 回答1: as of play 2.6.x it's now supported by a

Issue with bindFromRequest in Play! Framework 2.3

巧了我就是萌 提交于 2020-01-29 11:36:07
问题 I'm trying to use the automatic binding feature of Play, without success. I'm developing in Java, on Eclipse 4.4 Luna. Here is my form : <h2>Create a new user</h2> <form action="@routes.Backend.createUser()" method="post"> First Name <input type="text" name="firstName" /> Last Name <input type="text" name="lastName" /> E-mail <input type="email" name="email" /> PIN <input type="number" name="pin" /> Status <input type="text" name="status" /> Is guest? <input type="checkbox" name="isGuest" />

Issue with bindFromRequest in Play! Framework 2.3

流过昼夜 提交于 2020-01-29 11:36:05
问题 I'm trying to use the automatic binding feature of Play, without success. I'm developing in Java, on Eclipse 4.4 Luna. Here is my form : <h2>Create a new user</h2> <form action="@routes.Backend.createUser()" method="post"> First Name <input type="text" name="firstName" /> Last Name <input type="text" name="lastName" /> E-mail <input type="email" name="email" /> PIN <input type="number" name="pin" /> Status <input type="text" name="status" /> Is guest? <input type="checkbox" name="isGuest" />

PlayFramework resolves dependencies every launch

南楼画角 提交于 2020-01-25 04:30:27
问题 Every time I launch my app play resolves dependencies. Considering this happens every single launch takes a lot of time... There was a time I had problem with one lib that wasn't unavailable so the app didn't launch... Is there anyway to configure play/SBT to work like Maven? Download dependencies and use local instead resolve every launch? 回答1: Yes, you can do this. Add skip in update := true in to the build.sbt file to stop dependencies resolution. My build.sbt looks like ... scalaVersion :

Play Framework 2.3 how to reset database?

会有一股神秘感。 提交于 2020-01-14 09:07:07
问题 In the Play 2.3.x documentation on Evolutions it says In development mode however it is often simpler to simply trash your development database and reapply all evolutions from the beginning. However it doesn't give instructions on how to do this. Is there some kind of activator command I can use to do this? How can I reset and reapply evolutions? Thanks! Update: I would prefer not to have to mess with my DB manually, but it seems like that's the only way 回答1: If you don't care about the data

play 2.3.8 sbt excluding logback

时光毁灭记忆、已成空白 提交于 2020-01-14 08:18:10
问题 I'm having a really hard time excluding logback from my play 2.3.8 test run. I've tried many exclude rules, but nothing seems to work. I also can't find it in my dependency tree. Snippet from my sbt file: [...] resolvers ++= Seq( "Typesafe repository snapshots" at "http://repo.typesafe.com/typesafe/snapshots/", "Typesafe repository releases" at "http://repo.typesafe.com/typesafe/releases/", "Sonatype repo" at "https://oss.sonatype.org/content/groups/scala-tools/", "Sonatype releases" at

play 2.3.8 sbt excluding logback

空扰寡人 提交于 2020-01-14 08:17:35
问题 I'm having a really hard time excluding logback from my play 2.3.8 test run. I've tried many exclude rules, but nothing seems to work. I also can't find it in my dependency tree. Snippet from my sbt file: [...] resolvers ++= Seq( "Typesafe repository snapshots" at "http://repo.typesafe.com/typesafe/snapshots/", "Typesafe repository releases" at "http://repo.typesafe.com/typesafe/releases/", "Sonatype repo" at "https://oss.sonatype.org/content/groups/scala-tools/", "Sonatype releases" at

ReactiveMongo Extensions: Bulk update using reactive mongo extensions

余生颓废 提交于 2020-01-06 19:30:06
问题 Is there any way to update bulk records. I am trying to update user object using following code: .update($doc("_id" $in (usersIds: _*)), users, GetLastError(), false , true) In above code i am passing, users List. in user list i also add new properties and chage existing properties state, but with this statement the records are not update If i am using following code: .update($doc("_id" $in (usersIds: _*)), $set("inviteStatus" $eq "Invited"), GetLastError(), false , true) The record updated