mirror of
https://gitee.com/dromara/sa-token.git
synced 2025-08-24 07:22:48 +08:00
优化文档
This commit is contained in:
parent
5fbafc7674
commit
f97f9fb06c
@ -1,7 +1,7 @@
|
||||
<p align="center">
|
||||
<img alt="logo" src="https://gitee.com/dromara/sa-token/raw/master/sa-token-doc/doc/logo.png" width="150" height="150">
|
||||
</p>
|
||||
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">sa-token v1.19.0</h1>
|
||||
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">Sa-Token v1.19.0</h1>
|
||||
<h4 align="center">这可能是史上功能最全的 Java 权限认证框架!</h4>
|
||||
<h4 align="center">
|
||||
<a href="https://gitee.com/dromara/sa-token/stargazers"><img src="https://gitee.com/dromara/sa-token/badge/star.svg"></a>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<p align="center">
|
||||
<img alt="logo" src="https://gitee.com/dromara/sa-token/raw/master/sa-token-doc/doc/logo.png" width="150" height="150">
|
||||
</p>
|
||||
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">sa-token v1.19.0</h1>
|
||||
<h1 align="center" style="margin: 30px 0 30px; font-weight: bold;">Sa-Token v1.19.0</h1>
|
||||
<h4 align="center">这可能是史上功能最全的 Java 权限认证框架!</h4>
|
||||
<h4 align="center">
|
||||
<a href="https://gitee.com/dromara/sa-token/stargazers"><img src="https://gitee.com/dromara/sa-token/badge/star.svg"></a>
|
||||
|
@ -10,7 +10,7 @@
|
||||
<!-- tab:SpringMVC环境 (ServletAPI) -->
|
||||
如果你使用的框架基于 ServletAPI 构建( `SpringMVC`、`SpringBoot`、`Zuul`等 ),请引入此包
|
||||
``` xml
|
||||
<!-- sa-token 权限认证, 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<!-- Sa-Token 权限认证, 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-spring-boot-starter</artifactId>
|
||||
@ -21,7 +21,7 @@
|
||||
<!-- tab:WebFlux环境 (Reactor) -->
|
||||
注:如果你使用的框架基于 Reactor 模型构建(`Netty`、`WebFlux`、`Soul`、`SC Gateway`等),请引入此包
|
||||
``` xml
|
||||
<!-- sa-token 权限认证(Reactor响应式集成), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<!-- Sa-Token 权限认证(Reactor响应式集成), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-reactor-spring-boot-starter</artifactId>
|
||||
@ -32,7 +32,7 @@
|
||||
<!-- tab:Servlet容器环境 -->
|
||||
注:如果你的项目没有使用Spring,但是Web框架是基于`ServletAPI`规范的,可以引入此包
|
||||
``` xml
|
||||
<!-- sa-token 权限认证(ServletAPI规范), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<!-- Sa-Token 权限认证(ServletAPI规范), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-servlet</artifactId>
|
||||
@ -43,7 +43,7 @@
|
||||
<!-- tab:其它 -->
|
||||
注:如果你的项目既没有使用`SpringMVC`、`WebFlux`,也不是基于`ServletAPI`规范,那么可以引入`core`核心包
|
||||
``` xml
|
||||
<!-- sa-token 权限认证(core核心包), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<!-- Sa-Token 权限认证(core核心包), 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-core</artifactId>
|
||||
@ -53,7 +53,6 @@
|
||||
<!---------------------------- tabs:end ------------------------------>
|
||||
|
||||
|
||||
|
||||
## Gradle依赖
|
||||
<!-- tabs:start -->
|
||||
<!-- tab:SpringMVC环境 (ServletAPI) -->
|
||||
@ -74,11 +73,13 @@ implementation 'cn.dev33:sa-token-core:1.19.0'
|
||||
```
|
||||
<!-- tabs:end -->
|
||||
|
||||
注:JDK版本:`v1.8+`
|
||||
|
||||
|
||||
## 获取源码
|
||||
如果你想深入了解`sa-token`,你可以通过`gitee`或者`github`来获取源码 (**学习测试请拉取master分支**,dev为正在开发的分支,有很多特性并不稳定)
|
||||
- gitee地址:[https://gitee.com/dromara/sa-token](https://gitee.com/dromara/sa-token)
|
||||
- github地址:[https://github.com/dromara/sa-token](https://github.com/dromara/sa-token)
|
||||
如果你想深入了解Sa-Token,你可以通过`Gitee`或者`GitHub`来获取源码 (**学习测试请拉取master分支**,dev为正在开发的分支,有很多特性并不稳定)
|
||||
- Gitee地址:[https://gitee.com/dromara/sa-token](https://gitee.com/dromara/sa-token)
|
||||
- GitHub地址:[https://github.com/dromara/sa-token](https://github.com/dromara/sa-token)
|
||||
- 开源不易,求鼓励,给个`star`吧
|
||||
- 源码目录介绍:
|
||||
|
||||
|
@ -3,14 +3,14 @@
|
||||
|
||||
Sa-token默认将会话数据保存在内存中,此模式读写速度最快,且避免了序列化与反序列化带来的性能消耗,但是此模式也有一些缺点,比如:重启后数据会丢失,无法在集群模式下共享数据
|
||||
|
||||
为此,sa-token将数据持久操作全部抽象到 `SaTokenDao` 接口中,保证大家对框架进行灵活扩展,比如我们可以将会话数据存储在 `Redis`、`Memcached`等专业的缓存中间件中,做到重启数据不丢失,而且保证分布式环境下多节点的会话一致性
|
||||
为此,Sa-Token将数据持久操作全部抽象到 `SaTokenDao` 接口中,保证大家对框架进行灵活扩展,比如我们可以将会话数据存储在 `Redis`、`Memcached`等专业的缓存中间件中,做到重启数据不丢失,而且保证分布式环境下多节点的会话一致性
|
||||
|
||||
除了框架内部对`SaTokenDao`提供的基于内存的默认实现,官方仓库还提供了以下扩展方案:<br>
|
||||
|
||||
|
||||
### 1. Sa-Token 整合 Redis (使用jdk默认序列化方式)
|
||||
``` xml
|
||||
<!-- sa-token整合redis (使用jdk默认序列化方式) -->
|
||||
<!-- Sa-Token整合redis (使用jdk默认序列化方式) -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-dao-redis</artifactId>
|
||||
@ -22,7 +22,7 @@ Sa-token默认将会话数据保存在内存中,此模式读写速度最快,
|
||||
|
||||
### 2. Sa-Token 整合 Redis (使用jackson序列化方式)
|
||||
``` xml
|
||||
<!-- sa-token整合redis (使用jackson序列化方式) -->
|
||||
<!-- Sa-Token整合redis (使用jackson序列化方式) -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
<artifactId>sa-token-dao-redis-jackson</artifactId>
|
||||
|
Loading…
Reference in New Issue
Block a user