Skip to content

Commit

Permalink
Demo fix
Browse files Browse the repository at this point in the history
  • Loading branch information
plyhun committed Sep 10, 2024
1 parent 6073be5 commit afb1b59
Show file tree
Hide file tree
Showing 7 changed files with 68 additions and 40 deletions.
26 changes: 21 additions & 5 deletions bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
<aws.sdk.version>2.16.83</aws.sdk.version>
<snakeyaml.version>1.30</snakeyaml.version>
<testcontainers.version>1.19.4</testcontainers.version>
<log4j.version>2.17.1</log4j.version>
</properties>

<!-- IMPORTANT: Always keep dependencies in-sync with mesh-plugin-parent pom in order to avoid duplicate libraries in shaded plugin jars -->
Expand Down Expand Up @@ -157,16 +158,31 @@
<groupId>org.apache.tika</groupId>
<artifactId>tika-parsers-standard-package</artifactId>
<version>${tika.version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.tika</groupId>
<artifactId>tika-core</artifactId>
<version>${tika.version}</version>
</dependency>
<dependency>
<groupId>org.apache.tika</groupId>
<artifactId>tika-parser-scientific-package</artifactId>
<version>${tika.version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>

<!-- Spring - bcrypt -->
Expand Down
22 changes: 14 additions & 8 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,14 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand All @@ -115,15 +123,13 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.tika</groupId>
<artifactId>tika-parser-scientific-package</artifactId>
<exclusions>
<exclusion>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;

import org.apache.cxf.helpers.IOUtils;
import org.apache.commons.io.IOUtils;

import com.gentics.mesh.Mesh;
import com.gentics.mesh.graphdb.OrientDBDatabase;
Expand Down Expand Up @@ -61,7 +62,7 @@ public void run() throws MalformedURLException, Exception {
VersionNumber parsedVersion = VersionNumber.parse(version);
if (parsedVersion != null && parsedVersion.compareTo(VersionNumber.parse("0.16.1")) >= 0) {
URL revisionFileUrl = new URL(BASE_PATH + version + "/" + "mesh-orientdb-" + version + "-revision.txt");
String hash = IOUtils.readStringFromStream(revisionFileUrl.openStream());
String hash = IOUtils.readLines(revisionFileUrl.openStream(), "UTF-8").stream().collect(Collectors.joining());
System.out.println("Found version {" + version + "} with hash {" + hash + "}");
Map<String, String> map = new HashMap<>();
map.put("version", version);
Expand Down
23 changes: 14 additions & 9 deletions plugin-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,14 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand All @@ -143,16 +151,13 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.tika</groupId>
<artifactId>tika-parser-scientific-package</artifactId>
<scope>provided</scope>
<exclusions>
<exclusion>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
Expand Down
22 changes: 14 additions & 8 deletions services/image-imgscalr/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand All @@ -54,15 +62,13 @@
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.tika</groupId>
<artifactId>tika-parser-scientific-package</artifactId>
<exclusions>
<exclusion>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP-java7</artifactId>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import static com.gentics.mesh.test.ClientHelper.call;
import static com.gentics.mesh.test.TestSize.FULL;
import static io.netty.handler.codec.http.HttpResponseStatus.UNAUTHORIZED;
import static org.apache.http.HttpHeaders.AUTHORIZATION;
import static org.assertj.core.api.Assertions.assertThat;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotEquals;
Expand Down Expand Up @@ -129,7 +128,7 @@ public void testBasicAuth() throws IOException {
Response response = client.newCall(new Request.Builder()
.get()
.url(String.format("http://%s:%s/api/v2/auth/login", "localhost", port()))
.header(AUTHORIZATION, "Basic " + base64("admin:admin"))
.header("Authorization", "Basic " + base64("admin:admin"))
.build()).execute();

assertThat(response.code()).isEqualTo(200);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,24 +10,19 @@
import java.net.URL;
import java.time.Duration;
import java.util.Optional;
import java.util.concurrent.TimeoutException;
import java.util.stream.IntStream;

import org.apache.http.HttpStatus;
import org.junit.After;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;

import com.gentics.mesh.core.db.Tx;
import com.gentics.mesh.core.rest.MeshEvent;
import com.gentics.mesh.core.rest.user.UserListResponse;
import com.gentics.mesh.etc.config.search.ElasticSearchOptions;
import com.gentics.mesh.test.MeshTestSetting;
import com.gentics.mesh.test.TestSize;
import com.gentics.mesh.test.context.AbstractMeshTest;
import com.gentics.mesh.test.helper.ExpectedEvent;

import io.vertx.core.http.HttpMethod;
import io.vertx.core.http.HttpServerOptions;
Expand Down Expand Up @@ -149,7 +144,7 @@ public void testResumeQueriesAfterBlackout() throws IOException, InterruptedExce
@Test
public void testResumeQueriesAfterGatewayTimeout() throws IOException, InterruptedException {
timeout = false;
maybeCustomStatus = Optional.of(HttpStatus.SC_GATEWAY_TIMEOUT);
maybeCustomStatus = Optional.of(504 /*SC_GATEWAY_TIMEOUT*/);
String json = getESText("userWildcard.es");
call(() -> client().searchUsers(json), INTERNAL_SERVER_ERROR);
// reset
Expand Down

0 comments on commit afb1b59

Please sign in to comment.