当前位置: 首页 > 编程日记 > 正文

Maven-环境配置

=================================================二更================================================================

可算搞好了,除了下面外,我找到了setting.xml里面的东西,给出来就好了,简单就是mvn -v弄好后,setting.xml里面写好的话,直接加入,然后让eclipse下载jar包

然后就可以运行网上的基本项目了

  1 <?xml version="1.0" encoding="UTF-8"?>
  2 
  3 <!--
  4 Licensed to the Apache Software Foundation (ASF) under one
  5 or more contributor license agreements.  See the NOTICE file
  6 distributed with this work for additional information
  7 regarding copyright ownership.  The ASF licenses this file
  8 to you under the Apache License, Version 2.0 (the
  9 "License"); you may not use this file except in compliance
 10 with the License.  You may obtain a copy of the License at
 11 
 12     http://www.apache.org/licenses/LICENSE-2.0
 13 
 14 Unless required by applicable law or agreed to in writing,
 15 software distributed under the License is distributed on an
 16 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 17 KIND, either express or implied.  See the License for the
 18 specific language governing permissions and limitations
 19 under the License.
 20 -->
 21 
 22 <!--
 23  | This is the configuration file for Maven. It can be specified at two levels:
 24  |
 25  |  1. User Level. This settings.xml file provides configuration for a single user,
 26  |                 and is normally provided in ${user.home}/.m2/settings.xml.
 27  |
 28  |                 NOTE: This location can be overridden with the CLI option:
 29  |
 30  |                 -s /path/to/user/settings.xml
 31  |
 32  |  2. Global Level. This settings.xml file provides configuration for all Maven
 33  |                 users on a machine (assuming they're all using the same Maven
 34  |                 installation). It's normally provided in
 35  |                 ${maven.conf}/settings.xml.
 36  |
 37  |                 NOTE: This location can be overridden with the CLI option:
 38  |
 39  |                 -gs /path/to/global/settings.xml
 40  |
 41  | The sections in this sample file are intended to give you a running start at
 42  | getting the most out of your Maven installation. Where appropriate, the default
 43  | values (values used when the setting is not specified) are provided.
 44  |
 45  |-->
 46 <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
 47           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 48           xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
 49   <!-- localRepository
 50    | The path to the local repository maven will use to store artifacts.
 51    |
 52    | Default: ${user.home}/.m2/repository
 53   -->
 54      <localRepository>E:\m2\repository</localRepository>
 55 
 56    
 57   <!-- interactiveMode
 58    | This will determine whether maven prompts you when it needs input. If set to false,
 59    | maven will use a sensible default value, perhaps based on some other setting, for
 60    | the parameter in question.
 61    |
 62    | Default: true
 63   <interactiveMode>true</interactiveMode>
 64   -->
 65 
 66   <!-- offline
 67    | Determines whether maven should attempt to connect to the network when executing a build.
 68    | This will have an effect on artifact downloads, artifact deployment, and others.
 69    |
 70    | Default: false
 71   <offline>false</offline>
 72   -->
 73 
 74   <!-- pluginGroups
 75    | This is a list of additional group identifiers that will be searched when resolving plugins by their prefix, i.e.
 76    | when invoking a command line like "mvn prefix:goal". Maven will automatically add the group identifiers
 77    | "org.apache.maven.plugins" and "org.codehaus.mojo" if these are not already contained in the list.
 78    |-->
 79   <pluginGroups>
 80     <!-- pluginGroup
 81      | Specifies a further group identifier to use for plugin lookup.
 82     <pluginGroup>com.your.plugins</pluginGroup>
 83     -->
 84   </pluginGroups>
 85 
 86   <!-- proxies
 87    | This is a list of proxies which can be used on this machine to connect to the network.
 88    | Unless otherwise specified (by system property or command-line switch), the first proxy
 89    | specification in this list marked as active will be used.
 90    |-->
 91   <proxies>
 92     <!-- proxy
 93      | Specification for one proxy, to be used in connecting to the network.
 94      |
 95     <proxy>
 96       <id>optional</id>
 97       <active>true</active>
 98       <protocol>http</protocol>
 99       <username>proxyuser</username>
100       <password>proxypass</password>
101       <host>proxy.host.net</host>
102       <port>80</port>
103       <nonProxyHosts>local.net|some.host.com</nonProxyHosts>
104     </proxy>
105     -->
106   </proxies>
107 
108   <!-- servers
109    | This is a list of authentication profiles, keyed by the server-id used within the system.
110    | Authentication profiles can be used whenever maven must make a connection to a remote server.
111    |-->
112   <servers>
113     <!-- server
114      | Specifies the authentication information to use when connecting to a particular server, identified by
115      | a unique name within the system (referred to by the 'id' attribute below).
116      |
117      | NOTE: You should either specify username/password OR privateKey/passphrase, since these pairings are
118      |       used together.
119      |
120     <server>
121       <id>deploymentRepo</id>
122       <username>repouser</username>
123       <password>repopwd</password>
124     </server>
125     -->
126 
127     <!-- Another sample, using keys to authenticate.
128     <server>
129       <id>siteServer</id>
130       <privateKey>/path/to/private/key</privateKey>
131       <passphrase>optional; leave empty if not used.</passphrase>
132     </server>
133     -->
134   </servers>
135 
136   <!-- mirrors
137    | This is a list of mirrors to be used in downloading artifacts from remote repositories.
138    |
139    | It works like this: a POM may declare a repository to use in resolving certain artifacts.
140    | However, this repository may have problems with heavy traffic at times, so people have mirrored
141    | it to several places.
142    |
143    | That repository definition will have a unique id, so we can create a mirror reference for that
144    | repository, to be used as an alternate download site. The mirror site will be the preferred
145    | server for that repository.
146    |-->
147   <mirrors>
148 
149     <mirror>
150       <id>mirrorId</id>
151       <mirrorOf>repositoryId</mirrorOf>
152       <name>Human Readable Name for this Mirror.</name>
153       <url>http://my.repository.com/repo/path</url>
154     </mirror>
155     <mirror>
156       <!--This sends everything else to /public -->
157       <id>nexus</id>
158       <mirrorOf>*</mirrorOf> 
159       <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
160     </mirror>
161     <mirror>
162       <!--This is used to direct the public snapshots repo in the 
163           profile below over to a different nexus group -->
164       <id>nexus-public-snapshots</id>
165       <mirrorOf>public-snapshots</mirrorOf> 
166       <url>http://maven.aliyun.com/nexus/content/repositories/snapshots/</url>
167     </mirror>
168   </mirrors>
169 
170   <!-- profiles
171    | This is a list of profiles which can be activated in a variety of ways, and which can modify
172    | the build process. Profiles provided in the settings.xml are intended to provide local machine-
173    | specific paths and repository locations which allow the build to work in the local environment.
174    |
175    | For example, if you have an integration testing plugin - like cactus - that needs to know where
176    | your Tomcat instance is installed, you can provide a variable here such that the variable is
177    | dereferenced during the build process to configure the cactus plugin.
178    |
179    | As noted above, profiles can be activated in a variety of ways. One way - the activeProfiles
180    | section of this document (settings.xml) - will be discussed later. Another way essentially
181    | relies on the detection of a system property, either matching a particular value for the property,
182    | or merely testing its existence. Profiles can also be activated by JDK version prefix, where a
183    | value of '1.4' might activate a profile when the build is executed on a JDK version of '1.4.2_07'.
184    | Finally, the list of active profiles can be specified directly from the command line.
185    |
186    | NOTE: For profiles defined in the settings.xml, you are restricted to specifying only artifact
187    |       repositories, plugin repositories, and free-form properties to be used as configuration
188    |       variables for plugins in the POM.
189    |
190    |-->
191   <profiles>
192     <!-- profile
193      | Specifies a set of introductions to the build process, to be activated using one or more of the
194      | mechanisms described above. For inheritance purposes, and to activate profiles via <activatedProfiles/>
195      | or the command line, profiles have to have an ID that is unique.
196      |
197      | An encouraged best practice for profile identification is to use a consistent naming convention
198      | for profiles, such as 'env-dev', 'env-test', 'env-production', 'user-jdcasey', 'user-brett', etc.
199      | This will make it more intuitive to understand what the set of introduced profiles is attempting
200      | to accomplish, particularly when you only have a list of profile id's for debug.
201      |
202      | This profile example uses the JDK version to trigger activation, and provides a JDK-specific repo.
203     <profile>
204       <id>jdk-1.4</id>
205 
206       <activation>
207         <jdk>1.4</jdk>
208       </activation>
209 
210       <repositories>
211         <repository>
212           <id>jdk14</id>
213           <name>Repository for JDK 1.4 builds</name>
214           <url>http://www.myhost.com/maven/jdk14</url>
215           <layout>default</layout>
216           <snapshotPolicy>always</snapshotPolicy>
217         </repository>
218       </repositories>
219     </profile>
220     -->
221 
222     <!--
223      | Here is another profile, activated by the system property 'target-env' with a value of 'dev',
224      | which provides a specific path to the Tomcat instance. To use this, your plugin configuration
225      | might hypothetically look like:
226      |
227      | ...
228      | <plugin>
229      |   <groupId>org.myco.myplugins</groupId>
230      |   <artifactId>myplugin</artifactId>
231      |
232      |   <configuration>
233      |     <tomcatLocation>${tomcatPath}</tomcatLocation>
234      |   </configuration>
235      | </plugin>
236      | ...
237      |
238      | NOTE: If you just wanted to inject this configuration whenever someone set 'target-env' to
239      |       anything, you could just leave off the <value/> inside the activation-property.
240      |
241     <profile>
242       <id>env-dev</id>
243 
244       <activation>
245         <property>
246           <name>target-env</name>
247           <value>dev</value>
248         </property>
249       </activation>
250 
251       <properties>
252         <tomcatPath>/path/to/tomcat/instance</tomcatPath>
253       </properties>
254     </profile>
255     -->
256 <profile>
257       <id>jdk-1.8</id>
258       <activation>
259         <activeByDefault>true</activeByDefault>
260         <jdk>1.8</jdk>
261       </activation>
262       <properties>
263         <maven.compiler.source>1.8</maven.compiler.source>
264         <maven.compiler.target>1.8</maven.compiler.target>
265         <maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>
266       </properties>
267     </profile>
268   </profiles>
269 
270   <!-- activeProfiles
271    | List of profiles that are active for all builds.
272    |
273   <activeProfiles>
274     <activeProfile>alwaysActiveProfile</activeProfile>
275     <activeProfile>anotherAlwaysActiveProfile</activeProfile>
276   </activeProfiles>
277   -->
278 </settings>
View Code

当然,如果你用一些什么注释的话,pom.xml里面也要写好,我也给出来吧,基本都可以用,目前用lombok,shiro,thymeleaf什么的都还没遇到错误

也可以映射网页

 1 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 2   xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 3   <modelVersion>4.0.0</modelVersion>
 4   <groupId>com.ctgu</groupId>
 5   <artifactId>codegroup</artifactId>
 6   <packaging>war</packaging>
 7   <version>0.0.1-SNAPSHOT</version>
 8   <name>codegroup Maven Webapp</name>
 9   <url>http://maven.apache.org</url>
10   
11   <!--   
12 spring-boot-starter-parent是Spring Boot的核心启动器,
13 包含了自动配置、日志和YAML等大量默认的配置,大大简化了我们的开发。
14 引入之后相关的starter引入就不需要添加version配置,
15    spring boot会自动选择最合适的版本进行添加。
16    -->
17 <parent>
18 <groupId>org.springframework.boot</groupId>
19 <artifactId>spring-boot-starter-parent</artifactId>
20 <version>2.0.0.RELEASE</version>
21 <relativePath/>
22 </parent>
23   
24  
25   <dependencies>
26   
27   <!--Shiro登录界面-->
28 <dependency>
29     <groupId>org.apache.shiro</groupId>
30     <artifactId>shiro-spring</artifactId>
31     <version>1.4.0</version>
32 </dependency>
33   
34   
35   <!-- Thymeleaf引擎 -->
36   <dependency>
37     <groupId>org.springframework.boot</groupId>
38     <artifactId>spring-boot-starter-thymeleaf</artifactId>
39 </dependency>
40   
41   <!-- 热部署所用 -->
42       <dependency>
43         <groupId>org.springframework.boot</groupId>
44         <artifactId>spring-boot-devtools</artifactId>
45         <optional>true</optional>
46     </dependency>
47   
48     <!-- 导入jar包所用 -->
49     <dependency>
50     <groupId>org.springframework.boot</groupId>
51         <artifactId>spring-boot-starter-web</artifactId> 
52     </dependency>
53   
54   
55     <dependency>
56       <groupId>junit</groupId>
57       <artifactId>junit</artifactId>
58       <version>3.8.1</version>
59       <scope>test</scope>
60     </dependency>
61       
62 <dependency>
63 <groupId>org.apache.maven.plugins</groupId>
64 <artifactId>maven-resources-plugin</artifactId>
65 <version>2.4.3</version>
66 </dependency>
67   
68   </dependencies>
69   <build>
70     <finalName>codegroup</finalName>
71   </build>
72 </project>
pom.xml

=====================================================================================================================

前提:简单记录下这2天配置Maven环境遇到的问题

环境:

jdk1.08

Maven3.6.0

eclipse

    网上有一大堆讲解,我就不重复了,简单说一下mvn -v弄好后再遇到的问题。

第一步:mvn -v:(验证配置成功入下图)

遇到的第一个问题 (mvn -v一直失败):

解决方案:按道理按照网上步骤不会出错,但是最终发现jdk错误,我之前用的jdk1.6,实际是1.8

下面也又相关视频配置

慕课网 https://www.imooc.com/learn/443

mvn -v成功后打开eclipse中pom.xml一直报错,也明白了maven没有完全配置好。

步骤二:将setting.xml加入路径(如何加入网上也有讲解,如果每次更改setting.xml,除了重新导入setting.xml外,还需要重启eclipse,在Maven Repositories里面的Global Repositories可以检测mirrors是否更新了

   遇到的第二个问题:

CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin

解决方案:settings.xml里面profiles没有写好,写好后去你的mirrors里面的repository里面查看jar包,重新下载,具体见如下博客

https://blog.csdn.net/u010452388/article/details/80789816

(我当时是将2.6删除了,然后再建立项目就相当于重新下载,然后就好了)

疑点:settings.xml里面需要修改的就是profiles和mirrors),mirrors按照网上说要改成aliyun或者别的,但是我弄了很多方案也还是Rebuild Index搞不好,不知道为什么,先给出来。

 1      <mirror>
 2             <id>alimaven</id>
 3             <mirrorOf>central</mirrorOf>
 4             <name>aliyun maven</name>
 5             <url>http://maven.aliyun.com/nexus/content/repositories/central/</url>
 6         </mirror>
 7         <mirror>
 8             <id>alimaven</id>
 9             <name>aliyun maven</name>
10             <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
11             <mirrorOf>central</mirrorOf>
12         </mirror>
13         <mirror>
14             <id>central</id>
15             <name>Maven Repository Switchboard</name>
16             <url>http://repo1.maven.org/maven2/</url>
17             <mirrorOf>central</mirrorOf>
18         </mirror>
19         <mirror>
20             <id>repo2</id>
21             <mirrorOf>central</mirrorOf>
22             <name>Human Readable Name for this Mirror.</name>
23             <url>http://repo2.maven.org/maven2/</url>
24         </mirror>
25         <mirror>
26             <id>ibiblio</id>
27             <mirrorOf>central</mirrorOf>
28             <name>Human Readable Name for this Mirror.</name>
29             <url>http://mirrors.ibiblio.org/pub/mirrors/maven2/</url>
30         </mirror>
31         <mirror>
32             <id>jboss-public-repository-group</id>
33             <mirrorOf>central</mirrorOf>
34             <name>JBoss Public Repository Group</name>
35             <url>http://repository.jboss.org/nexus/content/groups/public</url>
36         </mirror>
37         <mirror>
38             <id>google-maven-central</id>
39             <name>Google Maven Central</name>
40             <url>https://maven-central.storage.googleapis.com
41             </url>
42             <mirrorOf>central</mirrorOf>
43         </mirror>
44         <!-- 中央仓库在中国的镜像 -->
45         <mirror>
46             <id>maven.net.cn</id>
47             <name>oneof the central mirrors in china</name>
48             <url>http://maven.net.cn/content/groups/public/</url>
49             <mirrorOf>central</mirrorOf>
50         </mirror>
51   </mirrors>
mirror

 1 <profiles>
 2  
 3     <profile>
 4       <id>jdk-1.8</id>
 5       <activation>
 6         <activeByDefault>true</activeByDefault>
 7         <jdk>1.8</jdk>
 8       </activation>
 9       <properties>
10         <maven.compiler.source>1.8</maven.compiler.source>
11         <maven.compiler.target>1.8</maven.compiler.target>
12         <maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>
13       </properties>
14     </profile>
15   </profiles>

步骤三:继续报错

Could not resolve archetype org.apache.maven.archetypes:maven-archetype-webapp:1.0 from any of the configured repositories.

解决方案:

https://www.cnblogs.com/rever/p/7076596.html

我用的最后一个补充的方法,打开CMD即可,不用在意路径.jar包下载完

步骤四:eclipse不再报错,新建Maven  project也不再报错,新建项目如下面博客

https://www.cnblogs.com/lzx2509254166/p/7674455.html

我重新测试了一下,pom.xml里面没更改,什么都没变,一建立就能运行了,eclipse的Console窗口显示如下,建立Maven project即可,什么代码都不用加,然后项目没有红叉叉

总结:总体配置Maven环境过程如下:

1.mvn -v 成功

2.加入setting.xml(里面的东西写好)

3.新建Maven项目不报错(然后就算成功?网上也没看到什么附加内容,就算成功了吧,开始写springbboott项目)

疑点:mirrors那一块我试了各种mirror也没有成功Rebuild Index成功,看网上说这个功能是为了找jar包方便,对我用处目前不算特别大,先留下来吧。

转载于:https://www.cnblogs.com/meditation5201314/p/10244010.html

相关文章:

分布式存储(ceph)技能图谱(持续更新)

一下为个人结合其他人对分布式存储 所需的技能进行总结&#xff0c;绘制成如下图谱&#xff0c;方便针对性学习。 这里对分布式存储系统接触较多的是ceph,所以在分布式存储系统分支上偏向ceph的学习。 如有分类有问题或者分支不合理&#xff0c;欢迎大家批评指正&#xff0c;目…

android如何查看方法属于哪个类,Android Studio查看类中所有方法和属性

css-关于位置当你设置一个你想要相对的模块为relative 你这个模块为absolute 则你的这个absolute会相对relative的那个模块进行移动.微信公众平台自动回复wechatlib&period;jar的生成及wechatlib解析微信公众平台出来有一段时日了,官方提供的自动回复的接口调用大致是这么些…

读javascript高级程序设计03-函数表达式、闭包、私有变量

一、函数声明和函数表达式 定义函数有两种方式&#xff1a;函数声明和函数表达式。它们之间一个重要的区别是函数提升。 1.函数声明会进行函数提升&#xff0c;所以函数调用在函数声明之前也不会报错&#xff1a; test(); function test(){ alert(1); } 2.函数表达式不会进行函…

集成公司内部的多个子系统(兼容B/S和C/S),实现单点登录功能的多系统的统一入口功能...

有一句话也挺有意思的&#xff0c;一直在模仿但从未超越过&#xff0c;文章里的技术也都是相对简单的技术&#xff0c;但是实实在在能解决问题&#xff0c;提高效率。现在人都懒得瞎折腾&#xff0c;能多简单就多简单&#xff0c;谁都不希望总是做一些重复的工作&#xff0c;我…

mysql无法远程连接

在mysql的mysql数据库下&#xff1a; select user,host from user;(查看&#xff0c;没有本机的访问权限) grant all privileges on *.* to root"xxx.xxx.xxx.xxx" identified by "密码";(xx为本机ip,%为所有IP) flush privileges; select user,host from …

哈希表的分类,创建,查找 以及相关问题解决

总体的hash学习导图如下&#xff1a; 文章目录定义分类字符hash排序hash链式hash&#xff08;解决hash冲突&#xff09;创建链式hash查找指定数值STL map(hash)哈希分类 完整测试代码应用&#xff08;常见题目&#xff09;1. 回文字符串&#xff08;Longest Palindrome&#x…

android 自定义音乐圆形进度条,Android自定义View实现音频播放圆形进度条

本篇文章介绍自定义View配合属性动画来实现如下的效果实现思路如下&#xff1a;根据播放按钮的图片大小计算出圆形进度条的大小根据音频的时间长度计算出圆形进度条绘制的弧度通过Handler刷新界面来更新圆形进度条的进度具体实现过程分析&#xff1a;首先来看看自定义View中定义…

jsp error-page没有生效

1、首页检查web.xml中的配置&#xff0c;确保路径是正确的 <error-page> <error-code>404</error-code> <location>/error.jsp</location> </error-page> 2、然后再检查error.jsp文件内容是否有问题&#xff0c;比如只有<head>&…

CTO(首席技术官)

CTO&#xff08;首席技术官&#xff09;英文Chief Technology Officer&#xff0c;即企业内负责技术的最高负责人。这个名称在1980年代从美国开始时兴。起于做很多研究的大公司&#xff0c;如General Electric&#xff0c;AT&T&#xff0c;ALCOA&#xff0c;主要责任是将科…

把数组排成最小的数

题目 输入一个正整数数组&#xff0c;把数组里所有数字拼接起来排成一个数&#xff0c;打印能拼接出的所有数字中最小的一个。例如输入数组{3&#xff0c;32&#xff0c;321}&#xff0c;则打印出这三个数字能排成的最小数字为321323。 思路 一  需要找到字典序最小的哪个排列…

shell脚本自动执行,top命令无输出

shell脚本在系统启动时推后台自动执行&#xff0c;发现其中/usr/bin/top -n 1 -c -b -u ceph 命令并无输出 但是系统启动之后手动执行脚本&#xff0c;&推后台脚本中的top仍然能够正常输出&#xff0c;仅仅是系统发生重启&#xff0c;该功能就不生效了 stackoverflow 推荐…

0709 C语言常见误区----------函数指针问题

1.函数指针的定义 对于函数 void test(int a, int b){ // } 其函数指针类型是void (* ) (int , int)&#xff0c; 注意这里第一个括号不能少&#xff0c; 定义一个函数指针&#xff0c;void (* pfunc)(int , int) ,其中pfunc就是函数指针类型&#xff0c; 它指向的函数类型必须…

android 定时换图片,android 视频和图片切换并进行自动轮播

刚入android没多久&#xff0c;遇到的比较郁闷的问题就是子线程主线程的问题&#xff0c;更改UI界面&#xff0c;本想做一个图片的轮播但是比较简单&#xff0c;然后就试试实现视频跟图片切换播放进行不停的循环播放。也用过不少控件&#xff0c;但是知其然不知其所以然&#x…

Win8:Snap 实现

Win8允许分屏的操作&#xff0c;所以我们必须让我们App能对Snap模式视图做出反应&#xff0c;这样也便于通过Store的审核。如果项目中在Snap展现的功能不大&#xff0c;我们可以仅用一张logo代替&#xff0c;类似系统的商店应用。 我的项目实现效果&#xff1a; 实现思路是在你…

ping命令使用及其常用参数

PING (Packet Internet Groper)&#xff0c;因特网包探索器&#xff0c;用于测试网络连接量检查网络是否连通&#xff0c;可以很好地帮助我们分析和判定网络故障。Ping发送一个ICMP(Internet Control Messages Protocol&#xff09;即因特网信报控制协议&#xff1b;回声请求消…

g-gdb工具使用图谱(持续更新)

如下为整个GDB的学习导图

android bitmap 转drawable,android Drawable转换成Bitmap失败

错误代码&#xff1a;08-07 06:42:30.482 28497-28497/app.tianxiayou E/AndroidRuntime﹕ FATAL EXCEPTION: mainProcess: app.tianxiayou, PID: 28497java.lang.RuntimeException: Unable to start activity ComponentInfo{app.tianxiayou/app.tianxiayou.AppInfoActivity}: …

微软职位内部推荐-Software Development Engineer II

微软近期Open的职位:Job Title:Software Development EngineerIIDivision: Server & Tools Business - Commerce Platform GroupWork Location: Shanghai, ChinaAre you looking for a high impact project that involves processing of billions of dollars, hundreds of …

Lync与Exchange 2013 UM集成:Exchange 配置

有点长时间没有更新文章了&#xff0c;也是由于工作的原因确实忙不过来&#xff0c;好在博客上还有这么多朋友支持&#xff0c;非常的欣慰啊。很久没有给大家带来新东西&#xff0c;真的非常抱歉&#xff0c;今天跟大家带来的是Lync Server 2013与Exchange Server 2013统一消息…

「Java基本功」一文读懂Java内部类的用法和原理

内部类初探 一、什么是内部类&#xff1f; 内部类是指在一个外部类的内部再定义一个类。内部类作为外部类的一个成员&#xff0c;并且依附于外部类而存在的。内部类可为静态&#xff0c;可用protected和private修饰&#xff08;而外部类只能使用public和缺省的包访问权限&#…

从一致性hash到ceph crush算法演进图谱(持续更新)

参考文档&#xff1a; https://ceph.com/wp-content/uploads/2016/08/weil-crush-sc06.pdf Ceph剖析&#xff1a;数据分布之CRUSH算法与一致性Hash

[原]unity3d之http多线程异步资源下载

郑重声明&#xff1a;转载请注明出处 U_探索 本文诞生于乐元素面试过程&#xff0c;被面试官问到AssetBundle多线程异步下载时&#xff0c;愣了半天&#xff0c;同样也被深深的鄙视一回&#xff08;做了3年多u3d 这个都没用过&#xff09;&#xff0c;所以发誓要实现出来填补一…

android首页图片轮播效果,Android_Android自动播放Banner图片轮播效果,先看一下效果图支持本地图 - phpStudy...

Android自动播放Banner图片轮播效果先看一下效果图支持本地图片以及网络图片or本地网络混合。使用方式&#xff1a;android:id"id/banner"android:layout_width"match_parent"android:layout_height"230dip">核心代码&#xff1a;int length …

mongodb 入门

在NOSQL的多个数据库版本中,mongodb相对比较成熟,把学mongodb笔记整理在这&#xff0c;方便以后回顾。这笔记预计分三部分&#xff1a; 一&#xff0c;基础操作&#xff0c;二、增删改查详细操作&#xff0c;三、高级应用。一、在linux在安装mongodb&#xff0c;在linux下安装m…

springboot 学习笔记(三)

&#xff08;三&#xff09;用jar包启动springboot项目 1、首先需要在pom文件中添加依赖&#xff0c;spring-boot-starter-parent包含有打包的默认配置&#xff0c;如果要修改的话要可以进行重新定义&#xff0c;具体内容参考https://docs.spring.io/spring-boot/docs/2.1.1.RE…

搜索:深搜/广搜 获取岛屿数量

题目描述&#xff1a; 用一个二维数组代表一张地图&#xff0c;这张地图由字符“0”与字符“1”组 成&#xff0c;其中“0”字符代表水域&#xff0c;“1”字符代表小岛土地&#xff0c;小岛“1”被 水“0”所包围&#xff0c;当小岛土地“1”在水平和垂直方向相连接时&#xf…

2.4.4.1、Django新建APP(acounts)

$django-admin.py startapp accounts 在oss/accounts修改forms.py(新建)和views.py如下&#xff1a; 注&#xff1a;绿字部分为注释 views.py ################################################################ #codingutf-8 from django.core.urlresolvers import reverse f…

vue html引入资源dev下404,webpack vue 项目打包生成的文件,资源文件报404问题的修复方法(总结篇)...

最近在使用webpack vue做个人娱乐项目时&#xff0c;发现npm run build后&#xff0c;css js img静态资源文件均找不到路径&#xff0c;报404错误。。。网上查找了一堆解决办法&#xff0c;总结如下一、首先修改config目录下的index.js文件将其中build的配置项assetsPublicPat…

解决.net webservice的WebClient或HttpWebRequest首次连接缓慢问题

【编程环境】Visual Studio 2010, NET4.0 【开发语言】C#, 理论上VB.NET等依赖.NET Framework框架的语言均受此影响 【问题描述】 使用HttpWebRequest抓取网页内容,但首次请求总是莫名奇妙的阻塞在Request.GetResponse();上,不过一旦这次请求成功&#xff0c;后续的操作就很快了…

2019-1-11

unique的使用&#xff1a; 1. unique是把相邻的重复元素放到最后面。所以在对无序数列使用之前&#xff0c;需要用sort先排序。 2.unique的返回值是不重复区的的最后一个元素加一的地址。 sort(V.begin(), V.end() ); vector<int>::iterator end_unique unique&#xff…