自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(103)
  • 资源 (2)
  • 收藏
  • 关注

原创 redis (error) CLUSTERDOWN The cluster is down

在测试的时候发现redis提示(error) CLUSTERDOWN The cluster is downcheck一下先:报错了,[ERR] Not all 16384 slots are covered by nodes.修复,redis-cli --cluster fix 127.0.0.1:6379输出如下已修复...

2020-04-13 17:50:00 2269 1

原创 [leetcode]14.Longest Common Prefix

Write a function to find the longest common prefix string amongst an array of strings.If there is no common prefix, return an empty string"".Example 1:Input: ["flower","flow","flight"]Output:...

2020-01-20 17:32:12 181

原创 Springboot Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory

报错:Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory在网上搜了各种方法都没有得到解决,先大概列一下有以下几种说法:1.没有加@SpringBootApplication注解,我加了,所以不是这个原因2.没有加@EnableAutoConfiguration...

2020-01-17 14:58:10 2250 2

原创 resin服务本地调试

在项目he-project下建两个文件夹,分别为resin和webapp安装的resin放在resin文件夹中,resin文件夹如下conf/resin.xml配置如下:<!-- - Resin 4.0 configuration file. --><resin xmlns="http://caucho.com/ns/resin" ...

2020-01-10 17:07:30 375

原创 项目启动报错:Caused by: java.lang.IncompatibleClassChangeError: Implementing class at java.lang.ClassLoad

项目启动报错:Caused by: java.lang.IncompatibleClassChangeError: Implementing class at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at ja...

2020-01-09 14:18:41 499

原创 springboot pom.xml 配置不替换问题

今天遇到了一个问题,在Pom中配置的变量在编译时没有自动替换.properties文件和.xml文件中的${key},后来发现原因是因为我在pom里面写了:进入starter-parent的pom以后发现:默认的替换符如下所示,是@符号解决这个问题有两种方法:1.把变量引用改写为@key@2.在build中添加如下插件,使其使用maven替换符<plugin&g...

2020-01-02 19:28:14 1495

原创 springboot注解拦截器不生效问题

今天用springboot写了一个注解拦截器,一直不生效,网上各种方式我都尝试过了,都不起作用,找了好久总算知道是什么原因了我的annotation:@Inherited@Target({ ElementType.TYPE, ElementType.METHOD})@Retention(RetentionPolicy.RUNTIME)@Documentedpub...

2019-12-31 18:13:01 2342

原创 springboot 拦截器返回json字符串给前端页面

在intercept中加入以下代码: private void returnJson(HttpServletResponse response, String json){ PrintWriter writer = null; response.setCharacterEncoding("UTF-8"); response.setCont...

2019-12-31 18:04:51 3665

原创 spring 事务不生效问题 bmw-jade-route事务配置

在spring中配置了事务,但是没有生效@Transactional(rollbackFor = {Exception.class}) public Long insertTicket(Ticket ticket, List<Long> attachIds) throws Exception { LOGGER.info("Insert ticket wit...

2019-12-24 14:52:20 231

原创 不同Java版本切换

export JAVA_HOME=/user/local/jdk-11.0.5export PATH=$JAVA_HOME/bin:$PATHexport CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jarecho ${JAVA_HOME}一开始想在shell脚本中每次改java_home,失败,报错提示信息:...

2019-11-22 18:29:39 821

原创 mabatis Mapper.xml报错

org.springframework.jdbc.BadSqlGrammarException:### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual...

2019-10-29 14:58:39 947

原创 MySql集群搭建

分布式、集群都是用来处理大批量数据操作的,工作原理不太一样。分布式是缩短每个任务的执行时间来提升工作效率,集群是提高单位时间内执行的任务数来提高效率。分布式是将步骤分到不同机器上,集群指的是几个任务同时处理。 管理节点,数据节点和sql节点。管理节点(ndb_mgmd),管理服务器,负责管理数据节点和sql节点,以及集群配置文件和集群日志文件。监控其他节点的工作状态,能够启动...

2019-10-21 17:29:05 96

原创 一条sql语句添加多个字段

Forbiden: Merge the alter statement for table 'app_info' to ONE.需要给表中添加两个字段,之前写了两句:alter table app_info add software_copy_right text comment "软著地址";alter table app_info add qualifications text ...

2019-10-16 16:56:00 5641

原创 [报错解决]freemarker java.io.FileNotFoundException/TemplateNotFoundException: Template xxx not found.

java.io.FileNotFoundException: Template common/user_menu.ftl not found.最开始一直报fileNotFound,后来又报templateNotFound,看了很多文章刚开始一直没有解决。根据提示,始终觉得是路径的问题,我的项目目录结构如下:尝试升级了freemarker版本,仍然未解决最初在resou...

2019-10-12 10:36:06 6625 1

原创 spring security自定义权限配置

最近在项目中遇到了关于spring security的问题,所以学习一下。需要引入依赖: <dependency> <groupId>org.springframework.security</groupId> <artifactId>spring-security-web...

2019-10-09 11:23:25 2597

原创 com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax;

一、com.xiaomi.miliao.dal.DAOException: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio...

2019-09-19 17:20:45 1916

原创 基于旧的master开发的分支,之后master更新了版本应该怎么平滑过度?

基于旧的master开发的分支,之后更新了master以后,需要把feature分支rebase到新的master。假设feature分支名为hellodake,切换到master-VCS-git-pull,拉取当前master最新版本代码;切换到分支hellodake,在Version Control中找到当前远程master,右键-rebase current onto selec...

2019-09-18 18:24:07 1198

原创 git拉取本地不存在的分支

一、首先 git branch -a 查看全部分支:二、git fetch 获取远程所有分支三、git branch -r 可以看到所有远程分支,假设要拉取的是分支update四、git checkout update 会在本地创建一个同名分支,并与该远程分支关联...

2019-09-18 14:19:59 1584

原创 [leetcode]78. Subsets

Given a set ofdistinctintegers,nums, return all possible subsets (the power set).Note:The solution set must not contain duplicate subsets.Example:Input: nums = [1,2,3]Output:[ [3], [1...

2019-08-16 16:34:56 107

原创 [leetcode]237. Delete Node in a Linked List

Write a function to delete a node (except the tail) in a singly linked list, given only access to that node.Given linked list --head =[4,5,1,9], which looks like following:Example 1:Input: ...

2019-07-16 20:02:23 78

原创 [leetcode]206. Reverse Linked List

Reverse a singly linked list.Example:Input: 1->2->3->4->5->NULLOutput: 5->4->3->2->1->NULLFollow up:A linked list can be reversed either iteratively or recursiv...

2019-07-16 17:01:48 118

原创 消息队列

REF:https://www.jianshu.com/p/36a7775b04ec1.什么是消息队列? 消息队列可以看作是一个存放消息的容器,当需要使用消息的时候从容器中取出来。消息队列可以说是分布式系统中一个重要的组件,使用消息队列可以通过异步处理提高系统性能和削减峰值、降低系统耦合性。 在消息队列使用的时候,类比队列,我们需要保证一致性问题。消息不能被重复消费,多个消...

2019-07-16 11:07:34 114

原创 [ERROR]ubuntu18.04自带中文输入法在输入中文选择内容的时候出现数字而不是中文

ubuntu18.04自带中文输入法在输入中文选择内容的时候出现数字而不是中文今天早上遇到了这个问题,sudo rm -rf ~/.cache/ibus/libpinyin重启电脑。解决。...

2019-07-16 09:58:59 463

原创 [leetcode]347. Top K Frequent Elements

Given a non-empty array of integers, return thekmost frequent elements.Example 1:Input: nums = [1,1,1,2,2,3], k = 2Output: [1,2]Example 2:Input: nums = [1], k = 1Output: [1]Note:You ...

2019-07-15 14:51:20 67

原创 [ERROR]ubuntu18.04安装Postman报错

解压完成以后,进入解压目录,执行./Postman,提示:./Postman: error while loading shared libraries: libgconf-2.so.4: cannot open shared object file: No such file or directory此时需要执行:sudo apt install libgconf2-4完成以后...

2019-07-12 14:45:27 548

原创 [leetcode]238. Product of Array Except Self

Given an arraynumsofnintegers wheren> 1, return an arrayoutputsuch thatoutput[i]is equal to the product of all the elements ofnumsexceptnums[i].Example:Input: [1,2,3,4]Output: ...

2019-07-11 19:48:00 75

原创 [leetcode]22. Generate Parentheses

Givennpairs of parentheses, write a function to generate all combinations of well-formed parentheses.For example, givenn= 3, a solution set is:[ "((()))", "(()())", "(())()", "()(())"...

2019-07-11 16:31:00 69

原创 [ERROR][idea报错]Unmapped Spring configuration files found.

idea启动Event Log提示:Spring Configuration CheckUnmapped Spring configuration files found.Please configure Spring facet or use 'Create Default Context' to add one including all unmapped files.原因是w...

2019-07-11 13:37:16 297

原创 [leetcode]46. Permutations

Given a collection ofdistinctintegers, return all possible permutations.Example:Input: [1,2,3]Output:[ [1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], [3,2,1]]Solution:全排列。cl...

2019-07-02 16:36:30 56

原创 [leetcode]94. Binary Tree Inorder Traversal

Given a binary tree, return theinordertraversal of its nodes' values.Example:Input: [1,null,2,3] 1 \ 2 / 3Output: [1,3,2]Solution:/** * Definition for a binary tree n...

2019-06-28 10:10:15 95

原创 [leetcode]412. Fizz Buzz

Write a program that outputs the string representation of numbers from 1 ton.But for multiples of three it should output “Fizz” instead of the number and for the multiples of five output “Buzz”. Fo...

2019-06-28 09:53:33 89

原创 [leetcode]136. Single Number

Given anon-emptyarray of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runtime complexity. Could you implement it without us...

2019-06-27 15:29:41 73

原创 [leetcode]344. Reverse String

Write a function that reverses a string. The input string is given as an array of characterschar[].Do not allocate extra space for another array, you must do this bymodifying the input arrayin-pl...

2019-06-26 09:49:12 60

原创 [leetcode]1038. Binary Search Tree to Greater Sum Tree

Given the root of a binarysearchtree with distinct values, modify it so that everynodehas a new value equal to the sum of the values of the original tree that are greater than or equal tonode.val...

2019-06-25 17:16:44 212

原创 [leetcode]807.Max Increase to Keep City Skyline

In a 2 dimensional arraygrid, each valuegrid[i][j]represents the height of a building located there. We are allowed to increase the height of any number of buildings, by any amount (the amountscan...

2019-06-24 09:15:35 112

原创 Manifest.json文档说明

    Manifest.json文件是5+移动App的配置文件,用于指定应用的显示名称、图标、应用入口文件地址及需要使用的设备权限等信息。是扩展的配置文件,指明了扩展的各种信息。    一个manifest.json格式如下:{    // 必须的字段3个    "name": "MyExtension", // 扩展名称    "version": "1.0", // 版...

2018-11-13 15:11:55 35038 4

原创 maven学习

1.什么是maven    maven是基于项目对象模型(POM),可以通过一小段描述信息(配置文件)来管理项目的构建、报告和文档的软件项目管理工具。是一个采用纯Java编写的开源项目管理工具,所有的项目配置信息都被定义在一个叫做POM.xml的文件中,通过该文件maven可以管理项目的整个生命周期,包括清除、编译、测试、报告、打包、部署等。2.maven模型    3.maven...

2018-11-08 11:01:47 190

转载 git常用命令熟悉

workspace:工作区 Index/Stage:暂存区 Repository:仓库区(本地仓库) Remote:远程仓库新建代码库# 在当前目录新建一个Git代码库$ git init# 新建一个目录,将其初始化为Git代码库$ git init [project-name]# 下载一个项目和它的整个代码历史$ git clone [url]配置# 显...

2018-11-08 10:08:33 174

原创 Hive学习笔记1

Hive:数据仓库;Hive:解释器,编译器,优化器等;Hive运行时,元数据存储在关系型数据库里面。Hive的架构通过命令行接口接入Hive;把SQL翻译成map-reduce。数据存在HDFS中,元数据(表信息,表字段)放在关系型数据库中,任务转化成map-reduce任务。PS.元数据不放在HDFS上,因为慢,而且元数据很小,所以可以放在关系型数据库上。Hiv...

2018-10-22 19:28:11 94

原创 字符串编辑距离

    字符串的编辑距离,又称为Levenshtein距离。是利用字符操作,把字符串A转换成字符串B所需要的最少操作数。其中,字符操作包括:删除一个字符 插入一个字符 修改一个字符    例如对于"hello"和"hell",可以通过插入一个'o'和删除一个'o'来达到目的。    一般来说,两个字符的编辑距离越小,则它们越相似。如果两个字符串相同,则它们的编辑距离为0.可以分析出,...

2018-09-22 19:42:51 597

Mathtype中丢失Mplugin.dll

Mathtype中丢失Mplugin.dll,把Mplugin.dll文件放到Mathtype安装根目录下就好了。

2019-01-06

hadoop2.7.3 在windows下需要的hadoop.dll winutils.exe等文件(bin目录)

hadoop2.7.3 在windows下需要的hadoop.dll winutils.exe等文件 拷贝到bin目录下覆盖。

2017-11-20

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除