07 2023 档案
Token和JWT的区别
摘要:服务端验证客户端发送的 token 信息要进行数据的查询操作 Jwt 验证客户端发来的 token 就不用,在服务端使用密钥校验就可以,不用数据库的查询。 Token需要查库验证 token 是否有效,而 JWT 不用查库或者少查库,直接在服务端进行校验,并且不用查库。因为用户的信息及加密信息在第二
fastapi文件上传下载
摘要:```python import os import time from fastapi import APIRouter, File, UploadFile from fastapi.responses import FileResponse router = APIRouter(tags=['U
scrapy
摘要:https://gitee.com/bitterteaer/scrapy-learn.git 在代码中运行scrapy的方法 @https://www.cnblogs.com/kakashiS/p/7475742.html 官方文档给出了两个scrapy工具: scrapy.crawler.Craw
celery
摘要:https://gitee.com/bitterteaer/celery-learn.git Celery的架构由三部分组成,消息中间件(message broker),任务执行单元(worker)和任务执行结果存储(task result store)组成。 基本使用 celery_task im
appsmith使用第三方库进行http请求
摘要:### 安装  ### 使用 ```js export default { debugMeter: asy
sqlalchemy created_at字段自动生成当前时间写法
摘要:```python created_at = Column(Integer, nullable=False, default=lambda: int(time.time())) ``` 使用lambda即可使其实时生成,如果不使用lambda,则无法实时获取时间,只会记录第一次的时间
使用fastapi background task踩的第一个坑
摘要:### 场景复原(这份代码可以和我之前的业务产生同样的效果) ```python async def task(): print("1......") time.sleep(5) print("ok") @router.post("/1") async def crate(background_ta
FastAPI提供了多种安全性机制,包括OAuth2、API密钥等。例如,我们可以使用API密钥保护我们的API
摘要:```python from fastapi.security import APIKeyHeader api_key_header = APIKeyHeader(name="api_key") @app.get("/items/{item_id}", response_model=Item) de
Hystrix-结构图
摘要:
在 Kubernetes(k8s) 上部署 Spring Boot 应用程序:应用程序使用环境变量中的错误端口属性
摘要:### 如果我使用此配置启动部署(即先启动服务,然后启动部署)则 pod 在启动期间会失败。 在日志中,我可以找到以下消息: ```shell *************************** APPLICATION FAILED TO START **********************