I have some performance issues in the Spring boot Project and PostgreSQL database.
Assume there is a large table, about 20 million records in the PostgreSQL database.
I use the spring crud Repository class to fetch records.
in a non-partitioned table, everything is ok and query data is very fast. ~100 milliseconds. when I switch the target table to a partitioned one, it turns into a performance issue. the same query takes to long about 1500 milliseconds.
The partitioned table is based on user_id and also query search is based on user_id.
There are some mapping entities with the base entity.
The same query execution in the database console is so fast. about 100 milliseconds.
Anybody can help me?