openstate / open-raadsinformatie

Doorzoek vergaderstukken van gemeenten en provincies
https://openbesluitvorming.nl
MIT License
28 stars 12 forks source link

Slow queries #445

Open joepio opened 1 year ago

joepio commented 1 year ago

The responses for simple queries can take up to 30 seconds.

Screenshot 2023-09-28 at 16 01 59 Screenshot 2023-09-28 at 16 00 12

Hopefully this is fixable with current hardware.

breyten commented 1 year ago

We reconfigured redis to prevent saving any kind of state which makes performance better in general. We're looking into other ways to improve performance.

tsaltena commented 4 months ago

Is there an update on this? I am trying to implement some cross-index searches, but they can take minutes to complete. I am using the API to find mentions of academic researchers in policy documents.

Like so:

            "query": {
                "bool": {
                        "must": [
                            {"bool": {"should": ["Ronald Van Steden", "R. Steden", "Ronald Steden"]}},
                            {"match_phrase": {
                                "text": {
                                    "query": "Vrije Universiteit Amsterdam",
                                    "slop": 1,
                                    }    
                            }}
                        ]
                    }
            },

image

Are the search clusters provisioned with enough RAM for indexed text data?