icatproject / icat.server

The ICAT server offering both SOAP and "RESTlike" interfaces to a metadata catalog.
Other
1 stars 5 forks source link

Slow queries due to application of access rules #250

Open RKrahl opened 3 years ago

RKrahl commented 3 years ago

There is an issue for ids.server about some queries being excessively slow to an extent that requests timeout, see icatproject/ids.server#115. It turns out that this is caused by quite complicated conditions that icat.server adds to the queries to enforce the access rules.

@kevinphippsstfc provided a work around in icatproject/ids.server#118 that will fix the problem for ids.server, by doing the concerned queries in a privileged session, which essentially bypasses authorization. But of course, the root of the problem is the way how access rules are applied in icat.server and the same problem may occur again if other clients try to do the same queries. I assume this may affect any search for Datafiles if the facility has billions of them, like DLS.

I open this issue as a reminder that although the issue might be fixed in ids.server, the underlying problem still remains.