03 2023 档案

Sql Server 自定义标量值函数 获取URL请求参数
摘要:sql 中获取RUL中指定的参数的值 http://www.hztech.com/aaa.aspx?ab=1&bc=2&ac=3 获取 1,2,3 使用方法: [dbo].[GetURLPara]('ab=1&bc=2&ac=3','bc') CREATE FUNCTION [dbo].[GetUR 阅读全文

posted @ 2023-03-31 10:39 hztech 阅读(49) 评论(0) 推荐(0) 编辑

VS 2022 不支持 .NET Framework 4.5 项目解决办法(Visual Studio 2022)
摘要:用友U9C UBF 开发 平台生成的项目,默认使用的是 .net 4.5 但是 VISUAL studio 2022 已经不支持这个版本了, 解决方法: 手动拷贝 4.5的文件 到 两个文件夹 C:\Windows\Microsoft.NET\Framework C:\Program Files ( 阅读全文

posted @ 2023-03-25 14:30 hztech 阅读(584) 评论(0) 推荐(0) 编辑

C# +SQL 存储过程 实现系统数据权限审查AOP效果
摘要:背景: 1、C/S系统架构 2、前端 Extjs 3、后台C# 4、数据库SQL 前端通过ajAx请求与后台通信。 前端应用页面统一继承入口类 BasePage 应用页面 public partial class xxxxxxx :BasePage { //y业务代码...... } BasePag 阅读全文

posted @ 2023-03-24 16:32 hztech 阅读(362) 评论(1) 推荐(2) 编辑

Java+Redis 通过Lua 完成库存扣减,创建消息队列,异步处理消息--实战
摘要:需要完成功能 借助redis Stream 数据结构实现消息队列,异步完成订单创建,其中涉及到了缓存(击穿,穿透,雪崩),锁(Redisson),并发处理,异步处理,Lua脚本 IDE:IDEA 2022 1、读取库存数据 【Lua】 2、判断库存 【Lua】 3、扣减库存 【Lua】 4、创建队列 阅读全文

posted @ 2023-03-15 16:26 hztech 阅读(640) 评论(1) 推荐(1) 编辑

Redis Stream Commands 命令学习-3 XREADGROUP
摘要:Redis Streams tutorial | Redis xread命令有几个问题: 1、消息丢失的问题 2、消息多人重复读取 3、消息是否读取的状态标记 针对上面的问题,引出另一个概念,“消费者组"(consumber group),可以这么理解,stream 是水果生产基地,组就是中间批发商 阅读全文

posted @ 2023-03-13 13:08 hztech 阅读(1084) 评论(0) 推荐(0) 编辑

hztech Redis Stream Commands 命令学习-2 XREAD
摘要:Listening for new items with XREAD When we do not want to access items by a range in a stream, usually what we want instead is to subscribe to new ite 阅读全文

posted @ 2023-03-13 11:15 hztech 阅读(79) 评论(0) 推荐(0) 编辑

Redis Stream Commands 命令学习-1 XADD XRANGE XREVRANGE
摘要:概况 A Redis stream is a data structure that acts like an append-only log. You can use streams to record and simultaneously syndicate events in real tim 阅读全文

posted @ 2023-03-12 22:16 hztech 阅读(299) 评论(0) 推荐(0) 编辑

企业应该拥有自己的代码平台-程序员应该写有能力的代码
摘要:要 在大数据,云计算,人工智能盛行的环境下,程序员该何去何从?企业自有的研发团队又该如何规划?这两个问题在五年前,我就认真的思考和深入的分析过。程序开发模式基本经历了以下阶段。 传统的程序开发阶段 在对需求进行调研和分析后,最终得到系统的设计架构和技术选型;接下来就是程序员从第一行代码纯手工的编写, 阅读全文

posted @ 2023-03-11 12:35 hztech 阅读(157) 评论(0) 推荐(1) 编辑

c# 递归应用 完成js文件自动引用
摘要:背景: 两张表,分别是 :sys_tbl,和 sys_field,其中:sys_tbl 是系统所有表的信息,包含两个字段 :code(表名),name(表描述信息);sys_fld 是记录第张表中的字段 的名称(field)和描述信息(table) , 截图如下: sys_tbl 其中,字段 名称包 阅读全文

posted @ 2023-03-10 11:05 hztech 阅读(302) 评论(0) 推荐(1) 编辑

利用阻塞队列完成异步操作
摘要://异步阻塞队列变量 private BlockingQueue<VoucherOrder> orderTasks=new ArrayBlockingQueue<>(1024*1024); //create the thread pool signal thread private static f 阅读全文

posted @ 2023-03-08 17:23 hztech 阅读(48) 评论(0) 推荐(0) 编辑

载入静态资源
摘要:public static final DefaultRedisScript<Long> SECKILL_SCRIPT; static { SECKILL_SCRIPT= new DefaultRedisScript<>(); SECKILL_SCRIPT.setLocation(new Class 阅读全文

posted @ 2023-03-08 17:18 hztech 阅读(14) 评论(0) 推荐(0) 编辑

异步,同步,阻塞,非阻塞 4句话表达
摘要:同步:实时同步全过程,连续做几件事,从头到尾不管用多少时间,最后得到一个结果 (单人做战) 异步:异步状态跟踪,对于耗时较久的工作可以让别人去做(或者自己有时间再做),自己不关注过程,有结果通知自己就好 (多人做战) 阻塞:堵门,自己要的鸡蛋灌饼还没有做好,我就堵门等,后面人买烧饼(虽然有现货)对不 阅读全文

posted @ 2023-03-08 14:37 hztech 阅读(18) 评论(0) 推荐(0) 编辑

Lua 垃圾回收
摘要:Lua 内存垃圾回收,是自动完成的,不需要人工处理。 垃圾回收有两种模式: 1、增量式(Incremental) 有三个参数 1)、garbage-collector pause, 什么时间执行,比上次回收后内增加的比例 默认200% 最大1000% 2)、garbage-collector ste 阅读全文

posted @ 2023-03-07 15:30 hztech 阅读(306) 评论(0) 推荐(0) 编辑

Lua 学习-10 元表metaTable
摘要:2.4 – Metatables and Metamethods Every value in Lua can have a metatable. This metatable is an ordinary Lua table that defines the behavior of the ori 阅读全文

posted @ 2023-03-07 13:34 hztech 阅读(35) 评论(0) 推荐(0) 编辑

Luau学习--8 Function call 函数
摘要:2.5.8 – Function Calls A function call in Lua has the following syntax: functioncall ::= prefixexp args In a function call, first prefixexp and args a 阅读全文

posted @ 2023-03-05 15:43 hztech 阅读(129) 评论(0) 推荐(0) 编辑

Lua--学习--7 Table 构建
摘要:2.5.7 – Table Constructors Table constructors are expressions that create tables. Every time a constructor is evaluated, a new table is created. A con 阅读全文

posted @ 2023-03-05 13:31 hztech 阅读(20) 评论(0) 推荐(0) 编辑

Lua 学习--6 运算
摘要:2.5.1 – Arithmetic Operators Lua supports the usual arithmetic operators: the binary + (addition), - (subtraction), * (multiplication), / (division),  阅读全文

posted @ 2023-03-05 11:31 hztech 阅读(10) 评论(0) 推荐(0) 编辑

Lua学习--5 表达式
摘要:2.5 – Expressions The basic expressions in Lua are the following: exp ::= prefixexp exp ::= nil | false | true exp ::= Number exp ::= String exp ::= f 阅读全文

posted @ 2023-03-05 11:00 hztech 阅读(18) 评论(0) 推荐(0) 编辑

Lua学习--4
摘要:结构控制 2.4.4 – Control Structures The control structures if, while, and repeat have the usual meaning and familiar syntax: stat ::= while exp do block e 阅读全文

posted @ 2023-03-04 22:43 hztech 阅读(17) 评论(0) 推荐(0) 编辑

Lua学习--3
摘要:变量 Variables are places that store values. There are three kinds of variables in Lua: global variables, local variables, and table fields. A single na 阅读全文

posted @ 2023-03-04 22:20 hztech 阅读(17) 评论(0) 推荐(0) 编辑

Lua 学习---2
摘要:值和类型 Lua is a dynamically typed language. This means that variables do not have types; only values do. There are no type definitions in the language. 阅读全文

posted @ 2023-03-04 17:57 hztech 阅读(13) 评论(0) 推荐(0) 编辑

学习Lua--1
摘要:1、标识符 Names (also called identifiers) in Lua can be any string of letters, digits, and underscores, not beginning with a digit. Identifiers are used t 阅读全文

posted @ 2023-03-04 15:49 hztech 阅读(34) 评论(0) 推荐(0) 编辑

redis 分布式锁应用
摘要:在开始之前 ,先把结论留下: 要想真正用于生产环境,推荐使用 Redisson 实现分布式锁! <dependency> <groupId>org.redisson</groupId> <artifactId>redisson</artifactId> <version>3.19.3</versio 阅读全文

posted @ 2023-03-03 15:57 hztech 阅读(30) 评论(0) 推荐(0) 编辑

有关事务
摘要:事务简介 事务在逻辑上是一组操作,要么执行,要不都不执行。主要是针对数据库而言的,比如说 MySQL。为了保证事务是正确可靠的,在数据库进行写入或者更新操作时,就必须得表现出 ACID 的 4 个重要特性: 原子性(Atomicity):一个事务中的所有操作,要么全部完成,要么全部不完成,不会结束在 阅读全文

posted @ 2023-03-03 15:14 hztech 阅读(24) 评论(0) 推荐(0) 编辑

idea快捷键
摘要:1、Ctrl+Alt+m 完成选择代码块的封装 2、CTRL+ALT+t 选择代码放在try catch 等快捷操作 如下: 阅读全文

posted @ 2023-03-03 14:40 hztech 阅读(9) 评论(0) 推荐(0) 编辑

PostMan 简单使用
摘要:postman 可以完成模拟请求 post ,get ,delete ,put 等 1 增加headers :Authorization (设置了登录token ) 2选择 POST 3填写请求地址 http://localhost:8081/voucher/seckill 4、输入请求内容 { " 阅读全文

posted @ 2023-03-03 13:18 hztech 阅读(17) 评论(0) 推荐(0) 编辑

Redis 实现唯一全局ID
摘要:package com.hmdp.utils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.redis.core.StringRedisTemplate; 阅读全文

posted @ 2023-03-03 11:04 hztech 阅读(88) 评论(0) 推荐(0) 编辑

redis sentinel模式 及idea 开发方式+redisson
摘要:此内容要在 前一篇 主从模式基础之上阅读 在主从模式的基础上增加 sentinel 主从模式的运行配置 conf配置文件 sentinel monitor mymaster 192.168.1.138 6385 2 192.168.1.138 6385 master2 重新选举时达到数量 s1/se 阅读全文

posted @ 2023-03-01 16:23 hztech 阅读(298) 评论(0) 推荐(0) 编辑

Redis 主从模式安装配置开发Idea 实战
摘要:规划 Centos7 1、创建目录: mkdir 638{5,6,7} [root@machine138 redis-stack]# mkdir masterSlave [root@machine138 redis-stack]# cd masterSlave/ [root@machine138 m 阅读全文

posted @ 2023-03-01 15:01 hztech 阅读(232) 评论(0) 推荐(0) 编辑

Redis 持久化-实战
摘要:两种方式: rdf :默认 save <seconds> <changes> 多长时间内 有几个操作就执行 后台save rdbcompression yes是否执行压缩 建议不开启,因为压缩会消耗CPU dbfilename dump.rdb数据文件名字 ##################### 阅读全文

posted @ 2023-03-01 10:23 hztech 阅读(24) 评论(0) 推荐(0) 编辑

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

导航

统计

点击右上角即可分享
微信分享提示