这几天,用tomcat运行springmvc项目时,遇到这样一个问题,服务器CPU、内存都是本地开发环境的2倍,但是访问项目时非常卡,最后找到原因,竟然是tomcat打印台导致。 一、 错误描述 导致界面查询很慢的原因,是因为tomcat打印台处于中文模式下,所以导致系统处理结果变慢。错误tomca ...
分类:
其他好文 时间:
2021-03-04 13:31:10
阅读次数:
0
axios是一个就promise的HTTP库,可以用在浏览器和node.js中 main.js import Vue from 'vue' import axios from 'axios' // 使用拦截器// 添加请求拦截器 axios.interceptors.response.use( re ...
分类:
移动开发 时间:
2021-03-04 13:30:53
阅读次数:
0
这里举例两种方式。 1. Newtonsoft.Json.JsonConvert 需要引用外部的 Newtonsoft.Json.dll /// <summary> /// 将json字符串转换为对象(使用Json.net) /// </summary> /// <param name="respo ...
pom.xml <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance ...
分类:
编程语言 时间:
2021-02-26 13:18:18
阅读次数:
0
框架注解 在写代码时,特别是SpringMVC框架下的代码,在dao层,service层,controller层,开始写代码时,一定要先在类上加@注解,切记不能再犯这个小错误. MyBatis与MySQL版本 在使用MyBatis框架连接数据库时,运行程序出现如下异常: java.sql.SQLEx ...
分类:
编程语言 时间:
2021-02-25 11:55:22
阅读次数:
0
1、SpringBoot+Maven自动帮我们管理的某个版本的依赖,如果需要修改版本,在pom.xml中配置即可 2、SpringBoot启动程序返回一个IOC容器,已自动装配所有web开发的常用场景。 而如果使用以前的Spring整合SpringMVC,则需要在web.xml配置文件中配置很多的组 ...
分类:
编程语言 时间:
2021-02-24 13:28:21
阅读次数:
0
##方法一 ###新增CustomException.php文件 App\Exceptions\CustomException.php <?php namespace App\Exceptions; use Exception; /** * 王召波自定义异常基类 * Class BaseExcept ...
分类:
其他好文 时间:
2021-02-24 13:08:11
阅读次数:
0
Request对象:接?封装了客户请求信息,如客户请求?式、参数、客户使?的协议、以 及发出请 求的远程主机信息等, 其主要?法: String getParamter(String paramName);//获取请求参数 String[] getParamterValues(String para ...
分类:
其他好文 时间:
2021-02-23 14:10:28
阅读次数:
0
方式1:js代码,延迟2秒后跳转到首页 <script> setTimeout(function () { location.href = '/'; }, 2000);</script> 方式2:利用响应头部进行重定向 response = make_response('注销并进行重定向', 302 ...
分类:
其他好文 时间:
2021-02-22 12:34:44
阅读次数:
0
网页请求报错: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. ...
分类:
数据库 时间:
2021-02-20 12:31:09
阅读次数:
0