Nitromelon

Results 47 comments of Nitromelon

It's a personal demand. Feel free to ignore it if it's inappropriate. This PR has no public api changes. Two more parameters are added for some internel methods. Two more...

Rebase master 46c00a317f169369d416c1a4705bd561ef163d45

Fast DbClient 只能在自己所在的 IO 线程调用,请检查如下几点: 1. 每次使用时都重新调用 getFastDbClient(), 不要使用static变量或类成员变量等存储 2. 获取client时处于IO线程内,使用该client时处于同一线程。 3. controller内的代码可能并不全部都运行在IO线程。任何非fast的回调函数或者 coroutine 调用都可能导致线程切换。 4. 不要在 filter 内使用非fast的回调函数或coroutine

Could `Mapper::paginate()` in #1112 solve your problem?

Could you give a example on what you refering by 'user custom'? https://github.com/drogonframework/drogon/blob/d18740d4bca53670c55e1a3bbdb1b84694eda9f4/drogon_ctl/templates/model_h.csp#L560-L564 These things can be done for all models with a simple template function, which can be written...

The model class generated by `drogon_ctl create model` is just a helper. If you need some custom feature, you can just modified the source file, or add some standalone functions....

Adding a pre-routing advice is actually a good solution. You can make it a plugin, in that case you can easily enable/disable the feature and change configs.

I have a little doubt if we should overwrite peerAddr_. I think user would expect that getPeerAddr() returns the same thing as ::getpeername() does? At least I'm expecting that.

Rebase master [c97125b](https://github.com/drogonframework/drogon/commit/c97125b22f134a9a9b647b4e055f4d218713c6e9)

> Does the filter support async? > > ```c++ > auto redisClientPtr = app().getRedisClient(); > transPtr->execCommandAsync( > [fccb](const nosql::RedisResult &r) { > // successed > return fccb(); > }, >...