関連クエリが削除できない

担当者様

FESS(13.16.0)において関連クエリの削除ができない状況です。
事象としては、FESS(13.8.1)からFESS(13.16.0)にアップグレード後、
不要になった関連クエリをブラウザ上から削除したいのですが、
詳細画面に遷移しようとすると400エラーが発生いたします。
※FESS(13.8.1)においても同様の事象が発生

上記、関連クエリをクリックすると400エラーが発生します。

400エラーとなり削除できない関連クエリを削除する方法をご教示いただけますでしょうか?
APIなどがございましたらご教示いただきたいです。

400エラー画面

fess.logかserver.logには何が出力されているでしょうか?何も表示されていない場合は、デバッグログで確認すると良いと思います。

ご確認いただきありがとうございます。

デバッグログを有効化しているのですが、なにも出力されない状況です。

デバッグログについて以下の設定をしているのですが、正しいでしょうか?
対象ファイル:fess.in.bat
対象箇所:「set FESS_JAVA_OPTS=%FESS_JAVA_OPTS% -Dfess.log.level=debug」 ※コメントアウトを外す

特定の関連クエリを削除したいのですが、
一旦、関連クエリをまっさらにしたいので、初期化する方法でも問題ありません。

画面に関するログレベルは管理画面の全般で変更できます。

ご返答いただきありがとうございます。

以下のログが出力されました。
原因解決についてご教示いただけますと幸いです。

2022-03-23 11:20:15,412 [http-nio-8080-exec-6] DEBUG #flow ...Redirecting to /admin/relatedquery/
2022-03-23 11:20:15,415 [http-nio-8080-exec-6] DEBUG 
  responseClass=org.apache.catalina.connector.ResponseFacade ; committed=true
  ; httpStatus=302 ; contentType=null ; locale=ja_JP
  [header] Access-Control-Allow-Credentials=true
  [header] Access-Control-Allow-Headers=Origin, Content-Type, Accept, Authorization, X-Requested-With
  [header] Access-Control-Allow-Methods=GET, POST, OPTIONS, DELETE, PUT
  [header] Access-Control-Allow-Origin=*
  [header] Access-Control-Max-Age=3600
  [header] Location=/admin/relatedquery/
  [header] Set-Cookie=JSESSIONID=F604F005FBED8327BD43FB814DCDA96F; Path=/; HttpOnly
  [request] VirtualHostValue=
  [request] lastaflute.action.ACTION_RUMTIME=runtime:{/login/, public HtmlResponse LoginAction@login(LoginForm), pathParam:{{}}, HtmlResponse:{redirect:{/admin/relatedquery/, INNER}}, display=[searchLogSupport, favoriteSupport, thumbnailSupport, popularWords]}
  [request] lastaflute.action.FIRST_SUBMITTED_MARK=java.lang.Object@784c7744
  [request] lastaflute.action.USER_LOCALE=ja
  [request] lastaflute.config.ACTION_EXECUTE=execute:{public HtmlResponse LoginAction@login(LoginForm), urlPattern:{login, ^login$}}@2f2823b8
  [request] lastaflute.dbflute.SQL_COUNT={total=0}
  [request] login_loginAction=org.codelibs.fess.app.web.login.LoginAction@6e6461b8
  [request] login_loginAction_login_Form=VirtualForm:{formMeta:{login_loginAction_login_Form, org.codelibs.fess.app.web.login.LoginForm, props=3}, realForm=org.codelibs.fess.app.web.login.LoginForm@2af8bd8a}@579cfcea
  [request] userRoles=[1guest, Rguest]
  [session] lastaflute.action.USER_BEAN.FessUserBean={userId=admin, sync=2022/03/23 11:20:15}@1bc0dd37
  [session] lastaflute.action.USER_LOCALE=ja
  [session] relatedQueryPager=org.codelibs.fess.app.pager.RelatedQueryPager@4c6af3bf
* * * * * * * * * * {END}: /login/ [00m00s067ms]


2022-03-23 11:20:15,427 [http-nio-8080-exec-7] DEBUG * * * * * * * * * * {BEGIN}: /admin/relatedquery/
  requestClass=org.apache.catalina.connector.RequestFacade ; sessionId=F604F005FBED8327BD43FB814DCDA96F
  ; url=http://localhost:8080/admin/relatedquery/
  ; method=GET ; protocol=HTTP/1.1 ; scheme=http ; secure=false ; remoteAddr=0:0:0:0:0:0:0:1 ; remoteHost=0:0:0:0:0:0:0:1
  ; characterEncoding=UTF-8 ; contentLength=-1 ; contentType=null ; locale=ja ; locales=ja,en_US,en
  [header] accept=text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
  [header] accept-encoding=gzip, deflate, br
  [header] accept-language=ja,en-US;q=0.9,en;q=0.8
  [header] cache-control=max-age=0
  [header] connection=keep-alive
  [header] cookie=JSESSIONID=F604F005FBED8327BD43FB814DCDA96F
  [header] host=localhost:8080
  [header] referer=http://localhost:8080/login/
  [header] sec-ch-ua=" Not A;Brand";v="99", "Chromium";v="99", "Google Chrome";v="99"
  [header] sec-ch-ua-mobile=?0
  [header] sec-ch-ua-platform="Windows"
  [header] sec-fetch-dest=document
  [header] sec-fetch-mode=navigate
  [header] sec-fetch-site=same-origin
  [header] sec-fetch-user=?1
  [header] upgrade-insecure-requests=1
  [header] user-agent=Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.82 Safari/537.36
  [cookie] JSESSIONID=F604F005FBED8327BD43FB814DCDA96F
  [session] lastaflute.action.USER_BEAN.FessUserBean={userId=admin, sync=2022/03/23 11:20:15}@1bc0dd37
  [session] lastaflute.action.USER_LOCALE=ja
  [session] relatedQueryPager=org.codelibs.fess.app.pager.RelatedQueryPager@4c6af3bf
2022-03-23 11:20:15,437 [http-nio-8080-exec-7] DEBUG ...Routing to action: name=admin_relatedquery_adminRelatedqueryAction params={}
2022-03-23 11:20:15,438 [http-nio-8080-exec-7] DEBUG  by the mapping path: /admin/relatedquery/
2022-03-23 11:20:15,439 [http-nio-8080-exec-7] DEBUG ...Saving user locale to session: ja
2022-03-23 11:20:15,442 [http-nio-8080-exec-7] DEBUG #flow ...Calling back #before for AdminRelatedqueryAction
2022-03-23 11:20:15,443 [http-nio-8080-exec-7] DEBUG refresh user info: false
2022-03-23 11:20:15,444 [http-nio-8080-exec-7] DEBUG ...Checking login status for login required
2022-03-23 11:20:15,450 [http-nio-8080-exec-7] DEBUG ...Passing login check as already-login
2022-03-23 11:20:15,460 [http-nio-8080-exec-7] DEBUG Begin transaction: [FormatId=4360, GlobalId=1648001999203/5, BranchId=]
2022-03-23 11:20:15,462 [http-nio-8080-exec-7] DEBUG #flow ...Beginning #action AdminRelatedqueryAction@index()
2022-03-23 11:20:15,577 [http-nio-8080-exec-7] DEBUG Commit transaction: [FormatId=4360, GlobalId=1648001999203/5, BranchId=]
2022-03-23 11:20:15,579 [http-nio-8080-exec-7] DEBUG #flow ...Calling back #finally for AdminRelatedqueryAction
2022-03-23 11:20:15,585 [http-nio-8080-exec-7] DEBUG #flow ...Forwarding to #jsp /admin/relatedquery/admin_relatedquery.jsp
2022-03-23 11:20:15,753 [http-nio-8080-exec-7] DEBUG 
  responseClass=org.apache.catalina.connector.ResponseFacade ; committed=true
  ; httpStatus=200 ; contentType=text/html;charset=UTF-8 ; locale=ja_JP
  [header] Cache-Control=no-cache, no-store
  [header] Connection=keep-alive
  [header] Content-Type=text/html;charset=UTF-8
  [header] Date=Wed, 23 Mar 2022 02:20:15 GMT
  [header] Expires=Thu, 01 Dec 1994 16:00:00 GMT
  [header] Keep-Alive=timeout=60
  [header] Pragma=no-cache
  [header] Transfer-Encoding=chunked
  [request] VirtualHostValue=
  [request] admin_relatedquery_adminRelatedqueryAction=org.codelibs.fess.app.web.admin.relatedquery.AdminRelatedqueryAction@157c7847
  [request] admin_relatedquery_adminRelatedqueryAction_index_Form=VirtualForm:{formMeta:{admin_relatedquery_adminRelatedqueryAction_index_Form, org.codelibs.fess.app.web.admin.relatedquery.SearchForm, props=2}, realForm=org.codelibs.fess.app.web.admin.relatedquery.SearchForm@4f7ca081}@2f09beb7
  [request] developmentMode=false
  [request] editable=true
  [request] editableClass=
  [request] eoled=false
  [request] fesenType=default
  [request] forumLink=https://discuss.codelibs.org/c/FessJA/
  [request] helpLink=https://fess.codelibs.org/ja/13.16/admin/relatedquery-guide.html
  [request] installationLink=https://fess.codelibs.org/ja/13.16/install/install.html
  [request] lastaflute.action.ACTION_RUMTIME=runtime:{/admin/relatedquery/, public HtmlResponse AdminRelatedqueryAction@index(), pathParam:{{}}, HtmlResponse:{forward:{/admin/relatedquery/admin_relatedquery.jsp}}, display=[relatedQueryItems, developmentMode, installationLink, storageEnabled, eoled, editable, editableClass, fesenType, forumLink, helpLink]}
  [request] lastaflute.action.PUSHED_ACTION_FORM=VirtualForm:{formMeta:{admin_relatedquery_adminRelatedqueryAction_index_Form, org.codelibs.fess.app.web.admin.relatedquery.SearchForm, props=2}, realForm=org.codelibs.fess.app.web.admin.relatedquery.SearchForm@4f7ca081}@2f09beb7
  [request] lastaflute.action.USER_LOCALE=ja
  [request] lastaflute.config.ACTION_EXECUTE=execute:{public HtmlResponse AdminRelatedqueryAction@index(), urlPattern:{, ^$}}@3995f4e6
  [request] lastaflute.dbflute.SQL_COUNT={total=0}
  [request] pager=org.codelibs.fess.app.pager.RelatedQueryPager@4c6af3bf
  [request] relatedQueryItems=[{id=g1OBW4NYg2eJ/JFQ, versionNo=-1, createdBy=admin, virtualHost=internal, term=繧エ繝シ繧ケ繝域隼蝟?, queries=[Ljava.lang.String;@4d728f29, updatedTime=1545199241060, updatedBy=admin, createdTime=1545199241060}, {id=k/GMUZWUkWeC3ZV0gq+MXo9DkLOVaQ==, versionNo=-1, createdBy=admin, virtualHost=internal, term=莠檎セ、驛ィ邨??∩莉倥¢蝙倶ソョ豁」蜩?, queries=[Ljava.lang.String;@3bba7880, updatedTime=1545199241060, updatedBy=admin, createdTime=1545199241060}, {id=k/GPZJXvkZWOZJds, versionNo=-1, createdBy=admin, virtualHost=internal, term=莠碁㍾...
  [request] storageEnabled=false
  [session] lastaflute.action.USER_BEAN.FessUserBean={userId=admin, sync=2022/03/23 11:20:15}@1bc0dd37
  [session] lastaflute.action.USER_LOCALE=ja
  [session] relatedQueryPager=org.codelibs.fess.app.pager.RelatedQueryPager@4c6af3bf
* * * * * * * * * * {END}: /admin/relatedquery/ [00m00s325ms]

ありがとうございます。そのログには特にエラーがないようです。そのログの取得時に問題が再現しているようであれば、fess.logでなく、server.logの方にエラーが出ているように思います。

ご確認いただきありがとうございます。
server.logですが、どこに出力されているかご教示いただけますでしょうか?
もしくは出力する設定箇所があればご教示いただければと存じます。

Windowsだと、コンソールやサービス登録されているならサービスのログとして出ていると思います。

ご確認いただきありがとうございます。
事象を発生させた上「server.log」を確認したところ、以下のログが出力されておりました。
※ログレベルはALLとしています。

関連クエリを削除したいため、画面以外から削除する方法をご教示いただけないでしょうか?

ログ出力が多すぎるため関連すると思われるログのみ抜粋しております。

3月 24, 2022 1:47:30 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097250857; nextExpiration=1648097250855; keyCount=0; hasEvents=false; eval=false
3月 24, 2022 1:47:31 午後 org.apache.jasper.compiler.JspRuntimeContext checkUnload
詳細: Checking JSPs for unload in context [], JSP count: [10] queue length: [-1]
3月 24, 2022 1:47:31 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097251858; nextExpiration=1648097251857; keyCount=0; hasEvents=false; eval=false
3月 24, 2022 1:47:32 午後 org.apache.coyote.AbstractProtocol$ConnectionHandler process
普通: Processing socket [org.apache.tomcat.util.net.NioChannel@247cfd81:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55589]] with status [OPEN_READ]
3月 24, 2022 1:47:32 午後 org.apache.coyote.AbstractProtocol$ConnectionHandler process
普通: Found processor [null] for socket [org.apache.tomcat.util.net.NioChannel@247cfd81:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55589]]
3月 24, 2022 1:47:32 午後 org.apache.coyote.AbstractProtocol$ConnectionHandler process
普通: Popped processor [org.apache.coyote.http11.Http11Processor@42790c01] from cache
3月 24, 2022 1:47:32 午後 org.apache.coyote.http11.Http11InputBuffer fill
普通: Before fill(): parsingHeader: [true], parsingRequestLine: [true], parsingRequestLinePhase: [0], parsingRequestLineStart: [0], byteBuffer.position(): [0], byteBuffer.limit(): [0], end: [827]
3月 24, 2022 1:47:32 午後 org.apache.tomcat.util.net.SocketWrapperBase populateReadBuffer
普通: Socket: [org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper@4d639af1:org.apache.tomcat.util.net.NioChannel@247cfd81:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55589]], Read from buffer: [0]
3月 24, 2022 1:47:32 午後 org.apache.coyote.http11.Http11Processor service
普通: Error parsing HTTP request header
java.io.EOFException
	at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1328)
	at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1215)
	at org.apache.coyote.http11.Http11InputBuffer.fill(Http11InputBuffer.java:805)
	at org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:360)
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:269)
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:895)
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1732)
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.base/java.lang.Thread.run(Thread.java:834)

3月 24, 2022 1:47:32 午後 org.apache.coyote.AbstractProcessor setErrorState
普通: Error state [CLOSE_CONNECTION_NOW] reported while processing request
java.io.EOFException
	at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.fillReadBuffer(NioEndpoint.java:1328)
	at org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper.read(NioEndpoint.java:1215)
	at org.apache.coyote.http11.Http11InputBuffer.fill(Http11InputBuffer.java:805)
	at org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:360)
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:269)
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:895)
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1732)
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
	at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.base/java.lang.Thread.run(Thread.java:834)

3月 24, 2022 1:47:32 午後 org.apache.coyote.AbstractProcessorLight process
普通: Socket: [org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper@4d639af1:org.apache.tomcat.util.net.NioChannel@247cfd81:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55589]], Status in: [OPEN_READ], State out: [CLOSED]
普通: Received [GET /admin/relatedquery/details/4/g1OBW4NYg2eJ%2FJFQ HTTP/1.1
Host: localhost:8080
Connection: keep-alive
sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="99", "Google Chrome";v="99"
sec-ch-ua-mobile: ?0
sec-ch-ua-platform: "Windows"
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.82 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Sec-Fetch-Site: same-origin
Sec-Fetch-Mode: navigate
Sec-Fetch-User: ?1
Sec-Fetch-Dest: document
Referer: http://localhost:8080/admin/relatedquery/
Accept-Encoding: gzip, deflate, br
Accept-Language: ja,en-US;q=0.9,en;q=0.8
Cookie: JSESSIONID=2DD7B4F69DCA6B534C898D7E690B1D44

]
3月 24, 2022 1:48:06 午後 org.apache.coyote.AbstractProcessorLight process
普通: Socket: [org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper@7c7f5987:org.apache.tomcat.util.net.NioChannel@571c3a41:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55599]], Status in: [OPEN_READ], State out: [CLOSED]
3月 24, 2022 1:48:06 午後 org.apache.coyote.AbstractProtocol$ConnectionHandler release
普通: Pushed Processor [org.apache.coyote.http11.Http11Processor@42790c01]
3月 24, 2022 1:48:06 午後 org.apache.tomcat.util.threads.LimitLatch countDown
普通: Counting down[http-nio-8080-exec-2] latch=2
3月 24, 2022 1:48:06 午後 org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper doClose
普通: Calling [org.apache.tomcat.util.net.NioEndpoint@5c669da8].closeSocket([org.apache.tomcat.util.net.NioEndpoint$NioSocketWrapper@7c7f5987:org.apache.tomcat.util.net.NioChannel@571c3a41:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:55599]])
3月 24, 2022 1:48:07 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097287020; nextExpiration=1648097286450; keyCount=0; hasEvents=false; eval=false
3月 24, 2022 1:48:08 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097288020; nextExpiration=1648097288020; keyCount=0; hasEvents=false; eval=false
3月 24, 2022 1:48:09 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097289021; nextExpiration=1648097289020; keyCount=0; hasEvents=false; eval=false
3月 24, 2022 1:48:10 午後 org.apache.tomcat.util.net.NioEndpoint$Poller timeout
詳細: timeout completed: keys processed=1; now=1648097290022; nextExpiration=1648097290021; keyCount=0; hasEvents=false; eval=false

ありがとうございます。見たことないエラーですね。
あと、気になるのは、URLのところに%2Fが入っているのですが、通常はこれが入ることはないと思うので…。
アップグレードにあるような手順で、データをバックアップして、それをリストアして作り直していただくのが良いように思います。

ご確認いただきありがとうございます。
クロール結果のインデックスがたまっている状態なので、再インストールは回避したいのですが、
関連クエリのみを初期化する方法はございませんでしょうか?

何度もお手数をおかけし申し訳ございませんが、ご確認のほどよろしくお願い申し上げます。

Elasticsearchのドキュメントなどを参照していただいて、.fess_config.related_queryインデックスから対象のデータを削除するなどで対応すると良いと思います。

ご確認いただきありがとうございます。
「.fess_config.related_queryインデックスから対象のデータを削除する」の対応手順など参考にできる情報ございますでしょうか?
どのファイルを削除すれば良いか判断ができず、お手数をおかけしますが、ご確認いただけますと幸いです。

Elasticsearchの使い方的な話になってくるので、FessのOSSのサポートとしては、特に情報はありません。OSSのサポートを超えるサポートが必要な場合は商用サポートにリクエストをしていただくか、Elasticsearchを理解して対応して頂く感じになるかと思います。

承知いたしました。
ご返答くださりありがとうございます。