Commit Graph
994 Commits
Author SHA1 Message Date
Ta-Ching ChenandGitHub d20dc9aa64 Allow using URL as archive source when creating functions (#1360)
In the case of large files, it takes a long time for the user to download
the source from the URL and upload it to StorgeSvc through CLI.

This PR allows a user to use URL as the function source when creating a function
and provides a new flag "--keeparchiveurl" to let the user to decided
whether the CLI should download the file first or store the file URL in the
archive directly. If "--keeparchiveurl" is true, then no checksum will be
generated, it's the user's responsibility to ensure the file won't be changed.
2019-10-28 22:37:13 +08:00
Ta-Ching ChenandGitHub 52b5cb0902 Remove UID from CLI output (#1361) 2019-10-28 19:34:02 +08:00
Ta-Ching ChenandGitHub bc5c181fc2 Update fission architecture doc (#1356) 2019-10-22 19:46:57 +08:00
Ta-Ching ChenandGitHub fed30e1b24 Refactor plugin & version subcommands (#1359) 2019-10-22 17:57:56 +08:00
Vivek SinghandTa-Ching Chen 22de11190c Calling the function that handles kafka messages, asynchronously (#1355) 2019-10-19 14:41:46 +08:00
Ta-Ching ChenandGitHub e42f81a7a1 Refactor package CLI command (#1345) 2019-10-13 01:30:20 +08:00
Ta-Ching ChenandGitHub f30e7df43d Fix release script wrongly tags image name & sed problem on Linux (#1353) 2019-10-12 21:38:13 +08:00
Ta-Ching ChenandGitHub c930c69629 Update CHANGELOG for 1.6.0 (#1352) 2019-10-11 04:07:38 +08:00
Ta-Ching Chen 08b6d43ac1 Fission 1.6.0 v1.6.0 1.6.0 2019-10-11 01:11:58 +08:00
Ta-Ching ChenandGitHub 53b075a315 Move statefulset to apps/v1 (#1350) 2019-10-10 23:42:40 +08:00
Ta-Ching ChenandGitHub b8311d43ce Fix newdeploy failed to find serviceEntry in cache (#1349)
When a function with executor type newdeploy got created, Newdeploy
is expected to create deployment/HPA/service for it and insert serviceEntry
to the cache for later use. Once clients call the function, newdeploy returns
the serviceEntry to the router.

However, the log shows that the newdeploy was unable to find the entry and
prints "Resource not found - key 'xxx' not found". The root cause is that the
informer controller instead of processing items in parallel, it dispatches XXFunc
to process items one by one. So if there is any problem during the creation of the
kubernetes resource, it takes a longer time to process the next item and hence
the serviceEntry was not inserted before clients call the function.

This PR lets the newdeploy to process items in extra goroutines instead of blocking
the process loop. It's a workaround to solve the problem above, we should consider
using workqueue to solve it in the future.
2019-10-10 23:32:36 +08:00
Ta-Ching ChenandGitHub 1075c5da13 Support encoded path in router (#1347)
Encoded path means the URL path contains encoded string like "/foo%2Fbar".
Gorilla/Mux by default doesn't enable encoded path support, you need to enable
it when initializing the router.

This PR adds a new environment variable USE_ENCODED_PATH to the router
deployment to enable encoded path support.
2019-10-10 02:23:41 +08:00
Ta-Ching ChenandGitHub 59c8569190 Support custom private go vendor (#1346) 2019-10-10 01:44:44 +08:00
Suraj BanakarandTa-Ching Chen 395a8adf37 Implement TLS authentication for kafka mqt (#1300)
* use secrets to store keys and certificates
2019-10-10 00:18:57 +08:00
Ta-Ching ChenandGitHub d358a29b17 Fix the namespace mismatch problem when deploying with a single YAML file (#1344)
If a user deploys fission in the namespace which is different from the one in the single YAML file generated by helm, fission components won't be able to talk to each other due to the wrong namespace appends after the service address.

This PR adds --namespace when generating the YAML file to prevent the mismatch problem.
2019-10-09 01:14:56 +08:00
Ta-Ching ChenandGitHub e253d2a376 Move charts executor service to the right place (#1343) 2019-10-07 18:44:58 +08:00
Ta-Ching ChenandGitHub bfd005a295 Allow to deploy router as DaemonSet (#1342)
ReplicaSet generated by Deployment distributes pods to nodes based
on nodes resource usage, which means in some cases the newly created
pods may be assigned to only a few nodes. The requests will go to the
same node if there multiple pods on it and may increase the node
resource usage and overall request latency.

To solve the problem mentioned above, this PR allows users to deploy
the router as DaemonSet so that we can distribute requests across all
nodes for better workload distribution and lower latency.
2019-10-07 18:09:36 +08:00
MengZeLeeandTa-Ching Chen c1a3bdd895 Add package filter feature (#1341) 2019-10-05 01:47:17 +08:00
Ta-Ching ChenandGitHub b18462b10b Fix executor doesn't apply user-configured container spec correctly (#1339)
The merge function executor used wasn't merge container correctly, and it
didn't merge all fields in spec except volumeMount & Env which confused people.

To apply the user-configured container correctly, this PR changes the way of merge
and follows rules:

1. Slices are merged and return an error if the elements in the slice have name conflicts.
2. Maps are merged, the value of map of dst container are overridden if the key is the same.
3. The rest of the fields of dst container are overridden directly.
2019-10-04 05:16:04 +08:00
Ta-Ching ChenandGitHub 30dba5dae9 Bump jvm builder JDK version (#1340) 2019-10-03 14:24:22 +08:00
Prabhu JayakumarandTa-Ching Chen f12880fb5c Allow to add annotations to router service in helm chart (#1338) 2019-10-02 14:48:36 +08:00
Ta-Ching ChenandGitHub c61442ee76 Remove too verbose and unhelpful debug log (#1336) 2019-10-02 01:35:23 +08:00
Vivek SinghandTa-Ching Chen 96ae708163 package will now be listed, sorted by lastupdatedtime (#1334) 2019-10-01 15:30:51 +08:00
Suraj BanakarandTa-Ching Chen b47b3ecb70 Fix kafka producer and consumer logs show empty objects (#1281) 2019-09-29 23:47:05 +08:00
Ta-Ching ChenandGitHub 7cdc146515 Move Deployment API group from extensions/v1beta1 to apps/v1 (#1331)
In 1.9, kubernetes prompted Deployment to apps/v1 and finally deprecated
extensions/v1beta1 support in 1.16. Users will see the following error message
in log when fission components try to submit Deployment to the k8s API server
and specify extensions/v1beta1 as API group.

error: unable to recognize "deployment": no matches for kind "Deployment" in version "extensions/v1beta1"

This PR updates call to k8s API server and apiKind in chart files to avoid fission failure in 1.16.
2019-09-29 22:16:33 +08:00
Ta-Ching ChenandGitHub e734fa3554 Fix router health route not found if no HTTP triggers created (#1333)
Router readiness probe failed due to kubelet cannot find router healthz endpoint.
This is caused that the healthz endpoint is added only when there is any update request
send to the updateRouterRequestChannel, and makes router failed.

This PR sends an update request right before the router is started to avoid the problem.
2019-09-28 17:43:04 +08:00
Ta-Ching ChenandGitHub 71b587b58e Use ErrorHandler to handle proxy error (#1310)
The router prints error no matter what error type it is.
It's useful for troubleshooting, however, it also prints
the context canceled error, which means that users abort
request before reply and its really normal nowadays. Also,
the router returns 502 if error is not nil and may confused
client if it's a timeout error.

To solve these problems, this PR adds an error handler to
reverse proxy to examine the return error and change the
status code when needed.
2019-09-28 14:22:20 +08:00
Ta-Ching ChenandGitHub 81ae6f38fc Fix spec doesn't update status of failed package when applying spec files (#1332)
Previously, the spec doesn't update the package status if nothing
in the spec file changed. Due to this, the failed package will
always stay in the failed state.

This PR adds a check to see whether a package is in the failed state.
If yes, then changes the state to pending for builder manager to rebuild it.
2019-09-28 04:35:57 +08:00
Ta-Ching ChenandGitHub 7fbb4098a4 Fix empty host value when list http triggers (#1328) 2019-09-28 00:28:14 +08:00
Ta-Ching ChenandGitHub f8af8b91f5 List/Delete HTTP triggers by function (#1327)
Previously, a user has to delete HTTP triggers point to
the same function one by one. This PR adds new flag --function
to list & delete commands. So that user can delete or list all
triggers with the same function. However, this feature is not
working for triggers with canary deployment setup.
2019-09-27 17:21:11 +08:00
Ta-Ching ChenandGitHub b5341edec0 Add Ingress TLS support (#1326)
This PR aims to add the Ingress TLS support by specifying the
TLS secret when creating/updating the HTTP trigger.

Command example:

fission route create --name foo \
    --url /foo/{bar} --function foofn --createingress \
    --ingressannotation "nginx.ingress.kubernetes.io/ssl-redirect=false" \
    --ingressannotation "nginx.ingress.kubernetes.io/use-regex=true" \
    --ingressrule "*=/foo/*"
    --ingresstls "foobartls"
2019-09-27 00:49:23 +08:00
Ta-Ching ChenandGitHub 49d60b19f3 Add Ingress host, path and annotations support (#1325)
For each ingress controller, the format of ingress host,
path and annotations are different. To support different
kinds of controller, this PR adds new ingress config field
to http trigger spec. A user can set annotations, host and
path based on the type of underlying ingress controller
with CLI.

Command example:

fission route create --name foo \
    --url /foo/{bar} --function foofn --createingress \
    --ingressannotation "nginx.ingress.kubernetes.io/ssl-redirect=false" \
    --ingressannotation "nginx.ingress.kubernetes.io/use-regex=true" \
    --ingressrule "*=/foo/*"
2019-09-26 16:54:16 +08:00
Ta-Ching ChenandGitHub 82a7acf408 Set maxSurge to 20% for safe rolling upgrade (#1321) 2019-09-23 16:11:56 +08:00
Ta-Ching ChenandGitHub 7bd57c208a Disable revision history for newdeploy (#1319) 2019-09-23 14:25:49 +08:00
Ta-Ching ChenandGitHub 27ec605955 Pre-built docker go module dependency cache image (#1318) 2019-09-18 05:07:53 +08:00
Ta-Ching ChenandGitHub c94e02b302 Fix newdeploy doesn't handle error properly (#1316) 2019-09-16 15:43:36 +08:00
Ta-Ching ChenandGitHub 5d2d65f05c Fix failed to update specialization timeout (#1315) 2019-09-16 13:21:25 +08:00
Ta-Ching ChenandGitHub 6d3d277cb9 Fix potential nil pointer problem when using multierror pkg (#1311) 2019-09-16 11:03:23 +08:00
Ta-Ching ChenandGitHub 4d654c6fe7 Add codecov config file (#1314) 2019-09-16 09:20:49 +08:00
Ta-Ching ChenandGitHub ecb97db913 Integrate with Codecov (#1308) 2019-09-11 14:52:45 +08:00
Ta-Ching ChenandGitHub 082c244b0b Fix executor unable to list secrets/configmaps (#1307) 2019-09-11 10:47:20 +08:00
parauliyaandTa-Ching Chen 678a2c7ad8 Configurable function level timeout (#1284) 2019-09-10 23:28:08 +08:00
Ta-Ching ChenandGitHub 78026ac573 Add specialization timeout default value to CLI (#1305) 2019-09-10 17:24:35 +08:00
Ta-Ching ChenandGitHub 4cfd459317 Update CHANGELOG for 1.5.0 (#1304) 2019-09-09 17:06:44 +08:00
Ta-Ching ChenandGitHub e481c234ee Fission 1.5.0 (#1303) 2019-09-09 15:38:27 +08:00
Ta-Ching ChenandGitHub 0d872020e3 Refactor support dump CLI (#1301) 2019-09-04 14:42:47 +08:00
moluzhangandTa-Ching Chen 62016b2f83 Support reverse query function for query log (#1298) 2019-09-02 18:02:07 +08:00
Ta-Ching ChenandGitHub 58811ab522 Fix unit tests failure (#1297) 2019-08-30 23:39:45 +08:00
David SheldonandTa-Ching Chen 19c60d1592 Fix environment version validation (#1253) 2019-08-30 19:02:18 +08:00
Vivek SinghandTa-Ching Chen cd36047660 Support for providing multiple CMs and secrets in fn create/update (#1282) 2019-08-30 17:13:24 +08:00