Merge remote-tracking branch 'origin' into 7.0.x

This commit is contained in:
William Cheng
2023-03-03 21:52:50 +08:00
10595 changed files with 418520 additions and 73194 deletions

View File

@@ -15,7 +15,7 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.7.0</version>
<version>2.7.6</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<build>
@@ -27,7 +27,7 @@
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-parent</artifactId>
<version>2021.0.1</version>
<version>2021.0.5</version>
<type>pom</type>
<scope>import</scope>
</dependency>
@@ -63,7 +63,7 @@
<dependency>
<groupId>org.openapitools</groupId>
<artifactId>jackson-databind-nullable</artifactId>
<version>0.2.2</version>
<version>0.2.6</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>

View File

@@ -25,7 +25,7 @@ import javax.annotation.Generated;
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
@Validated
@Api(value = "Pet", description = "Everything about your Pets")
@Api(value = "pet", description = "Everything about your Pets")
public interface PetApi {
/**
@@ -212,6 +212,8 @@ public interface PetApi {
* or Invalid ID supplied (status code 400)
* or Pet not found (status code 404)
* or Validation exception (status code 405)
* API documentation for the updatePet operation
* @see <a href="http://petstore.swagger.io/v2/doc/updatePet">Update an existing pet Documentation</a>
*/
@ApiOperation(
tags = { "pet" },

View File

@@ -25,7 +25,7 @@ import javax.annotation.Generated;
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
@Validated
@Api(value = "Store", description = "Access to Petstore orders")
@Api(value = "store", description = "Access to Petstore orders")
public interface StoreApi {
/**
@@ -87,7 +87,7 @@ public interface StoreApi {
/**
* GET /store/order/{orderId} : Find purchase order by ID
* For valid response try integer IDs with value &lt;&#x3D; 5 or &gt; 10. Other values will generated exceptions
* For valid response try integer IDs with value &lt;&#x3D; 5 or &gt; 10. Other values will generate exceptions
*
* @param orderId ID of pet that needs to be fetched (required)
* @return successful operation (status code 200)
@@ -98,7 +98,7 @@ public interface StoreApi {
tags = { "store" },
value = "Find purchase order by ID",
nickname = "getOrderById",
notes = "For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions",
notes = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions",
response = Order.class
)
@ApiResponses({

View File

@@ -26,7 +26,7 @@ import javax.annotation.Generated;
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
@Validated
@Api(value = "User", description = "Operations about user")
@Api(value = "user", description = "Operations about user")
public interface UserApi {
/**

View File

@@ -15,15 +15,6 @@ import org.springframework.security.oauth2.client.token.grant.implicit.ImplicitR
@EnableConfigurationProperties
public class ClientConfiguration {
@Value("${openapipetstore.security.apiKey.key:}")
private String apiKeyKey;
@Bean
@ConditionalOnProperty(name = "openapipetstore.security.apiKey.key")
public ApiKeyRequestInterceptor apiKeyRequestInterceptor() {
return new ApiKeyRequestInterceptor("header", "api_key", this.apiKeyKey);
}
@Bean
@ConditionalOnProperty("openapipetstore.security.petstoreAuth.client-id")
public OAuth2FeignRequestInterceptor petstoreAuthRequestInterceptor(OAuth2ClientContext oAuth2ClientContext) {
@@ -45,4 +36,13 @@ public class ClientConfiguration {
return details;
}
@Value("${openapipetstore.security.apiKey.key:}")
private String apiKeyKey;
@Bean
@ConditionalOnProperty(name = "openapipetstore.security.apiKey.key")
public ApiKeyRequestInterceptor apiKeyRequestInterceptor() {
return new ApiKeyRequestInterceptor("header", "api_key", this.apiKeyKey);
}
}

View File

@@ -43,7 +43,7 @@ public class Pet {
@JsonProperty("tags")
@Valid
private List<Tag> tags = null;
private List<@Valid Tag> tags = null;
/**
* pet status in the store
@@ -85,6 +85,23 @@ public class Pet {
@JsonProperty("status")
private StatusEnum status;
/**
* Default constructor
* @deprecated Use {@link Pet#Pet(String, List<String>)}
*/
@Deprecated
public Pet() {
super();
}
/**
* Constructor with only required parameters
*/
public Pet(String name, List<String> photoUrls) {
this.name = name;
this.photoUrls = photoUrls;
}
public Pet id(Long id) {
this.id = id;
return this;
@@ -166,7 +183,7 @@ public class Pet {
this.photoUrls = photoUrls;
}
public Pet tags(List<Tag> tags) {
public Pet tags(List<@Valid Tag> tags) {
this.tags = tags;
return this;
}
@@ -185,11 +202,11 @@ public class Pet {
*/
@Valid
@ApiModelProperty(value = "")
public List<Tag> getTags() {
public List<@Valid Tag> getTags() {
return tags;
}
public void setTags(List<Tag> tags) {
public void setTags(List<@Valid Tag> tags) {
this.tags = tags;
}