connect finagle filter to specific controller #203
Closed
Comments
In Finatra v2, please see the following example for adding a per-controller filter: https://github.com/twitter/finatra/blob/master/http/src/test/scala/com/twitter/finatra/http/integration/tweetexample/main/TweetsEndpointServer.scala#L26 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi , it's not clear for m the relation between finatra controllers nd finagle services and how can I compose them with filter, for instance, suppose than I wish than some routes will be filtered and check if the user is authenticate, with finagle you could use a filter which receive some service, but in finatra I dont know how apply the filter to some controllers, this is the only example in the doc
class MyServer extends FinatraServer
addFilter(new SimpleFilter)
register(new ExampleController)
//end <-- BTW seems than the author is rubyst :D
would be cool can do
register(onlyAuthenticateFilter andThen UserController))
but controllers seems not be services, what is the correct approach in this case?
The text was updated successfully, but these errors were encountered: