Coder Social home page Coder Social logo

funktion's People

Contributors

bbrowning avatar iocanel avatar jstrachan avatar maleck13 avatar rawlingsj avatar tobias avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

funktion's Issues

Problems with zsh

In zsh I seem to have all kinds of issues when using funktion

Some examples:

funktion create flow timer://bar?period=5000 http://hello/
zsh: no matches found: timer://bar?period=5000

It works great on bash and also works great if I escape the urls using double quotes.

I also have a random failures with random funktion commands:

# funktion <random command>
Extra data: line 1 column 12 (char 11)

ConfigMap "catalog-letschat" is invalid: metadata.annotations: Too long: must have at most 262144 characters

I get the following error when trying to run funktion install platform using an OpenShift Container Platform 3.4.0.40 installation and:

funktion version: 1.0.9

$ funktion install platform
kubectl apply --namespace funktion-system -f https://repo1.maven.org/maven2/io/fabric8/platform/packages/funktion-platform/2.4.21/funktion-platform-2.4.21-kubernetes.yml

namespace "user-secrets-source-admin" created
serviceaccount "configmapcontroller" created
serviceaccount "exposecontroller" created
serviceaccount "fabric8" created
serviceaccount "funktion-operator" created
service "fabric8" created
service "jenkinshift" created
configmap "catalog-apiman" created
configmap "catalog-apiman-gateway" created
configmap "catalog-artifactory" created
configmap "catalog-cd-pipeline" created
configmap "catalog-chaos-monkey" created
configmap "catalog-chat-irc" created
configmap "catalog-chat-letschat" created
configmap "catalog-chat-slack" created
configmap "catalog-configmapcontroller" created
configmap "catalog-content-repository" created
configmap "catalog-elasticsearch" created
configmap "catalog-elasticsearch-v1" created
configmap "catalog-exposecontroller" created
configmap "catalog-fabric8-docker-registry" created
configmap "catalog-fabric8-forge" created
configmap "catalog-fluentd" created
configmap "catalog-funktion" created
configmap "catalog-funktion-operator" created
configmap "catalog-funktion-runtimes" created
configmap "catalog-gerrit" created
configmap "catalog-git-collector" created
configmap "catalog-gitlab" created
configmap "catalog-gogs" created
configmap "catalog-grafana" created
configmap "catalog-ingress-nginx" created
configmap "catalog-jenkins" created
configmap "catalog-keycloak" created
configmap "catalog-kibana" created
configmap "catalog-kiwiirc" created
configmap "catalog-kubeflix" created
configmap "catalog-logging" created
configmap "catalog-manageiq" created
configmap "catalog-management" created
configmap "catalog-maven-shell" created
configmap "catalog-message-broker" created
configmap "catalog-message-gateway" created
configmap "catalog-messaging" created
configmap "catalog-metrics" created
configmap "catalog-nexus" created
configmap "catalog-prometheus" created
configmap "catalog-prometheus-blackbox-exporter" created
configmap "catalog-prometheus-node-exporter" created
configmap "catalog-social" created
configmap "catalog-taiga" created
configmap "catalog-turbine-server" created
configmap "catalog-zipkin" created
configmap "catalog-zookeeper" created
configmap "exposecontroller" created
configmap "fabric8" created
configmap "fabric8-environments" created
configmap "nodejs" created
deployment "configmapcontroller" created
deployment "exposecontroller" created
deployment "fabric8" created
deployment "funktion-operator" created
The ConfigMap "catalog-letschat" is invalid: metadata.annotations: Too long: must have at most 262144 characters
Failed: exit status 1

Build - can't load package: package github.com/funktionio/funktion/cmd/operator

I'm trying to build funktion, but I hit a compilation issue:

./scripts/check_license.sh
touch .check_license
go build -o funktion -ldflags="-X github.com/funktionio/funktion/pkg/version.version=1.0.10 -s -w -extldflags '-static'" github.com/funktionio/funktion/cmd/operator
can't load package: package github.com/funktionio/funktion/cmd/operator: cannot find package "github.com/funktionio/funktion/cmd/operator" in any of:
	/usr/local/opt/go/libexec/src/github.com/funktionio/funktion/cmd/operator (from $GOROOT)
	/Users/clement/dev/golang/src/github.com/funktionio/funktion/cmd/operator (from $GOPATH)

funktion create --file should work!

thanks to @jcrossley3 for spotting this!

[jim@localhost blog-example]$ funktion create -h
This command will create one or more resources from the command one, a file, directory or URL

Usage:
  funktion create -f FILENAME [flags]
  funktion create [command]

Available Commands:
  flow        Creates a new flow which creates an event stream and then invokes a function or HTTP endpoint
  fn          creates a new function

Flags:
  -d, --debug               enable debugging for the function?
  -e, --env stringArray     pass one or more environment variables using the form NAME=VALUE
  -f, --file string         the file name that contains the source code for the function to create
      --kubeconfig string   the directory to look for the kubernetes configuration
      --namespace string    the namespace to create the resource
  -w, --watch               whether to keep watching the files for changes to the function source code

Use "funktion create [command] --help" for more information about a command.
[jim@localhost blog-example]$ funktion create fn --file $PWD
Error: unknown flag: --file
Usage:
  funktion create fn [flags]

Flags:
  -d, --debug               enable debugging for the function?
  -e, --env stringArray     pass one or more environment variables using the form NAME=VALUE
      --kubeconfig string   the directory to look for the kubernetes configuration
  -n, --name string         the name of the function to create
      --namespace string    the namespace to create the resource
  -r, --runtime string      the runtime to use. e.g. 'nodejs' (default "nodejs")
  -s, --source string       the source code of the function to create
  -w, --watch               whether to keep watching the files for changes to the function source code

unknown flag: --file

enable bash completion for commands

it'd be really nice to enable bash completion like we can do with kubectl when using the commands. particularly for things like the names of functions / flows / connectors but also for other commands like kinds etc

Consider formatting code with `gofmt`

Many Golang project use gofmt to consistently format their Go code. And, it's not uncommon to setup your editor to automatically run gofmt when saving changes to a file. Perhaps we should consider doing so as well?

manual install instructions

The installation instructions all seem to be based on funktion install. Some K8s installs however are in private networks without net access.

function edit always edits the last connector

I am following the Getting Started Guide to the point where I edit the twitter connector.

Then I derive from the script by trying to edit another connector:

funktion edit connector http4

and I get the twitter's properties instead. If I delete twitter and try again I get:

The connector `http4` has no properties to configure!%  

Extensive ConfigMap usage a problem in some OpenShift environments

When trying to deploy Funktion to an Openshift environment maintained by my IT department, I hit an issue with ConfigMap quotas. Just installing the platform creates a lot of catalog-* ConfigMap entries and every Function, Flow, and Connector installed adds more. In my case I have a quota of 20 ConfigMaps, which is fairly low, but even a much higher quota could quickly be hit.

Is there a way we could reduce overall ConfigMap usage without sacrificing functionality? Perhaps we could install the catalog-* ConfigMap entries from funktion install platform lazily as-needed instead of eagerly?

should we use a Secret for the application.properties?

The connector configuration frequently contains username, passwords, tokens and secrets. e.g. for the twitter component all the component properties should be secret

One day we may want to split the configuration between 2 resources; a ConfigMap and a Secret; with secret stuff only going into the Secret.

However for now - maybe just using a Secret instead of a ConfigMap for the connector configuration is simplest? It then makes sure the configuration is all secret?

support easier scaling of funktions + flows

right now when we modify a Function or Flow the operator updates the Deployment. So if you update the Deployment - for example to scale it - the replicas usually gets overwritten by the operator.

It'd be nice to make a fix to this though. e.g. maybe the operator preserves the replicas on the Deployment whenever its updating due to changes to the Function or Flow?

e.g. we want to be able to reuse auto scaling in kubernetes - so the operator shouldn't get in the way

When using OpenShift use oc vs. kubectl

It would be nice if funktion could use the oc command line interface that comes with OpenShift in addition to kubectl. Today this is what happens if you don't have kubectl installed and try to install the platform:

$ funktion install platform
created Namespace funktion-system
Could not find executable at /usr/local/bin/kubectl
kubectl apply --namespace funktion-system -f https://repo1.maven.org/maven2/io/fabric8/platform/packages/funktion-platform/2.4.21/funktion-platform-2.4.21-kubernetes.yml

would be nice if `funktion debug` could open the chrome-devtools browser window

I had an experiment using HTTP and HTML redirects or generating a link in HTML but it seems Chrome doesn't treat URLs of this form as being something you can use as a link or redirect:

chrome-devtools://devtools/bundled/inspector.html?experiments=true&v8only=true&ws=127.0.0.1:5858/5d8d25e3-855f-409e-9761-5acd220a7d89

So we maybe need to do something icky like on a mac using AppleScript or something?

Function start time benchmark - camel

Hi Everyone,

Great work on the system! Has anyone done testing on flow start time for camel?

I am trying to send error logs from Kafka to CouchDb via camel. They come any frequency from 1 second to 1 minute.

Thank you
Mark

when use "funktion" return "command not found"

os:centos7
i follow this " download the funktion binary for your platform and add it to your PATH environment variable."
i download this one "funktion-linux-amd64" (1.0.14)to dir"root" ,set PATH=$PATH:/root/funktion-linux-amd64 ,
when i put in "funktion" the return is "command not found"
but wen i put in "./funktion-linux-amd6" it works ,but cant install anything such as platform.
anybody who can help me , thanks

scalability concern

Containerized applications is a huge step forward in the evolution of apps development but based on virtualization limits I'm not so sure that this is scalable when you have e.g. 1 million functions. As quickly as you start splitting your monolithic application into micro apps, you get 100+ functions per project. As Kubernetes article explains you can run up to 100 functions per server and that's with scaling turned off (1 node).

I would appreciate a detailed description on how Funktion would scale this scenario. What would be the right hosting strategy? Thanks!

Kubernetes namespace creation should be handled diffferently under OpenShift

When running inside of OpenShift, users typically won't have permission to create new Kubernetes namespaces. Detecting OpenShift and creating new OpenShift projects (which creates a new Kube namespace) is one alternative, although many OpenShift installs have a limit on the total number of projects a user can have.

You can specify an existing namespace to use with funktion install platform to partially workaround this issue. But, the funktion-platform-2.4.21-kubernetes.yml file also tries to create a user-secrets-source-admin namespace which will fail under OpenShift.

provide a Test command to test a step

it would be nice to be able to choose a sample input message and to test out a single step in an existing flow. Eventually we could package this up as a REST API we can use from consoles but starting with a CLI would be great.

e.g. something like:

$ funktion test-step myflow 3 -f sampleMessage.json -oyaml
testing myflow step setHeader:foo=bar
output:
  foo: 1234

Under the covers we'd need to create a new temporary flow for something like:

funktion create flow mytmp http://localhost setHeader:foo=bar

i.e. pull out the step to be tested and add a http endpoint in front. Then the funktion test-step would wait for a pod to start, when its up, POST the sampleMessage.json to the pod's HTTP port and output/save the results (then removing the flow). We could use a temporary namespace for these 'tests' to avoid it confusing end users too?

Installing Funktion in OpenShift Origin

Hi,

I'm trying to install Funktion 1.0.10 into OpenShift Origin 1.4.1, but I got User "admin" cannot get namespaces in project "user-secrets-source-admin" error message.

$ oc login
... admin/admin ...

$ oc new-project xxx
...

$ funktion install platform --namespace xxx
oc apply --namespace xxx -f https://repo1.maven.org/maven2/io/fabric8/platform/packages/funktion-platform/2.4.24/funktion-platform-2.4.24-kubernetes.yml
serviceaccount "configmapcontroller" created
...
deployment "fabric8" created
deployment "funktion-operator" created
Error from server: User "admin" cannot get namespaces in project "user-secrets-source-admin"
Error from server: ConfigMap "catalog-letschat" is invalid: metadata.annotations: Too long: must have at most 262144 characters
Failed: exit status 1

Any suggestions on what could I do wrong here? :)

Error when trying the blog-example

The very first sample command fails (and I also tried several variations but to no avail):

funktion create fn -f examples/blog-example
Error: unknown shorthand flag: 'f' in -f
Usage:
  funktion create fn [flags]

Flags:
  -d, --debug               enable debugging for the function?
  -e, --env stringArray     pass one or more environment variables using the form NAME=VALUE
      --kubeconfig string   the directory to look for the kubernetes configuration
  -n, --name string         the name of the function to create
      --namespace string    the namespace to create the resource
  -r, --runtime string      the runtime to use. e.g. 'nodejs' (default "nodejs")
  -s, --source string       the source code of the function to create
  -w, --watch               whether to keep watching the files for changes to the function source code

unknown shorthand flag: 'f' in -f

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.