Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
isc-core
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
isc-v3.1-tmp
isc-core
Commits
82a5e843
Commit
82a5e843
authored
Sep 27, 2024
by
hulei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加拦截器
parent
2c760646
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
10 deletions
+2
-10
ISCAuthInterceptor.java
.../com/brilliance/isc/common/filter/ISCAuthInterceptor.java
+2
-10
No files found.
isc-common-service/src/main/java/com/brilliance/isc/common/filter/ISC
RequestPreFilte
r.java
→
isc-common-service/src/main/java/com/brilliance/isc/common/filter/ISC
AuthIntercepto
r.java
View file @
82a5e843
...
...
@@ -17,17 +17,13 @@ import org.springframework.web.servlet.ModelAndView;
import
javax.annotation.Resource
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
javax.ws.rs.container.ContainerRequestContext
;
import
javax.ws.rs.container.ContainerRequestFilter
;
import
javax.ws.rs.core.Context
;
import
javax.ws.rs.core.HttpHeaders
;
import
java.io.IOException
;
import
java.util.concurrent.TimeUnit
;
public
class
ISC
RequestPreFilter
implements
HandlerInterceptor
{
public
class
ISC
AuthInterceptor
implements
HandlerInterceptor
{
Logger
logger
=
LoggerFactory
.
getLogger
(
ISC
RequestPreFilte
r
.
class
);
Logger
logger
=
LoggerFactory
.
getLogger
(
ISC
AuthIntercepto
r
.
class
);
@Resource
...
...
@@ -57,8 +53,6 @@ public class ISCRequestPreFilter implements HandlerInterceptor {
BchServiceImpl
.
removeBchInrCacheMap
();
}
@Override
public
boolean
preHandle
(
HttpServletRequest
request
,
HttpServletResponse
response
,
Object
handler
)
throws
IOException
{
clearCache
();
String
requestURI
=
request
.
getRequestURI
();
...
...
@@ -95,12 +89,10 @@ public class ISCRequestPreFilter implements HandlerInterceptor {
return
true
;
}
@Override
public
void
postHandle
(
HttpServletRequest
request
,
HttpServletResponse
response
,
Object
handler
,
ModelAndView
modelAndView
)
{
System
.
out
.
println
(
"postHandle: "
+
request
.
getRequestURI
());
}
@Override
public
void
afterCompletion
(
HttpServletRequest
request
,
HttpServletResponse
response
,
Object
handler
,
Exception
ex
)
{
System
.
out
.
println
(
"afterCompletion: "
+
request
.
getRequestURI
());
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment