Remove deprecated stsId

Closes gh-820
This commit is contained in:
Stephane Nicoll 2019-02-11 12:46:00 +01:00
parent de15e826b8
commit c98f59e8f2
7 changed files with 5 additions and 29 deletions

View File

@ -100,7 +100,6 @@ initializr:
types:
- name: Maven POM
id: maven-build
sts-id: pom.xml
tags:
build: maven
format: build
@ -108,7 +107,6 @@ initializr:
action: /pom.xml
- name: Maven Project
id: maven-project
sts-id: starter.zip
tags:
build: maven
format: project
@ -116,7 +114,6 @@ initializr:
action: /starter.zip
- name: Gradle Config
id: gradle-build
sts-id: build.gradle
tags:
build: gradle
format: build
@ -124,7 +121,6 @@ initializr:
action: /build.gradle
- name: Gradle Project
id: gradle-project
sts-id: gradle.zip
tags:
build: gradle
format: project

View File

@ -29,9 +29,6 @@ public class Type extends DefaultMetadataElement implements Describable {
private String description;
@Deprecated
private String stsId;
private String action;
private final Map<String, String> tags = new LinkedHashMap<>();
@ -53,14 +50,6 @@ public class Type extends DefaultMetadataElement implements Describable {
this.description = description;
}
public String getStsId() {
return this.stsId;
}
public void setStsId(String stsId) {
this.stsId = stsId;
}
public String getAction() {
return this.action;
}

View File

@ -45,9 +45,8 @@ public class TypeCapability extends ServiceCapability<List<Type>>
* @return the Type or {@code null}
*/
public Type get(String id) {
return this.content.stream()
.filter((it) -> id.equals(it.getId()) || id.equals(it.getStsId()))
.findFirst().orElse(null);
return this.content.stream().filter((it) -> id.equals(it.getId())).findFirst()
.orElse(null);
}
/**

View File

@ -100,7 +100,6 @@ initializr:
types:
- name: Maven POM
id: maven-build
sts-id: pom.xml
tags:
build: maven
format: build
@ -108,7 +107,6 @@ initializr:
action: /pom.xml
- name: Maven Project
id: maven-project
sts-id: starter.zip
tags:
build: maven
format: project
@ -116,7 +114,6 @@ initializr:
action: /starter.zip
- name: Gradle Config
id: gradle-build
sts-id: build.gradle
tags:
build: gradle
format: build
@ -124,7 +121,6 @@ initializr:
action: /build.gradle
- name: Gradle Project
id: gradle-project
sts-id: gradle.zip
tags:
build: gradle
format: project

View File

@ -31,7 +31,6 @@
"name": "Maven POM",
"id": "maven-build",
"description": null,
"stsId": "pom.xml",
"action": "/pom.xml",
"tags": {
"build": "maven",

View File

@ -118,7 +118,8 @@ class MainControllerIntegrationTests
@Test
void gradleWarProject() {
downloadZip("/starter.zip?style=web&style=security&packaging=war&type=gradle.zip")
downloadZip(
"/starter.zip?style=web&style=security&packaging=war&type=gradle-project")
.isJavaWarProject().isGradleProject();
}

View File

@ -349,7 +349,6 @@
"description": null,
"id": "maven-build",
"name": "Maven POM",
"stsId": "pom.xml",
"tags": {
"build": "maven",
"format": "build"
@ -361,7 +360,6 @@
"description": null,
"id": "maven-project",
"name": "Maven Project",
"stsId": "starter.zip",
"tags": {
"build": "maven",
"format": "project"
@ -373,7 +371,6 @@
"description": null,
"id": "gradle-build",
"name": "Gradle Config",
"stsId": "build.gradle",
"tags": {
"build": "gradle",
"format": "build"
@ -385,7 +382,6 @@
"description": null,
"id": "gradle-project",
"name": "Gradle Project",
"stsId": "gradle.zip",
"tags": {
"build": "gradle",
"format": "project"