Hi,
I’m using IntraWeb 16.0.10 and testing TMS AI (MCP Cloud AI) with the TMSMCPCloudAI component.
I noticed a problem when running the application in ISAPI.dll mode.
In Standalone mode everything works correctly, including file upload and execution.
Setup
Code
TMSMCPCloudAI1.Files.Clear;
TMSMCPCloudAI1.Context.Text := BuildPromptBonificoShort;
TMSMCPCloudAI1.Service := aiOpenAI;
TMSMCPCloudAI1.UploadFile(FPathRicevutaFisico, aiftPDF);
The issue is that in ISAPI mode, the code seems to hang after UploadFile.
It does not continue to the execute methods and appears to remain blocked.
No exception is raised — it just does not proceed.
In Standalone mode, the exact same code works without any issue.
Questions
-
Is TMSMCPCloudAI fully compatible with IntraWeb ISAPI deployments?
-
Are there known limitations when running under IIS (threading, async handling, HTTP client restrictions, etc.)?
-
Does the component require specific settings in ISAPI mode (timeouts, thread model, Indy vs WinHTTP, etc.)?
-
Is there anything special to consider when uploading PDF files in an ISAPI context?
Any feedback on compatibility or recommended configuration for ISAPI would be greatly appreciated.
Thank you.
Sorry, we have not tested/validated TMS AI Studio against deployment via an IntraWeb ISAPI DLL.
We will need to investigate what might be causing this.
Upon further investigation, TMSMCPCloudAI uses underlying the Microsoft WinInet API when used from Windows to perform its HTTP requests.
From the Microsoft documentation:
**It mentions:
Note** WinINet does not support server implementations. In addition, it should not be used from a service.
So, sadly, as-is, it is not possible to use TMS AI Studio from an IntraWeb ISAPI DLL.
Thank you for the clarification and for investigating this.
Since the limitation comes from WinINet not being supported in server environments or services, would it be possible to use an alternative HTTP stack (for example WinHTTP) in TMSMCPCloudAI when running in such environments?
Alternatively, is there any recommended workaround to make TMS AI Studio usable in applications deployed as an IntraWeb ISAPI DLL (IIS)? For example:
-
using a custom HTTP client
-
delegating the AI calls to an external service/process
-
or configuring the component in a different way
Do you have any plans to support server environments like ISAPI/IIS deployments in the future?
This would be extremely useful for Delphi web applications based on IntraWeb that are deployed on IIS.
Thank you for your support.
It is not a light or small task to isolate the underlying used WinInet API HTTP client functions with another HTTP client or WinHTTP API and ideally make this selectable what to use.
Not sure how much demand there would be for this to justify the effort. We’ll need to investigate the technical effort & estimate the demand for this first.
Thank you for the explanation. We understand that this is not a small task and requires proper evaluation. We hope it may be considered for future development.