Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 30 2019 08:08
    hoang17 starred kemalcr/kemal
  • Jan 30 2019 06:38
    cayter starred kemalcr/kemal
  • Jan 27 2019 18:40
  • Jan 27 2019 15:56
    sdogruyol closed #498
  • Jan 27 2019 15:56
    sdogruyol commented #498
  • Jan 27 2019 15:53
    sdogruyol closed #509
  • Jan 27 2019 15:53
    sdogruyol commented #509
  • Jan 27 2019 05:14
    mjb2kmn starred kemalcr/kemal
  • Jan 25 2019 01:42
    unixc3t starred kemalcr/kemal
  • Jan 24 2019 22:41
    talentlessguy starred kemalcr/kemal
  • Jan 24 2019 04:00
    ntilotta starred kemalcr/kemal
  • Jan 23 2019 10:12
    iwaruby starred kemalcr/kemal
  • Jan 23 2019 02:35
    isaced starred kemalcr/kemal
  • Jan 21 2019 18:33
    f9n starred kemalcr/kemal
  • Jan 19 2019 12:53
    SeedyROM starred kemalcr/kemal
  • Jan 17 2019 19:06

    sdogruyol on master

    Do not try to call ExceptionHan… Merge pull request #515 from ke… (compare)

  • Jan 17 2019 19:06
    sdogruyol closed #515
  • Jan 17 2019 19:06
    sdogruyol closed #514
  • Jan 17 2019 19:06
    sdogruyol edited #515
  • Jan 17 2019 15:09
    galfarragem starred kemalcr/kemal
Julien Reichardt
@j8r
The biggest one I have been hit it global methods leaking with get, post etc
Ed
@drum445
Oh yeah, how so?
Julien Reichardt
@j8r
create a def get on a given object, then call get inside it
Giorgi Kavrelishvili
@grkek
I cleaned up the global pollution in there
Julien Reichardt
@j8r
@grkek good! but note that it is not a sinatra-like syntax
Giorgi Kavrelishvili
@grkek
shhhh
shush no one has to know
Julien Reichardt
@j8r
That's funny, we have taken two different approaches, me with https://github.com/ricr-web/ricr
Giorgi Kavrelishvili
@grkek
mine is like way much more hackerman-like
but yours has swagger :(
i want that in grip
Julien Reichardt
@j8r
apparently the router is as efficient as Radix. Early benchmarks shows ricr to be on par with router.cr, for simple routes (what https://github.com/the-benchmarker/web-frameworks tests)
Giorgi Kavrelishvili
@grkek
nice I am way below the line but still fast enough
faster than amber and athena tho
the custom router got me slower speeds than kemal
Julien Reichardt
@j8r
it's good enough, in real life it won't matter much
Giorgi Kavrelishvili
@grkek
have you checked out the pipe system I added to grip ?
Julien Reichardt
@j8r
interesting
I got the same granularity by grouping routes in controllers
And handlers are attached to controllers
that are then attached to route actions
Giorgi Kavrelishvili
@grkek
how about custom actions
for example grip has something like a
get "/", Resource, override: :index
and it will go to the index function in the class instead of the get function
Julien Reichardt
@j8r
?
Giorgi Kavrelishvili
@grkek
for example my class of http controller is limited to get, post, put, delete and etc functions
and I wanted to extend it so I added an override to make it route calls to other functions as well
Julien Reichardt
@j8r
add new verbs?
Giorgi Kavrelishvili
@grkek
not cool
adding new verbs for each of them isn't going to work
Julien Reichardt
@j8r
Sorry I don't understand the purpose
Giorgi Kavrelishvili
@grkek
take the phoenix framework for example
its resource can have multiple endpoints
sign_up, log_in, create etc
adding verbs for each of them would be cumbersome ?
Julien Reichardt
@j8r
I got it, get is a method
On my side the action is not inside the method, but it is a Proc
A la sinatra
Giorgi Kavrelishvili
@grkek
its an useful feature
what I liked about kemal was its middleware support literally raw middleware but every request to an endpoint gets sent through it
pipelines help you avoid that
Julien Reichardt
@j8r
But it is useful only because of the framework design (overrides)
Giorgi Kavrelishvili
@grkek
I mean yeah but it is readable
Julien Reichardt
@j8r
Ricr works differently - it takes objects (like Parameters) as input, and a Response object as output.
the Proc is accordingly typed
most of the logic would be in Response, instead of a method
Matias Russitto
@russitto_gitlab
hi, I'm new at crystal and kemal
Giorgi Kavrelishvili
@grkek
@russitto_gitlab Welcome!