I'm wondering what the behavior should be for an interaction in which the user sends a query but the data reply takes several minutes (more time than in probable for the user to look at a loader or something...)
Any ideas / references?
There are several features you can use, which may be combined if appropriate:
Status bar. A status bar in the window can indicate that the process is underway or not. Ideally, the status bar will include a progress bar and/or percent done and/or estimated time remaining. If possible, place the status information in the corner of the window so the user can see it while using another mostly overlapping window (what they’re doing while they wait). Status bar usage design guidelines are in the Windows User Experience Interaction Guidelines.
Notifications. A notification from the task bar or similar ignorable and non-modal message can alert the user when the process finishes. Windows User Experience Interaction Guidelines also covers notifications. Notifications can be presented when the window that launched the process isn't in focus or even open.
Badging. Status information can be incorporated into the dock/task bar icon, indicating that a process is underway. Like notifications, this can provide feedback when the window that launched the process is out of focus. See "badging" in the OSX Human Interface Guidelines.
Animation and sound. Animation (e.g., flashing the task bar icon) and/or a “completion” sound can be used to alert the user when the process finishes, but only if the users should respond immediately (something at least as urgent as answering a phone). Even then, you probably want to provide users the option of suppressing the animation and sound.
Process management window. If the user can have multiple processes running at the same time, the UI can include a window that displays the detailed progress on every process, both underway and completed. It may also include controls to pause, restart, re-run, and cancel individual processes. Firefox has this in the form of a download management page that users can access from the download status bar (shown in the upper right of the window).
Progress message box. Ideally, the user can do other things in the app while the process is running asynchronously in the background. However, if this is not possible, then you can display a modal progress message box with a determinate or indeterminate progress bar. You should also somehow change the appearance of the underlying window or its dock/taskbar icon so the user can see the process is in progress even when all or most of the window is occluded (e.g., by dimming everything within). Both OSX and Windows guidelines cover progress bars.