Support for Play 2.6
JakubKahovec opened this issue ยท 24 comments
Hello,
Do you plan to add support for Play 2.6.x
Thank you
@t2v 2.6 is out now, will you update this library or will someone has to fork?
best regards
+1
It would be highly appreciated
All of my projects are waiting for play2-auth with 2.6 support
+1
Looking forward to see 2.6 play framework support
Thanks for open this issue.
And I'm sorry about the delay in integration to Play 2.5 over.
We are planning for create play2-auth version2 for Play2.6.
It will be DI based composition instead of mix-in based composition.
Probably it can not keep the source compatibility to play2-auth 0.x.
However I think that it is better way to integrate to current Play2 ecosystem.
I would like to hear your opinions about it.
best regards
exactly what I thought,
RequestWithAttributes shouldn't be necessary anymore for example (see: https://www.playframework.com/documentation/2.6.x/Highlights26#Request-attributes)
Yes, the next play2-auth should use the Request attribute API built-in Play2
@gakuzzzz nice news, thank you
Just wondering, how are you going to compose injected actions? Inject many ActionBuilders into Controller and then use something like
builder1 andThen builder2
to get resulting Action?
this is me just trying out the actionBuilder stuff, but this can create nearly the same syntax then before
I would keep all the builders private or in a nested class and compose them before handing out the dsl to the user
@ezhulkov @Daxten
This is an annoying problem.
ActionFunctions what have a same Request type can compose each other.
However Different Request type ActionFunctions can not compose.
And ActionBuilders can not compose other ActionBuilder.
To tell the truth, play2-auth has ActionFunctions what partially solves this problem
https://github.com/t2v/play2-auth/blob/master/README.ja.md#actionfunction-%E3%81%A8%E3%81%97%E3%81%A6%E3%81%AE%E5%88%A9%E7%94%A8 (Japanese)
Currently, I think that a better way to compose ActionBuilders is like the action-zipper approach.
I don't think that should be a problem, you can use a sealed trait for example and create a more generic ActionFunction that way
@Daxten
play2-auth's ActionBuilder should be enable to compose all ActionBuilders (provided by any libraries which play2-auth does not know)
Ah! Now I see the problem, yes that's shitty design then by play :/
Agree, action composition in play looks not very convinient
And ActionBuilders can not compose other ActionBuilder.
You can try to compose many ActionBuilders using andThen or compose syntax. Smth like this https://gist.github.com/ezhulkov/90d050a0701206d318999f2995f14472#file-testcontroller-scala-L8
May be it will be better and more concise to have current approach with super() calls and trait chains?
I've forked recently you stackable-controller and put some fixes to support play26 API.
Have not got a chance to get rid of RequestWithAttributes, but it's coming.
Any news? Scala 2.12.3 and play 2.6.3 are waiting for t2v support :)
would you mind to release it somewhere (bintray is incredibly easy for example) ? @fdoumet
What's the timeline looking like for releasing support for Play 2.6?
It's a few months later - any news please?
Looks like there is a pull request: #191
I recommend you migrate to silhouette which I now use in all new projects. It's much more complicated but also well maintained. I would ask the author of play2-auth to just merge the pull request and be done with it. Don't worry about maintaining pre-2.6 branches as the current release version is fine for pre-2.6 and there are critical fixes in 2.6 that everyone should be up to by now anyway.
If anybody's still looking for this, here are the details:
https://bintray.com/adenda/play2-auth/play2-auth