Skip to content

Conversation

bzp2010
Copy link
Collaborator

@bzp2010 bzp2010 commented Jul 27, 2025

Description

Add server mode to the ADC that exposes the HTTP API, which will help the ingress controller reduce launch and compile overhead.

This should not be used by any internal or external scenario other than a non-ingress controller unless you fully understand the ADC and know what you are doing.

It accepts the following request formats:

PUT /sync

{
    "task": {
        "opts": {
            "backend": "apisix",
            "server": "http://127.0.0.1:9180",
            "token": "token"
        },
        "config": {
            "services": [],
            "routes": [],
            "...": []
        }
    }
}

Start it with adc server.

Please pay special attention to its access control. Right now, this API does not have any additional authentication or permission control mechanisms, so it should not be called from anywhere but the local host.
Now, this server always listens on 127.0.0.1 instead of 0.0.0.0. In the future, we may add security mechanisms such as mTLS, etc., which is up for discussion.

Since the main use of this feature is for the ingress controller, it is expected that we can simply implement mTLS through components such as cert-manager, but mechanisms such as API key or basic auth are also possible.

Checklist

  • I have explained the need for this PR and the problem it solves
  • I have explained the changes or the new features added to this PR
  • I have added tests corresponding to this change
  • I have updated the documentation to reflect this change
  • I have verified that this change is backward compatible

@bzp2010 bzp2010 marked this pull request as ready for review July 28, 2025 10:46
Copy link
Contributor

@juzhiyuan juzhiyuan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other changes LGTM

bzp2010 and others added 2 commits July 29, 2025 11:23
Co-authored-by: 琚致远 / Zhiyuan Ju <juzhiyuan@apache.org>
@bzp2010 bzp2010 merged commit bf3c303 into main Jul 29, 2025
21 checks passed
@bzp2010 bzp2010 deleted the bzp/feat-ingress-server branch July 29, 2025 03:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants