12 2021 档案
摘要:Ⅰ : SQLAIchemy https://zhuanlan.zhihu.com/p/353399436 1.简介 SQLALchemy是Python中的一款优秀的ORM框架,它可以作用于任何第三方Web框架,如flask,tornado等框架。 SQLALchemy相较于DjangoORM来说更
阅读全文
摘要:pip install flask-sqlacodegen flask-sqlacodegen "mysql+pymysql://root:pwd@127.0.0.1/db_name" --tables user --outfile "models/user.py" --flask Python3
阅读全文
摘要:python操作Elasticsearch7.x python3 elasticsearch 先看下面我给准备的干货,如果不能满足,pls 官网文档 :https://pypi.org/project/elasticsearch/ dev 文档: https://elasticsearch-py.r
阅读全文
摘要:Elasticsearch学习笔记 本文链接:https://blog.csdn.net/u011863024/article/details/115721328 订阅专栏 - 第1章 Elasticsearch概述 - 01-开篇 02-技术选型 03-教学大纲 - 第2章 Elasticsear
阅读全文
摘要:redis setnx 过期时间_Redis加锁的几种实现 我们经常在工作中会碰到一些重复请求、并发等问题,而给资源加锁是一种不错的手段。我们今天就整理下使用redis作为分布式锁的几种实现。 redis可以用于几个命令是:INCR、SETNX和SET。 1. 使用INCR加锁 这种加锁的思路是,
阅读全文
摘要:Redisson基本用法 1. Redisson Redisson是Redis官方推荐的Java版的Redis客户端。它提供的功能非常多,也非常强大,此处我们只用它的分布式锁功能。 https://github.com/redisson/redisson 1.1. 基本用法 1 <dependenc
阅读全文
摘要:1.创建SpringBoot工程,选择 Web、MonogDB 依赖,pom如下: <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <ve
阅读全文
摘要:mongodb 事务学习总结 一、预备工作 1.MongoDB需要4.0版本+ 2.需要自己搭建MongoDB复制集,单个mongodb server 不支持事务。 事务原理:mongodb的复制至少需要两个节点。其中一个是主节点,负责处理客户端请求,其余的都是从节点,负责复制主节点上的数据。mon
阅读全文
摘要:Ubuntu18.04 最简单远程桌面 本文链接:https://blog.csdn.net/langyou0/article/details/107959002 Ubuntu开启远程桌面 Ubuntu18.04使用gnome桌面环境,系统自带屏幕共享和远程登录功能,默认使用的是vino作为VNC服
阅读全文
摘要:Ubuntu16.04 远程桌面连接(VNC) 本文链接:https://blog.csdn.net/qq_28284093/article/details/80166614 1、查看我的Ubuntu系统版本 2、客户机win10下载vnc viewer安装: 下载地址:https://www.re
阅读全文