maven 配置问题
① 错误
Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'
原因:pom.xml文件下载ojdbc14-10.2.0.3.0.jar只有561k,不好用,换成原来ojdbc14.jar(1501k),然后改名字为ojdbc14-10.2.0.3.0.jar
maven -》Update Project,解决了
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc14</artifactId>
<version>10.2.0.3.0</version>
</dependency>
② pom.xml中jar下载不下来。先下载jar到本地-》执行下面语句例子1/例子2-》maven-》Update Project-》OK
例子1:mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc14 -Dversion=10.2.0.3.0 -Dpackaging=jar -Dfile=C:\ojdbc14-10.2.0.3.0.jar
例子2:mvn install:install-file -DgroupId=org.springframework -DartifactId=org.springframework.web -Dversion=3.1.1.RELEASE -Dpackaging=jar -Dfile=C:\org.springframework.web-3.1.1.RELEASE.jar
③ 每次新建maven工程都下载大量jar,原因:本地库没有配好
1,setting.xml 中设置比如:<localRepository>C:\apache-maven-3.3.9\repository</localRepository>
2,eclipse中添加自己下载的maven Preferences-》Maven-》Installation-》Add-》自己maven目录
User Settings-》选为自己的setting.xml
这样新建maven工程时就会现在本地库检查,如果有就不会下载了。
④:根据【@ 从从前有座山】的提示,找到了问题②的另一种解决方式:
配置maven国内镜像。也就是在pom.xml中添加下列代码,之后maven更新一下就OK了。
<repositories>
<repository>
<id>aliyun-nexus</id>
<name>Nexus</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>aliyun-nexus</id>
<name>Nexus</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</pluginRepository>
</pluginRepositories>
maven 配置问题的更多相关文章
- springboot的maven配置问题
我是在idea中配置的中,mac,直接搜的网上最简单的教程,依赖包报错: project structure中引用路径报错 --> maven仓库的路径可能有问题 找不到springapplic ...
- eclipse maven配置问题:org.apache.maven.archiver.mavenarchiver.getmanifest
原因就是你的maven的配置文件不是最新的 1.help ->Install New Software -> add ->https://otto.takari.io/content ...
- maven配置问题
今天配置maven环境,最后总是显示 百度好多方法,都没解决,最后查看了一下maven目录下的mvn.cmd文件发现里面的jdk引用名用的是%JAVA_HOME%..... 看完就发现问题了,自己装了 ...
- Maven 配置问题 - could not find resource mybatis-config.xml
需要在pom中加入以下代码 <build> <resources> <resource> <directory>src/main/resources&l ...
- Jenkins Maven打包出错异常的解决方法
Jenkins是一个很好用的打包部署工具,实现一键式部署项目,在项目处于测试阶段或者对于运维人员来讲是非常方便的一个工具. 但是最近使用Jenkins部署项目时老是出错,主要是maven打包的问题,错 ...
- maven;cargo;仓库
[说明]又到晚上九点了,不得不加快进度,首先就是日报.今天上午在服务器搭建maven,下午完成了一个maven web项目,晚上改错找maven配置问题(因为想装jetty和cargo) 一:今日完成 ...
- 浅谈maven setting.xml 设置的mirrorof标签作用。
https://blog.csdn.net/whbing1471/article/details/53983779 A 看这一段 背景:写好的java项目放置到linux服务器上进行编辑的时候,由于m ...
- weex开发错误汇总
weex run serve 报UglifyJS错 ANDROID_HOME环境变量 weex build android需要ANDROID_HOME, 请配置 D:\adt-windows-x86_ ...
- Intellij Idea上Spring Boot编译报错:Error:(3, 32) java: 程序包org.springframework.boot不存在
很尴尬,为了使用Spring Boot的Initializr,特意下了个Intellij Idea,刚按提示新建一个Spring Boot的Maven项目后,就出现红叉叉了.因为IDE是新的,开始是M ...
随机推荐
- [LeetCode] Reverse Words in a String 翻转字符串中的单词
Given an input string, reverse the string word by word. For example, Given s = "the sky is blue ...
- leecode系列--Two Sum
学习这件事在任何时间都不能停下.准备坚持刷leecode来提高自己,也会把自己的解答过程记录下来,希望能进步. Two Sum Given an array of integers, return i ...
- 5G承载为什么需要三层到边缘
- C语言学习 第九次作业总结
本次作业练习的内容是二维数组.下面我先简单的说下二维数组的基本知识点: 二维数组其实这个中文概念颇有误导--会让人感觉这是一个两个维度的概念.所以很多的国外的C语言书籍上会称这种数组为多下标数组:即首 ...
- 自定义UIBarButtonItem
如果是通过UIButton自定义UIBarButtonItem,那么通过如下这个方式设置title是无效的.必须要直接给button设置title. self.navigationItem.right ...
- CSS display:inline-block
CSS display:inline-block 在css布局里,我们经常看到代码 「display:inline-block; *display:inline; zoom:1; 」,大多人会说上面的 ...
- import renumber.py in pymol
cp renumber.py /usr/local/lib/python2.7/dist-packages/pymol import renumber or run /path/to/renumber ...
- js控制Bootstrap 模态框(Modal)插件
js控制Bootstrap 模态框(Modal)插件 http://www.cnblogs.com/zzjeny/p/5564400.html
- POJ 2186 Popular Cows(Targin缩点)
传送门 Popular Cows Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 31808 Accepted: 1292 ...
- pandas read table
http://pandas.pydata.org/pandas-docs/stable/10min.html import pandas as pd res = pd.read_table(" ...