Answer the question
In order to leave comments, you need to log in
Java. Spring. Embedded tomcat
Good day.
I ran into a project build problem. When removing dependencies, fails to download org.apache.tomcat.embed:tomcat-embed-core:7.0.47, response code 401 (Unauthorized).
Error log
Could not resolve all dependencies for configuration ':compile'.
> Could not resolve org.apache.tomcat.embed:tomcat-embed-core:7.0.47.
Required by:
:RESTExample:unspecified > org.springframework.boot:spring-boot-starter-web:1.0.0.RC1 > org.springframework.boot:spring-boot-starter-tomcat:1.0.0.RC1
> Could not GET 'http://repo.spring.io/libs-snapshot/org/apache/tomcat/embed/tomcat-embed-core/7.0.47/tomcat-embed-core-7.0.47.pom'. Received status code 401 from server: Unauthorized
> Could not resolve org.apache.tomcat.embed:tomcat-embed-logging-juli:7.0.47.
Required by:
:RESTExample:unspecified > org.springframework.boot:spring-boot-starter-web:1.0.0.RC1 > org.springframework.boot:spring-boot-starter-tomcat:1.0.0.RC1
> Could not GET 'http://repo.spring.io/libs-snapshot/org/apache/tomcat/embed/tomcat-embed-logging-juli/7.0.47/tomcat-embed-logging-juli-7.0.47.pom'. Received status code 401 from server: Unauthorized
buildscript {
repositories {
maven { url "http://repo.spring.io/libs-snapshot" }
mavenLocal()
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:1.0.0.RC1"
}
}
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'spring-boot'
jar {
baseName = 'gs-rest-service'
version = '0.1.0'
}
repositories {
mavenLocal()
maven { url "http://repo.spring.io/libs-snapshot" }
}
dependencies {
compile("org.springframework.boot:spring-boot-starter-web:1.0.0.RC1")
compile("com.fasterxml.jackson.core:jackson-databind")
testCompile("junit:junit:4.11")
}
task wrapper(type: Wrapper) {
gradleVersion = '1.8'
}
Answer the question
In order to leave comments, you need to log in
Curiously, the link
everything is quite accessible. Although, I noticed that there are jsession cookies in the request headers.
Whether it is important or not for the turnip authorization mechanisms - xs.
Plus, whenever I see a repetition of something in the code / config, there is a feeling of "not quite clean".
Your definition of repositories is duplicated. Is this ok for gradle? (sorry if I hurt your sense of beauty with my noob question).
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question