How to intercept an http request triggering batch.js?

Hi All,

We are having a long going issue where a batch.js is creating delay in our custom-plugin. We have tried many approaches but nothing has worked for far. One last scenario we tried made us move closer to solution but we have hit a roadblock and would appreciate if someone can give their insights on this.

We tried intercepting the request using a servlet-filter but have noticed that instead of intercepting the request, a duplicate similar request is getting created on which action are being performed.

We would appreciate if someone could help answer our below queries:

  1. If there is a way of intercepting that particular batch.js request as mentioned above?
  2. Can we restrict only the batch.js with jira.general context?