Comments (2)
我之前也在思考拦截器的设计这块。
有cicada现在的拦截器有几点看法:
-
不合理的地方
- 缺少拦截驳回的功能。
- 不能设置拦截器的顺序。
-
Support will be better
- IncludeUrlPatterns
- ExcludeUrlPatterns
我之前设计的接口是这样的:
public interface HttyInterceptorAdapter extends HttyInterceptorWrapper, Priority, UrlPatternMatchEnable {
@Override
default boolean preHandle(HttyRequest request, HttyResponse response) {
return true;
}
@Override
default void postHandle(HttyRequest request, HttyResponse response) {
}
@Override
int getPriority();
@Override
Collection<String> getIncludeUrlPatterns();
@Override
Collection<String> getExcludeUrlPatterns();
}
能否用在cicada中,我提个pr? 或者有其他想法?
from cicada.
from cicada.
Related Issues (20)
- 项目初始化阶段基于注解的扫描建议 HOT 3
- 并发问题 HOT 5
- 如果包路径和项目的包路径一样,configurationList中会有相同的元素 HOT 2
- @Inteceptor order一样的话,会导致先前扫描到的interceptor 被覆盖 HOT 2
- Interceptor加载优化 HOT 2
- 读取配置文件的操作可否从action的execute里面抽离 HOT 1
- Got a null NullPointerException when APP starting! HOT 2
- ClassScanner$getCustomRouteBean获取IOC容器过程复杂 HOT 1
- 为啥不做彻底一点,直接通过注解实例化bean HOT 1
- HttpDispter使用单独的EventGroup? HOT 3
- Performance Test HOT 1
- HttpDispatcher.responseContent是不是在try中合适? HOT 5
- fastjson version need update HOT 1
- 群加不了呢? HOT 1
- RingBufferWheel 请问如何保证最后一个 Task 在 调用了 stop(false) 后还能被执行 HOT 1
- 初始化方法好像有点问题...
- Is it better to use ChannelFutureListener at the end of HttpDispatcher HOT 2
- 请问10w并发是怎么测试的,需要一些额外的设置吗
- 写了半天。。。最终发现除了get 其他的都拿不到参数.... HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cicada.