Skip to content

Commit

Permalink
Try to fix conditional matrix huild
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasdarimont committed Jul 12, 2023
1 parent 6a55ad5 commit f5d4db6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
restore-keys: ${{ runner.os }}-maven-${{ matrix.env.KEYCLOAK_VERSION }}

- name: Adjust sources for Keycloak Versions < 22.0.0
if: ${{ matrix.env.KEYCLOAK_VERSION < "22.0.0"}}
if: matrix.env.KEYCLOAK_VERSION < "22.0.0"
run: |
find . -name "*.java" -type f -print0 | xargs -0 sed -i 's/jakarta.ws./javax.ws./g';
echo "RESTEASY_BACKPORT=-Dresteasy.version=4.7.7.Final" >> $GITHUB_ENV
Expand Down Expand Up @@ -158,7 +158,7 @@ jobs:
restore-keys: ${{ runner.os }}-${{ matrix.java }}-maven-build-pom

- name: Adjust sources for Keycloak Versions < 22.0.0
if: ${{ matrix.env.KEYCLOAK_VERSION < "22.0.0"}}
if: matrix.env.KEYCLOAK_VERSION < "22.0.0"
run: |
find . -name "*.java" -type f -print0 | xargs -0 sed -i 's/jakarta.ws./javax.ws./g';
echo "RESTEASY_BACKPORT=-Dresteasy.version=4.7.7.Final" >> $GITHUB_ENV
Expand Down Expand Up @@ -191,7 +191,7 @@ jobs:
${{ runner.os }}-maven-keycloak-legacy
- name: Adjust sources for Keycloak Versions < 22.0.0
if: ${{ matrix.env.KEYCLOAK_VERSION < "22.0.0"}}
if: matrix.env.KEYCLOAK_VERSION < "22.0.0"
run: |
find . -name "*.java" -type f -print0 | xargs -0 sed -i 's/jakarta.ws./javax.ws./g';
echo "RESTEASY_BACKPORT=-Dresteasy.version=4.7.7.Final" >> $GITHUB_ENV
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@
public class CookieClientFilter implements ClientRequestFilter, ClientResponseFilter {

/**
* Hold the additional cookies across mutliple interactions in the same thread.
* Hold the additional cookies across multiple interactions in the same thread.
*/
private static final ThreadLocal<Map<String, String>> cookies = ThreadLocal.withInitial(HashMap::new);
private final ThreadLocal<Map<String, String>> cookies = ThreadLocal.withInitial(HashMap::new);

@Override
public void filter(ClientRequestContext clientRequestContext) {
Expand All @@ -49,9 +49,7 @@ public void filter(ClientRequestContext clientRequestContext) {

@Override
public void filter(ClientRequestContext requestContext, ClientResponseContext responseContext) {

cookies.remove(); // clear dangling cookies

cookies.remove();
responseContext.getCookies().forEach((name, cookie) -> cookies.get().put(name, String.format("%s=%s",
cookie.toCookie().getName(),
cookie.toCookie().getValue()
Expand Down

0 comments on commit f5d4db6

Please sign in to comment.