javaer快速从idea转战vscode

插件安装列表

在插市场安装下面插件

  • Extension Pack for Java
  • Spring Boot Tools 配置文件提示
  • Database Client Database/No-SQL管理工具
  • httpYac - Rest Client .http文件编辑、API测试工具
    https://httpyac.github.io/guide/request.html
  • Git Graph 图形化Git工具
  • XML by Red Hat XML自动提示及格式化
  • YAML by Red Hat K8S自动提示,格式化
  • MybatisX mybatis插件

设置参数setting.json

  • maven建议直接修改./m2/setting.xml
  • 设置自动保存Files: Auto Save
  • 设置控制台打印的编码
    setting.json
bash 复制代码
{
    "http.proxyStrictSSL": false,
    "http.proxyAuthorization": null,
    "cursor.general.disableHttp2": true,
    "git.autofetch": true,
    "redhat.telemetry.enabled": true,
    "database-client.autoSync": true,
    "xml.validation.enabled": false,
    "diffEditor.ignoreTrimWhitespace": false,
    "workbench.editor.limit.enabled": true,
    "files.autoSave": "onFocusChange",
    "git.enableSmartCommit": true,
    "gitlens.views.commitDetails.files.layout": "tree",
    "java.autoAddMissingImports": true,
    "terminal.integrated.defaultProfile.windows": "Command Prompt",
    "terminal.integrated.profiles.windows": {
        "Command Prompt": {
            "path": "cmd.exe
            "args": ["/K", "chcp 65001"],
            "env": {
                "JAVA_TOOL_OPTIONS": "-Dfile.encoding=UTF-8"
            }
        }
    },
}

配置服务启动文件launch.json

bash 复制代码
{
    // 使用 IntelliSense 了解相关属性。 
    // 悬停以查看现有属性的描述。
    // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [

        {
            "type": "java",
            "name": "CDCApplication(test3)",
            "request": "launch",
            "mainClass": "com.CDCApplication",
            "projectName": "platform-api-front",
            "vmArgs": [
                "-Dfile.encoding=UTF-8"
            ],
            "encoding": "UTF-8",
            "args": [
                "--spring.application.name=platform-api",
                "--server.port=31500",
                "--spring.cloud.nacos.config.server-addr=127.0.0.1:8848",
                "--spring.cloud.nacos.config.namespace=test-3",
                "--spring.cloud.nacos.config.username=test3",
                "--spring.cloud.nacos.config.password=test3",
                "--spring.cloud.nacos.config.prefix=platform-api",
                "--spring.cloud.nacos.config.shared-dataids=application.yml",
                "--spring.cloud.nacos.config.refreshable-dataids=application.yml,platform-api.yml",
                "--spring.cloud.nacos.discovery.enabled=true",
                "--spring.cloud.nacos.discovery.register-enabled=false",
                "--mybatis-plus.configuration.log-impl=org.apache.ibatis.logging.stdout.StdOutImpl",
                "--medicalboot.simple-sign=false",
                "--logging.level.com.fpva.fact.mapper=debug",
                "--logging.level.com.fpva.customized.mapper=debug",
                "--logging.level.com.fpva.dal.mapper.*=debug"
            ]
        }
    ]
}
相关推荐
未若君雅裁27 分钟前
MyBatis 一级缓存、二级缓存与清理机制
java·缓存·mybatis
AI人工智能+电脑小能手1 小时前
【大白话说Java面试题 第65题】【JVM篇】第25题:谈谈对 OOM 的认识
java·开发语言·jvm
阿维的博客日记1 小时前
Nacos 为什么能让配置动态生效?(涉及 @RefreshScope 注解)
java·spring
雨辰AI1 小时前
SpringBoot3 + 人大金仓读写分离 + 分库分表 + 集群高可用 全栈实战
java·数据库·mysql·政务
辰海Coding3 小时前
MiniSpring框架学习-完成的 IoC 容器
java·spring boot·学习·架构
小小编程路3 小时前
C++ 多线程与并发
java·jvm·c++
AI视觉网奇3 小时前
linux 检索库 判断库是否支持
java·linux·服务器
她的男孩3 小时前
从零搭一个企业后台,为什么我把能力拆成 Starter 和 Plugin
java·后端·架构
RainCity3 小时前
Java Swing 自定义组件库分享(七)
java·笔记·后端
Sam_Deep_Thinking4 小时前
连锁门店的外卖订单平台对接
java·微服务·架构·系统架构