happy-code-starter-user-sample

user组件使用示例

License

License

GroupId

GroupId

cool.happycoding
ArtifactId

ArtifactId

happy-code-starter-user-sample
Last Version

Last Version

1.0.0.RELEASE
Release Date

Release Date

Type

Type

jar
Description

Description

happy-code-starter-user-sample
user组件使用示例
Project Organization

Project Organization

HappyCoding

Download happy-code-starter-user-sample

How to add to project

<!-- https://jarcasting.com/artifacts/cool.happycoding/happy-code-starter-user-sample/ -->
<dependency>
    <groupId>cool.happycoding</groupId>
    <artifactId>happy-code-starter-user-sample</artifactId>
    <version>1.0.0.RELEASE</version>
</dependency>
// https://jarcasting.com/artifacts/cool.happycoding/happy-code-starter-user-sample/
implementation 'cool.happycoding:happy-code-starter-user-sample:1.0.0.RELEASE'
// https://jarcasting.com/artifacts/cool.happycoding/happy-code-starter-user-sample/
implementation ("cool.happycoding:happy-code-starter-user-sample:1.0.0.RELEASE")
'cool.happycoding:happy-code-starter-user-sample:jar:1.0.0.RELEASE'
<dependency org="cool.happycoding" name="happy-code-starter-user-sample" rev="1.0.0.RELEASE">
  <artifact name="happy-code-starter-user-sample" type="jar" />
</dependency>
@Grapes(
@Grab(group='cool.happycoding', module='happy-code-starter-user-sample', version='1.0.0.RELEASE')
)
libraryDependencies += "cool.happycoding" % "happy-code-starter-user-sample" % "1.0.0.RELEASE"
[cool.happycoding/happy-code-starter-user-sample "1.0.0.RELEASE"]

Dependencies

compile (3)

Group / Artifact Type Version
cool.happycoding : happy-code-starter-user jar 1.0.0.RELEASE
cool.happycoding : happy-code-starter-web jar 1.0.0.RELEASE
cool.happycoding : happy-code-starter-swagger jar 1.0.0.RELEASE

Project Modules

There are no modules declared in this project.

happy-code

License

本项目将日常开发中一些优秀实践封装起来,以微服务技术组件的形式赋能开发,致力于让代码变得简洁优雅,让开发变得简单高效,实现按时下班,回家吃饭的小目标!

如何使用

如何引入依赖

在pom.xml的配置中添加父级依赖

    <parent>
        <groupId>cool.happycoding</groupId>
        <artifactId>happy-code-parent</artifactId>
        <version>1.0.1-SNAPSHOT</version>
    </parent>

然后在 dependencies 中添加自己所需使用的依赖即可使用 注意: 引入该parent之后,在添加happy-code,spring-boot,spring cloud,spring alibaba cloud 组件时均不需要再指定版本号

封装逻辑

模块介绍

版本更新记录

1.0.1-SNAPSHOT[current]

  • feat: 引入jetcache完善cache组件
  • feat: 完善mybatis组件引入乐观锁定义支持
  • feat: 引入阿里ThreadLocal组件
  • feat: 定义默认线程池(happyThreadPoolExecutor),解决线程切换时上下文传递问题
  • feat: web组件提供自定fastjson 序列化/反序列化配置扩展FastJsonConfigCustomizer
  • refactor: 更改组件依赖的继承体系,该改动会造成依赖不兼容的问题,按照新的配置方式进行调整即可
  • refactor: 参照cola架构对异常和返回值封装进行优化

1.0.0.RELEASE

  • feat: 初始版本
  • feat: 规范依赖体系和版本
  • feat: 封装web组件规定序列化/反序列化方式,封装前后端交互规范、全局异常处理规范
  • feat: 封装validator组件,用于请求的入参校验
  • feat: 封装swagger组件,用于接口文档的管理
  • feat: 封装user组件,提供一个用于封装用户信息的UserContext
  • feat: 封装mybatis组件,引入mybatis-plus,实现Entity对象规范定义
  • feat: 封装log组件,规范log配置

框架选型

  • spring Cloud Hoxton.SR8
  • spring Cloud Alibaba 2.2.3.RELEASE

主要依赖

  • lombok 1.18.12
  • hutool 5.3.9
  • fastjson 1.2.73
  • guava 28.0-jre
  • knife4j 3.0.2
  • jetcache 2.6.0
  • fastjson 1.2.75
  • transmittable-thread-local 2.9.0

参考

cool.happycoding

happy-coding

按时下班,回家吃饭

Versions

Version
1.0.0.RELEASE