Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

Flpath 530 rebase on upgraded-spring #487

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions hack/manifests/backstage/app-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,20 +63,22 @@ proxy:
changeOrigin: true
redirect: follow
cache: 'no-cache'
allowedHeaders:
- Authorization
headers:
Content-Type: 'application/json'
accept: 'application/json'
Authorization: 'Basic dGVzdDp0ZXN0'

'/parodos-notifications':
target: 'http://notification-service:8080/api/v1'
changeOrigin: true
redirect: follow
cache: 'no-cache'
allowedHeaders:
- Authorization
headers:
Content-Type: 'application/json'
accept: 'application/json'
Authorization: 'Basic dGVzdDp0ZXN0'

# Reference documentation http://backstage.io/docs/features/techdocs/configuration
# Note: After experimenting with basic setup, use CI/CD to generate docs
Expand Down
2 changes: 1 addition & 1 deletion notification-service-sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ Class | Method | HTTP request | Description
- [NotificationRecordResponseDTO](docs/NotificationRecordResponseDTO.md)
- [PageNotificationRecordResponseDTO](docs/PageNotificationRecordResponseDTO.md)
- [PageableObject](docs/PageableObject.md)
- [Sort](docs/Sort.md)
- [SortObject](docs/SortObject.md)


<a id="documentation-for-authorization"></a>
Expand Down
8 changes: 4 additions & 4 deletions notification-service-sdk/api/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ paths:
minimum: 1
type: integer
style: form
- description: "Sorting criteria in the format: property(,asc|desc). Default\
- description: "Sorting criteria in the format: property,(asc|desc). Default\
\ sort order is ascending. Multiple sort criteria are supported."
explode: true
in: query
Expand Down Expand Up @@ -398,7 +398,7 @@ components:
format: int32
type: integer
sort:
$ref: '#/components/schemas/Sort'
$ref: '#/components/schemas/SortObject'
totalElements:
format: int64
type: integer
Expand Down Expand Up @@ -430,11 +430,11 @@ components:
paged:
type: boolean
sort:
$ref: '#/components/schemas/Sort'
$ref: '#/components/schemas/SortObject'
unpaged:
type: boolean
type: object
Sort:
SortObject:
example:
unsorted: true
sorted: true
Expand Down
4 changes: 2 additions & 2 deletions notification-service-sdk/docs/NotificationRecordApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ public class Example {
NotificationRecordApi apiInstance = new NotificationRecordApi(defaultClient);
Integer page = 0; // Integer | Zero-based page index (0..N)
Integer size = 100; // Integer | The size of the page to be returned
List<String> sort = Arrays.asList(); // List<String> | Sorting criteria in the format: property(,asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
List<String> sort = Arrays.asList(); // List<String> | Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported.
String state = "ARCHIVED"; // String |
String searchTerm = "searchTerm_example"; // String |
try {
Expand All @@ -181,7 +181,7 @@ public class Example {
|------------- | ------------- | ------------- | -------------|
| **page** | **Integer**| Zero-based page index (0..N) | [optional] [default to 0] |
| **size** | **Integer**| The size of the page to be returned | [optional] [default to 100] |
| **sort** | [**List&lt;String&gt;**](String.md)| Sorting criteria in the format: property(,asc|desc). Default sort order is ascending. Multiple sort criteria are supported. | [optional] |
| **sort** | [**List&lt;String&gt;**](String.md)| Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. | [optional] |
| **state** | **String**| | [optional] [enum: ARCHIVED, UNREAD] |
| **searchTerm** | **String**| | [optional] |

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
|**numberOfElements** | **Integer** | | [optional] |
|**pageable** | [**PageableObject**](PageableObject.md) | | [optional] |
|**size** | **Integer** | | [optional] |
|**sort** | [**Sort**](Sort.md) | | [optional] |
|**sort** | [**SortObject**](SortObject.md) | | [optional] |
|**totalElements** | **Long** | | [optional] |
|**totalPages** | **Integer** | | [optional] |

Expand Down
2 changes: 1 addition & 1 deletion notification-service-sdk/docs/PageableObject.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
|**pageNumber** | **Integer** | | [optional] |
|**pageSize** | **Integer** | | [optional] |
|**paged** | **Boolean** | | [optional] |
|**sort** | [**Sort**](Sort.md) | | [optional] |
|**sort** | [**SortObject**](SortObject.md) | | [optional] |
|**unpaged** | **Boolean** | | [optional] |


Expand Down
15 changes: 0 additions & 15 deletions notification-service-sdk/docs/Sort.md

This file was deleted.

2 changes: 2 additions & 0 deletions notification-service-sdk/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,8 @@
<addCompileSourceRoot>true</addCompileSourceRoot>
<enablePostProcessFile>true</enablePostProcessFile>
<configOptions>
<useSpringBoot3>true</useSpringBoot3>
<useJakartaEe>true</useJakartaEe>
<hideGenerationTimestamp>true</hideGenerationTimestamp>
<basePackage>com.redhat.parodos.notification.sdk</basePackage>
<configPackage>com.redhat.parodos.notification.sdk.configuration</configPackage>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,20 +28,42 @@
import java.security.cert.Certificate;
import java.security.cert.CertificateException;
import java.security.cert.CertificateFactory;
import java.security.cert.X509Certificate;
import java.text.DateFormat;
import java.util.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Objects;
import java.util.concurrent.TimeUnit;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

import javax.net.ssl.*;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.KeyManager;
import javax.net.ssl.SSLContext;
import javax.net.ssl.SSLSession;
import javax.net.ssl.TrustManager;
import javax.net.ssl.TrustManagerFactory;
import javax.net.ssl.X509TrustManager;

import com.redhat.parodos.notification.sdk.api.auth.ApiKeyAuth;
import com.redhat.parodos.notification.sdk.api.auth.Authentication;
import com.redhat.parodos.notification.sdk.api.auth.HttpBasicAuth;
import okhttp3.*;
import okhttp3.Call;
import okhttp3.Callback;
import okhttp3.Headers;
import okhttp3.Interceptor;
import okhttp3.MediaType;
import okhttp3.MultipartBody;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.RequestBody;
import okhttp3.Response;
import okhttp3.internal.http.HttpMethod;
import okhttp3.internal.tls.OkHostnameVerifier;
import okhttp3.logging.HttpLoggingInterceptor;
Expand Down Expand Up @@ -499,10 +521,9 @@ public ApiClient setDebugging(boolean debugging) {
* The path of temporary folder used to store downloaded files from endpoints with
* file response. The default value is <code>null</code>, i.e. using the system's
* default temporary folder.
*
* @return Temporary folder path
* @see <a href=
* "https://docs.oracle.com/javase/7/docs/api/java/nio/file/Files.html#createTempFile(java.lang.String,%20java.lang.String,%20java.nio.file.attribute.FileAttribute...)">createTempFile</a>
* @return Temporary folder path
*/
public String getTempFolderPath() {
return tempFolderPath;
Expand Down Expand Up @@ -607,7 +628,7 @@ else if (param instanceof Collection) {
/**
* Formats the specified query parameter to a list containing a single {@code Pair}
* object.
*
* <p>
* Note that {@code value} must not be a collection.
* @param name The name of the parameter.
* @param value The value of the parameter.
Expand All @@ -628,7 +649,7 @@ public List<Pair> parameterToPair(String name, Object value) {
/**
* Formats the specified collection query parameters to a list of {@code Pair}
* objects.
*
* <p>
* Note that the values of each of the returned Pair objects are percent-encoded.
* @param collectionFormat The collection format of the parameter.
* @param name The name of the parameter.
Expand Down Expand Up @@ -897,9 +918,9 @@ else if (obj instanceof String) {
/**
* Download file from the given response.
* @param response An instance of the Response object
* @return Downloaded file
* @throws com.redhat.parodos.notification.sdk.api.ApiException If fail to read file
* content from response and write to disk
* @return Downloaded file
*/
public File downloadFileFromResponse(Response response) throws ApiException {
try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
* </p>
*/
@SuppressWarnings("serial")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ApiException extends Exception {

private int code = 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

package com.redhat.parodos.notification.sdk.api;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class Configuration {

public static final String VERSION = "1.0.20-SNAPSHOT";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ private static Class getClassByDiscriminator(Map classByDiscriminatorValue, Stri
gsonBuilder.registerTypeAdapterFactory(
new com.redhat.parodos.notification.sdk.model.PageableObject.CustomTypeAdapterFactory());
gsonBuilder.registerTypeAdapterFactory(
new com.redhat.parodos.notification.sdk.model.Sort.CustomTypeAdapterFactory());
new com.redhat.parodos.notification.sdk.model.SortObject.CustomTypeAdapterFactory());
gson = gsonBuilder.create();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ public okhttp3.Call deleteNotificationAsync(UUID id, final ApiCallback<Void> _ca
* Build call for getNotifications
* @param page Zero-based page index (0..N) (optional, default to 0)
* @param size The size of the page to be returned (optional, default to 100)
* @param sort Sorting criteria in the format: property(,asc|desc). Default sort order
* @param sort Sorting criteria in the format: property,(asc|desc). Default sort order
* is ascending. Multiple sort criteria are supported. (optional)
* @param state (optional)
* @param searchTerm (optional)
Expand Down Expand Up @@ -620,7 +620,7 @@ private okhttp3.Call getNotificationsValidateBeforeCall(Integer page, Integer si
* Return a list of notification records for the user
* @param page Zero-based page index (0..N) (optional, default to 0)
* @param size The size of the page to be returned (optional, default to 100)
* @param sort Sorting criteria in the format: property(,asc|desc). Default sort order
* @param sort Sorting criteria in the format: property,(asc|desc). Default sort order
* is ascending. Multiple sort criteria are supported. (optional)
* @param state (optional)
* @param searchTerm (optional)
Expand Down Expand Up @@ -667,7 +667,7 @@ public PageNotificationRecordResponseDTO getNotifications(Integer page, Integer
* Return a list of notification records for the user
* @param page Zero-based page index (0..N) (optional, default to 0)
* @param size The size of the page to be returned (optional, default to 100)
* @param sort Sorting criteria in the format: property(,asc|desc). Default sort order
* @param sort Sorting criteria in the format: property,(asc|desc). Default sort order
* is ascending. Multiple sort criteria are supported. (optional)
* @param state (optional)
* @param searchTerm (optional)
Expand Down Expand Up @@ -715,7 +715,7 @@ public ApiResponse<PageNotificationRecordResponseDTO> getNotificationsWithHttpIn
* Return a list of notification records for the user (asynchronously)
* @param page Zero-based page index (0..N) (optional, default to 0)
* @param size The size of the page to be returned (optional, default to 100)
* @param sort Sorting criteria in the format: property(,asc|desc). Default sort order
* @param sort Sorting criteria in the format: property,(asc|desc). Default sort order
* is ascending. Multiple sort criteria are supported. (optional)
* @param state (optional)
* @param searchTerm (optional)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

package com.redhat.parodos.notification.sdk.api;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class Pair {

private String name = "";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import java.util.Collection;
import java.util.Iterator;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class StringUtil {

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.redhat.parodos.notification.sdk.api.ApiException;
import com.redhat.parodos.notification.sdk.api.Pair;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ApiKeyAuth implements Authentication {

private final String location;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.redhat.parodos.notification.sdk.api.ApiException;
import com.redhat.parodos.notification.sdk.api.Pair;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class HttpBearerAuth implements Authentication {

private final String scheme;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
import java.util.Map;
import java.util.Objects;

import javax.ws.rs.core.GenericType;
import jakarta.ws.rs.core.GenericType;

//import com.fasterxml.jackson.annotation.JsonValue;

/**
* Abstract class for oneOf,anyOf schemas defined in OpenAPI spec
*/
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public abstract class AbstractOpenApiSchema {

// store the actual instance of the schema/object
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
/**
* ErrorMessageDTO
*/
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ErrorMessageDTO {

public static final String SERIALIZED_NAME_DATE = "date";
Expand Down Expand Up @@ -64,7 +64,7 @@ public ErrorMessageDTO date(Date date) {
* Get date
* @return date
**/
@javax.annotation.Nullable
@jakarta.annotation.Nullable
public Date getDate() {
return date;
}
Expand All @@ -83,7 +83,7 @@ public ErrorMessageDTO description(String description) {
* Get description
* @return description
**/
@javax.annotation.Nullable
@jakarta.annotation.Nullable
public String getDescription() {
return description;
}
Expand All @@ -102,7 +102,7 @@ public ErrorMessageDTO message(String message) {
* Get message
* @return message
**/
@javax.annotation.Nullable
@jakarta.annotation.Nullable
public String getMessage() {
return message;
}
Expand Down
Loading
Loading