Share via

Found a workaround but identified a potential UI/Logic bug in Azure AI Foundry deployment flow

KWOK Tsz Wing 0 Reputation points
2026-04-27T04:28:42.22+00:00

I discovered that the success of the gpt-image-2 deployment depends on how the deployment is initiated within Azure AI Foundry:

The FAILED method: Using the "Global" entry point (Model Catalog) to deploy directly into an existing resource. This results in the 504/Socket Hang Up error I reported earlier. It seems this path creates a "broken" routing configuration where the Gateway cannot talk to the backend.

  1. The SUCCESSful method: Deploying gpt-image-2 from a Legacy OpenAI Resource, when initiating the deployment from the legacy resource/catalog, the system forces the creation of a completely new Project specifically for gpt-image-2. This path works perfectly and generates images instantly.

Technical Feedback for Engineering: There seems to be a discrepancy in how the API Gateway (Global Standard) is provisioned between these two UI paths. The direct deployment path from the Model Catalog appears to have a Routing/Provisioning bug, while the Project-based deployment path configures the endpoint correctly.


**UPDATE: The new deployment playground now also get a "**Request failed with status code 504".

Azure OpenAI in Foundry Models

2 answers

Sort by: Most helpful
  1. Karnam Venkata Rajeswari 3,240 Reputation points Microsoft External Staff Moderator
    2026-04-30T19:29:34.5466667+00:00

    Hello @KWOK Tsz Wing

    Welcome to Microsoft Q&A .Thank you for reaching out to us.

    In addition to the inputs provided by Sina Salam , please see if the following help

    This behavior may not always appear broadly visible due to several factors

    1. Workload variability - Image generation latency depends on prompt complexity, image size, and quality settings, which can lead to different experiences across environments
    2. Deployment configuration differences - Performance can vary based on deployment type (standard vs provisioned) and regional characteristics

    The Playground uses the same deployed endpoint and APIs that are used in production integrations. As a result,

    1. A failure in Playground generally reflects the same behavior that would occur in API-based integration
    2. Stable responses are required before production integration can proceed

    Image generation workloads can take longer to process, depending on parameters such as resolution and quality

    please see if the following help -

    1. Please validate deployment status by ensuring that the deployment state shows “Succeeded”
    2. Test simplified requests using minimal prompts and smaller image sizes where applicable. Lower complexity can help reduce processing time
    3. Performing model-level comparison by testing another available image model within the same resource. This helps determine whether the issue is model-specific or broader.
    4. Reviewing deployment configuration by confirming the deployment type and region are supported for the selected model as not all models support all deployment types
    5. Kindly ensure that appropriate timeout and retry logic is configured for longer-running requests

    The following references might be helpful , please check them out

    Thank you

    Was this answer helpful?

    0 comments No comments

  2. Sina Salam 29,596 Reputation points Volunteer Moderator
    2026-04-27T12:54:42.1233333+00:00

    Hello KWOK Tsz Wing,

    Welcome to the Microsoft Q&A and thank you for posting your questions here.

    I understand that you found a workaround but identified a potential UI/Logic bug in Azure AI Foundry deployment flow.

    I validated that the working result comes from the project-based Foundry deployment, not from the original failed direct deployment. The direct “Model Catalog > existing resource” path is therefore not fixed and should not be considered reliable.

    For production environment you will have to deploy gpt-image-2 from inside a Microsoft Foundry project and use the endpoint associated with that successful deployment. This aligns with Microsoft’s documented deployment model for Azure-direct models and with the official Azure OpenAI image-generation guidance. Microsoft’s docs also state that not all models support all deployment types, so the failing direct Global deployment should be treated as an invalid/broken deployment path for this case until Microsoft confirms otherwise. Use these links for reference:

    I hope this is helpful! Do not hesitate to let me know if you have any other questions or clarifications.


    Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.