Skip to content

Commit

Permalink
javax -> jakarta.
Browse files Browse the repository at this point in the history
  • Loading branch information
mihxil committed Feb 13, 2024
1 parent cfe12ca commit 03b057e
Show file tree
Hide file tree
Showing 42 changed files with 107 additions and 108 deletions.
2 changes: 1 addition & 1 deletion client-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>nl.vpro.poms.api-clients</groupId>
<artifactId>api-client-parent</artifactId>
<version>7.12-SNAPSHOT</version>
<version>8.0-SNAPSHOT</version>
</parent>

<artifactId>client-core</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public static VersionResult getVersionFromSwagger(String baseUrl, String default
final URI url = URI.create(baseUrl + "/openapi.json");
try {
if (timeout == null) {
timeout = Duration.ofSeconds(3);
timeout = Duration.ofSeconds(30);
}
final ObjectMapper mapper = new ObjectMapper();
final JsonFactory factory = new JsonFactory();
Expand Down
2 changes: 1 addition & 1 deletion client-extras/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>nl.vpro.poms.api-clients</groupId>
<artifactId>api-client-parent</artifactId>
<version>7.12-SNAPSHOT</version>
<version>8.0-SNAPSHOT</version>
</parent>

<artifactId>client-extras</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
import java.util.*;
import java.util.function.Predicate;

import javax.inject.Inject;
import javax.ws.rs.core.Response;
import javax.xml.bind.JAXB;
import jakarta.inject.Inject;
import jakarta.ws.rs.core.Response;
import jakarta.xml.bind.JAXB;

import org.checkerframework.checker.nullness.qual.NonNull;
import org.checkerframework.checker.nullness.qual.Nullable;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import nl.vpro.api.client.frontend.NpoApiClients;
import nl.vpro.domain.api.SuggestResult;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import nl.vpro.domain.api.media.MediaRepository;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import nl.vpro.domain.api.media.*;
import nl.vpro.domain.api.profile.ProfileDefinition;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import nl.vpro.api.client.frontend.NpoApiClients;
import nl.vpro.domain.api.SuggestResult;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
import java.time.Instant;
import java.time.LocalDate;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import org.checkerframework.checker.nullness.qual.NonNull;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
import java.util.concurrent.ExecutionException;
import java.util.concurrent.TimeUnit;

import javax.inject.Inject;
import javax.inject.Named;
import javax.validation.constraints.NotNull;
import jakarta.inject.Inject;
import jakarta.inject.Named;
import jakarta.validation.constraints.NotNull;

import com.google.common.cache.*;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
import java.util.*;
import java.util.function.Supplier;

import javax.validation.constraints.NotNull;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import jakarta.validation.constraints.NotNull;
import jakarta.ws.rs.*;
import jakarta.ws.rs.core.Response;

import org.apache.commons.io.IOUtils;
import org.checkerframework.checker.nullness.qual.NonNull;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
import java.util.Optional;
import java.util.OptionalLong;

import javax.inject.Inject;
import javax.inject.Named;
import javax.validation.constraints.NotNull;
import jakarta.inject.Inject;
import jakarta.inject.Named;
import jakarta.validation.constraints.NotNull;


import nl.vpro.domain.media.support.ImageUrlService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@
import java.util.concurrent.*;
import java.util.function.*;

import javax.inject.Inject;
import javax.inject.Named;
import javax.validation.constraints.NotNull;
import javax.ws.rs.ProcessingException;
import javax.ws.rs.core.Response;
import jakarta.inject.Inject;
import jakarta.inject.Named;
import jakarta.validation.constraints.NotNull;
import jakarta.ws.rs.ProcessingException;
import jakarta.ws.rs.core.Response;

import org.checkerframework.checker.nullness.qual.NonNull;
import org.checkerframework.checker.nullness.qual.Nullable;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
import java.util.*;
import java.util.function.Supplier;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

import com.google.common.collect.Lists;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

/**
* @author Michiel Meeuwissen
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import java.io.IOException;
import java.io.InputStream;

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

import nl.vpro.api.rs.v3.page.PageRestService;
import nl.vpro.domain.api.page.PageForm;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
import java.util.Optional;
import java.util.function.Function;

import javax.inject.Inject;
import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import javax.ws.rs.NotFoundException;
import javax.ws.rs.ProcessingException;
import javax.ws.rs.core.MultivaluedMap;
import javax.ws.rs.core.Response;
import jakarta.inject.Inject;
import jakarta.validation.Valid;
import jakarta.validation.constraints.NotNull;
import jakarta.ws.rs.NotFoundException;
import jakarta.ws.rs.ProcessingException;
import jakarta.ws.rs.core.MultivaluedMap;
import jakarta.ws.rs.core.Response;

import org.apache.commons.lang3.exception.ExceptionUtils;
import org.apache.http.impl.execchain.RequestAbortedException;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package nl.vpro.api.client.utils;

import javax.inject.Inject;
import javax.inject.Named;
import jakarta.inject.Inject;
import jakarta.inject.Named;

/**
* @author Michiel Meeuwissen
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import lombok.Getter;

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

/**
* @author Michiel Meeuwissen
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import java.io.InputStream;
import java.util.*;

import javax.inject.Inject;
import javax.inject.Named;
import javax.xml.bind.JAXB;
import jakarta.inject.Inject;
import jakarta.inject.Named;
import jakarta.xml.bind.JAXB;

import nl.vpro.domain.api.profile.*;
import nl.vpro.domain.media.MediaObject;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import java.net.URL;
import java.time.Instant;

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

import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
import java.time.Instant;
import java.util.*;

import javax.ws.rs.client.Client;
import javax.ws.rs.core.*;
import jakarta.ws.rs.client.Client;
import jakarta.ws.rs.core.*;

import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.time.StopWatch;
Expand Down Expand Up @@ -284,7 +284,7 @@ public void badRequest() {
/*String seriesRef = getSeriesRef(util.getClients().getMediaService().load("VPWON_1229797", null));
System.out.println("" + seriesRef);*/
System.out.println(util.getClients().getMediaService().findDescendants(new MediaForm(), "POMS_S_VPRO_522965", "vpro", "title,description,image", 0L, 1000).asList());
}).isInstanceOf(javax.ws.rs.NotFoundException.class);
}).isInstanceOf(jakarta.ws.rs.NotFoundException.class);
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

import java.io.StringReader;

import javax.ws.rs.core.MediaType;
import javax.xml.bind.JAXB;
import jakarta.ws.rs.core.MediaType;
import jakarta.xml.bind.JAXB;

import org.junit.jupiter.api.*;

Expand Down
2 changes: 1 addition & 1 deletion frontend-api-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>nl.vpro.poms.api-clients</groupId>
<artifactId>api-client-parent</artifactId>
<version>7.12-SNAPSHOT</version>
<version>8.0-SNAPSHOT</version>
</parent>

<artifactId>frontend-api-client</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
import java.net.URI;
import java.util.Map;

import javax.ws.rs.client.ClientRequestContext;
import javax.ws.rs.client.ClientRequestFilter;
import javax.ws.rs.core.MultivaluedMap;
import jakarta.ws.rs.client.ClientRequestContext;
import jakarta.ws.rs.client.ClientRequestFilter;
import jakarta.ws.rs.core.MultivaluedMap;

import org.slf4j.*;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
import java.util.stream.Collectors;
import java.util.stream.Stream;

import javax.inject.Inject;
import javax.inject.Named;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.MultivaluedMap;
import jakarta.inject.Inject;
import jakarta.inject.Named;
import jakarta.ws.rs.core.MediaType;
import jakarta.ws.rs.core.MultivaluedMap;

import org.jboss.resteasy.client.jaxrs.ResteasyClientBuilder;
import org.meeuw.functional.TriFunction;
Expand Down Expand Up @@ -98,7 +98,7 @@ public class NpoApiClients extends AbstractApiClient {

@SuppressWarnings({"SpringAutowiredFieldsWarningInspection", "unused", "OptionalUsedAsFieldOrParameterType"})
@Named
public static class Provider implements javax.inject.Provider<NpoApiClients> {
public static class Provider implements jakarta.inject.Provider<NpoApiClients> {
@Inject
@Named("npo-api.baseUrl")
String baseUrl;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
import java.lang.annotation.Annotation;
import java.lang.reflect.*;

import javax.ws.rs.QueryParam;
import javax.ws.rs.WebApplicationException;
import jakarta.ws.rs.QueryParam;
import jakarta.ws.rs.WebApplicationException;

import static nl.vpro.domain.api.Constants.*;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
package nl.vpro.api.client.frontend;

import jakarta.annotation.Priority;
import jakarta.ws.rs.client.*;
import jakarta.ws.rs.core.HttpHeaders;
import lombok.extern.slf4j.Slf4j;

import java.lang.reflect.Method;
import java.util.HashSet;
import java.util.Set;

import javax.annotation.Priority;
import javax.ws.rs.client.*;
import javax.ws.rs.core.HttpHeaders;

import nl.vpro.api.rs.v3.media.MediaRestService;
import nl.vpro.api.rs.v3.page.PageRestService;
import nl.vpro.jmx.CountAspect;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
import java.time.*;
import java.util.Locale;

import javax.ws.rs.*;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import jakarta.ws.rs.*;
import jakarta.ws.rs.core.MediaType;
import jakarta.ws.rs.core.Response;

import org.apache.commons.io.IOUtils;
import org.jboss.resteasy.client.jaxrs.ClientHttpEngine;
Expand Down Expand Up @@ -310,7 +310,7 @@ public void testTimeout() {
.httpEngine(httpClient);
Response response = builder.build().target(url).request().get();
log.info("{}", response);
}).isInstanceOf(javax.ws.rs.ProcessingException.class);
}).isInstanceOf(jakarta.ws.rs.ProcessingException.class);
}


Expand All @@ -324,7 +324,7 @@ public void testTimeoutSocket() {
Response response = builder.build().target(url).request().get();
assertThat(response.getStatus()).isEqualTo(200);
log.info(response.readEntity(String.class));
}).isInstanceOf(javax.ws.rs.ProcessingException.class);
}).isInstanceOf(jakarta.ws.rs.ProcessingException.class);

}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package nl.vpro.api.client.frontend;

import javax.inject.Inject;
import jakarta.inject.Inject;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

import lombok.extern.slf4j.Slf4j;

import javax.ws.rs.*;
import javax.ws.rs.core.MediaType;
import jakarta.ws.rs.*;
import jakarta.ws.rs.core.MediaType;

import org.jboss.resteasy.client.jaxrs.ResteasyClientBuilder;
import org.jboss.resteasy.client.jaxrs.cache.BrowserCacheFeature;
Expand Down
Loading

0 comments on commit 03b057e

Please sign in to comment.