Not to be rude, but let’s start with something a bit simpler. Caching is a hard problem. Caching data in the mendix runtime would very much be an anti-pattern as the server is stateless in nature. While you could theoretically use an in-memory database in another process, you’d still need to marshall data back and forth between your Mendix app and your caching system.
In this custom widget, what type of delay do you have in the auto-complete / type ahead feature? Are you canceling previous events? Doing that incorrectly could also cause extreme load on your system and emit a lot of unnecessary XAS calls.