When postmeta queries dominate your slow log, it is time for a custom table. dbDelta() with a CREATE TABLE statement on activation, then $wpdb queries against the table.
Use $wpdb->prefix to respect multisite. Use prepared statements via $wpdb->prepare() for any user input.
For ORM-style ergonomics, a thin repository class with typed entities reads better than scattered $wpdb calls.