Skip to content
This repository was archived by the owner on Nov 16, 2020. It is now read-only.

Commit b8ec32d

Browse files
authored
Rename api-manager -> endpoints (#630)
* Follow existing patterns from functions and image - largely rewrote and validated that endpoints are managed correctly - use Meta object * Remove dead-code (api-manager) * Move utils.Constants to api/v1 to avoid circular dependencies Signed-off-by: Berndt Jung <bjung@vmware.com>
1 parent b52e6ba commit b8ec32d

File tree

151 files changed

+7266
-7929
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

151 files changed

+7266
-7929
lines changed

Gopkg.lock

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Gopkg.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,3 +88,7 @@ ignored = [
8888
[[constraint]]
8989
name = "github.com/kubeless/kubeless"
9090
version = "1.0.0-alpha.2"
91+
92+
[[constraint]]
93+
branch = "master"
94+
name = "github.com/knative/pkg"

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ generate: ## run go generate
137137
scripts/generate-models.sh swagger/models.json
138138
scripts/generate.sh functions Functions functions.yaml
139139
scripts/generate.sh images Images images.yaml
140-
scripts/generate.sh api-manager APIManager api-manager.yaml
140+
scripts/generate.sh endpoints Endpoints endpoints.yaml
141141
scripts/generate.sh application-manager ApplicationManager application-manager.yaml
142142
scripts/generate.sh event-manager EventManager event-manager.yaml
143143
scripts/generate.sh identity-manager IdentityManager identity-manager.yaml

README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ Installing Dispatch depends on having a Kubernetes cluster with the Knative comp
3838
export DOCKER_PASSWORD="password"
3939
export DISPATCH_NAMESPACE="dispatch-server"
4040
export RELEASE_NAME="dispatch-server"
41+
export INGRESS_IP=$(kubectl get service -n istio-system knative-ingressgateway -o json | jq -r .status.loadBalancer.ingress[].ip)
4142
```
4243

4344
2. Build and publish a dispatch image:
@@ -96,14 +97,14 @@ Installing Dispatch depends on having a Kubernetes cluster with the Knative comp
9697
./dispatch-darwin --config ./config.json create function --image dispatchframework/python3-base:0.0.13-knative hello ./examples/python3/hello.py
9798
Created function: hello
9899
```
99-
Once status is READY
100+
Once status is READY:
100101
```bash
101102
./dispatch-darwin --config ./config.json get function
102103
NAME | FUNCTIONIMAGE | STATUS | CREATED DATE
103104
----------------------------------------------------------------
104105
hello | ************* | READY | Thu Sep 13 12:41:07 PDT 2018
105106
```
106-
Exec the function
107+
Exec the function:
107108
```
108109
./dispatch-darwin --config ./config.json exec hello <<< '{"name": "user"}' | jq .
109110
{
@@ -120,5 +121,13 @@ Installing Dispatch depends on having a Kubernetes cluster with the Knative comp
120121
}
121122
}
122123
```
124+
Create an endpoint:
125+
```
126+
./dispatch-darwin --config ./config.json create endpoint get-hello hello --method GET --method POST --path /hello
127+
```
128+
Hit the endpoint with curl:
129+
```
130+
curl -v http://${INGRESS_IP}/hello?name=Jon -H 'Host: default.dispatch-server.dispatch.local'
131+
```
123132
124133
For a more complete quickstart see the [developer documentation](#documentation)

pkg/api-manager/controller.go

Lines changed: 0 additions & 151 deletions
This file was deleted.

0 commit comments

Comments
 (0)