Commit Graph
20 Commits
Author SHA1 Message Date
Ta-Ching ChenandSoam Vasani 46ff55ab49 Fix unstoppable kubewatcher (#208)
Fix a bug due to which watches could never be stopped; simplify control flow a bit.
2017-07-10 16:01:48 -07:00
Ta-Ching ChenandSoam Vasani d9b98830cf Fix http response body not closed correctly, return immediately on error (#210)
* Fix controller timer handler not return when error occurred

* Fix controller not close http response correctly

This PR aims to fix controller not close response correctly. Also, I’ve check all over the project there is no more resource leak issues exist after this patch.

* Fix controller not return immediately when error occurred

* Sort import
2017-06-17 13:10:54 -07:00
Javier CastellanosandSoam Vasani cde2f26a9d Added support for pods and replication controllers to watchers (#216) 2017-06-01 10:49:57 -07:00
yang qfandSoam Vasani a8c6347ed0 Add Time Trigger API and client (#153) (#161)
This change adds a timer trigger API, client, and implementation.  Users can trigger a function with a cron-compatible string. 

This change also moves the publisher interface and webhook-based publisher implementation out of kubewatcher and into a separate `publisher` package.
2017-05-17 15:13:56 -07:00
Soam Vasani 01b399187e Work around 'too old resource version' 2017-03-28 12:42:59 +02:00
Soam Vasani b4dd7a83df Better error checking in watch restarts 2017-03-28 12:06:07 +02:00
Soam Vasani 137d8f7285 Track resourceVersion from event objects 2017-03-28 10:01:11 +02:00
Soam Vasani c9f63e8173 Pass last resource version to restart watch 2017-03-28 10:01:11 +02:00
Soam Vasani a71756762b Restart watches when they stop unexpectedly 2017-03-28 10:01:11 +02:00
Soam Vasani bba71d65a2 Fix incorrect log printf 2017-01-23 19:49:13 -08:00
J. Gavin Ray 943d430870 # This is a combination of 2 commits.
# This is the 1st commit message:

Changed package names to match the new organization

# This is the commit message #2:

Forgot Cache
2016-12-24 08:11:35 -08:00
Soam Vasani d721df998d Fix object-type header passed to event handlers 2016-12-20 14:16:33 -08:00
Soam Vasani c5425180e8 Make webhook publisher use relative urls 2016-12-20 12:19:51 -08:00
Soam Vasani 0456df0d63 Refactor kubewatcher/webhook publisher
Create a Publisher interface. Refactor webhook publisher to satisfy
that interface.

Add some limited retries to webhook publisher.
2016-12-19 14:38:44 -08:00
Soam Vasani de30886c9e compile error 2016-12-16 00:43:45 -08:00
Soam Vasani 215f4fc30f comments 2016-12-15 19:48:45 -08:00
Soam Vasani 53c49d1485 Add an atomic bool to track if a watch is stopped
Saw a watch channel close once without actually calling watch.Stop.
Need to investigate this a bit and handle it if necessary.
2016-12-15 09:34:03 -08:00
Soam Vasani 5c6dcca19d Pass obj type to functions 2016-12-12 08:46:19 -08:00
Soam Vasani ddb189bda2 Kube requests: add content-type 2016-12-10 19:54:01 -08:00
Soam Vasani fa093829bc Kubernetes events watcher
Kubewatcher watches the Kubernetes API for Watches that have been
configured on the fission controller.  It then posts that event to the
function configured in the watch.
2016-12-09 23:22:18 -08:00