From issues-return-96868-archive-asf-public=cust-asf.ponee.io@ignite.apache.org Wed Jun 26 14:34:02 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 0107918064D for ; Wed, 26 Jun 2019 16:34:01 +0200 (CEST) Received: (qmail 41368 invoked by uid 500); 26 Jun 2019 14:34:01 -0000 Mailing-List: contact issues-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list issues@ignite.apache.org Received: (qmail 41359 invoked by uid 99); 26 Jun 2019 14:34:01 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Jun 2019 14:34:01 +0000 Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 729CAE2E29 for ; Wed, 26 Jun 2019 14:34:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 2FD8225807 for ; Wed, 26 Jun 2019 14:34:00 +0000 (UTC) Date: Wed, 26 Jun 2019 14:34:00 +0000 (UTC) From: "Ilya Kasnacheev (JIRA)" To: issues@ignite.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (IGNITE-8772) WebSessionFilter does not work with jetty 9.4 anymore MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/IGNITE-8772?page=3Dcom.atlassi= an.jira.plugin.system.issuetabpanels:all-tabpanel ] Ilya Kasnacheev updated IGNITE-8772: ------------------------------------ Reviewer: Ilya Kasnacheev > WebSessionFilter does not work with jetty 9.4 anymore > ----------------------------------------------------- > > Key: IGNITE-8772 > URL: https://issues.apache.org/jira/browse/IGNITE-8772 > Project: Ignite > Issue Type: Bug > Components: websession > Affects Versions: 2.5 > Environment: * jetty-distribution-9.4.10.v20180503 > * ignite 2.5.0 > Reporter: Michael Bierwirth > Assignee: Saikat Maitra > Priority: Blocker > Time Spent: 10m > Remaining Estimate: 0h > > Jetty adds a workername suffix to the session cookie, using . as delimete= r: > {{SESSIONID.node0}} > =C2=A0 > In doFilterV2 the requested sessionid is read from cookie, which contains= the suffix: > =C2=A0 > {code:java} > private String doFilterV2(HttpServletRequest httpReq, ServletResponse res= , FilterChain chain) > throws IOException, ServletException, CacheException { > WebSessionV2 cached =3D null;String sesId =3D httpReq.getRequestedSession= Id(); > {code} > =C2=A0 > This id will never be found in the cache, because the cache key for new s= essions is just the part before the dot. > =C2=A0 > This is/may be fixed, by adding another session id transformer in the ini= t method. For example: > =C2=A0 > {code:java} > if (srvInfo !=3D null && srvInfo.contains("jetty")) { > sesIdTransformer =3D s -> { > int idx =3D s.indexOf('.'); > if (idx < 0 || idx =3D=3D s.length() - 1) { > return s; > } > 2 return s.substring(0, idx); > }; > } > {code} > =C2=A0 > =C2=A0 -- This message was sent by Atlassian JIRA (v7.6.3#76005)