Connected to the target VM, address: '127.0.0.1:58177', transport: 'socket'

网上查了一些资料说是
test

package com.ttxq.tt;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

@RunWith(SpringRunner.class)
@SpringBootTest
public class TtApplicationTests {

//    @Test
//    public void contextLoads() {
//    }

}

方法名不能大小写,我本来就不是大写呀****,改成大写没用,全部注释掉,也没用。。。遗留问题。。

Connected to the target VM, address: '127.0.0.1:58583', transport: 'socket'
"C:\Program Files\Java\jdk1.8.0_161\bin\java.exe" -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:58583,suspend=y,server=n -XX:TieredStopAtLevel=1 -noverify -Dspring.output.ansi.enabled=always -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=58582 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost -Dspring.liveBeansView.mbeanDomain -
……………………
Connected to the target VM, address: '127.0.0.1:58583', transport: 'socket'

这个端口被占用了但是没有找到很好的解决办法。。。(查看58583 端口一个是被java.exe 占用一个是被idea占用,但是关闭idea的项目之后java.exe也不占用了,我想应该是有什么地方需要配置才可以,,但是。。。。)

-agentlib:jdwp=transport=dt_socket,address=127.0.0.1:58583

配置文件的问题,去掉这一行不报错了(而且不去掉这一行日志也不会写到文件里面去***)

<configurationFile>${basedir}/src/main/resources/log4j2/log4j2.xml</configurationFile>
<plugin>
                <groupId>org.mybatis.generator</groupId>
                <artifactId>mybatis-generator-maven-plugin</artifactId>
                <version>1.3.2</version>
                <configuration>
                    <!--
                    <configurationFile>${basedir}/src/main/resources/log4j2/log4j2.xml</configurationFile>-->
                    <configurationFile>${basedir}/src/main/resources/generator/generatorConfig.xml</configurationFile>
                    <overwrite>true</overwrite>
                    <verbose>true</verbose>
                </configuration>
            </plugin>

下一步怎怎么搞。。。很奇怪的是这个报错。。哎呦。。南辕北辙
application.properties 配置log4j2路径 完美搞定。。。

logging.config=classpath:log4j2/log4j2.xml

不得不说,springboot的文件配置还是在 application.properties 比较靠谱。

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值