Giter Club home page Giter Club logo

app-functions-sdk-go's People

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

Watchers

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

app-functions-sdk-go's Issues

SDK needs to log trace Correlation ID messages

At a minimum the SDK should log trace correlation ID messages when the events are received and when they are published.

From Boston F2F notes:
The SDK should allow tracing of execution into and out of the application service but not into and out of each function –via the correlation ID

Device Virtual's device profile changes the cause Advanced example error

Something has changed with the default decoding of float values causing the following errors in the advanced sample:

level=ERROR ts=2019-06-06T08:41:25.034644884Z app=AppFunctionsSDK source=convert.go:48 msg="Unable to Base 64 decode float32/64 value ('3.840383e+307'): illegal base64 data at input byte 1"
level=ERROR ts=2019-06-06T08:41:25.042110489Z app=AppFunctionsSDK source=convert.go:65 msg="Unable to decode float64 value bytes: EOF"

Add ability to un-marshal custom type from message bus to start function pipeline

Currently the App functions SDK expects the data pulled from the message bus to be an EdgeX Event. This require and data that is pushed back to the message bus under a different topic to be wrapped in a dummy event.

Proposed solution is to allow the App Service to initialize the SDK with a custom type to be used when un-marshaling the data. If not specified, the SDK uses EdgeX Event.

Edinburgh Release - Update go.mod for modules

Once the following modules are tagged to v0.1.0 update the edgex-go go.mod and submit the PR. This will be the final task before the edinburgh branch is cut.

go-mod-core-contracts
go-mod-messaging
go-mod-registry

Config file format

I notice this SDK uses JSON for configuration but everywhere else we use TOML. Probably want to change this to TOML

examples/config.json

Need Example App Service that processes CBOR encoded data

device-simple from device-sdk-go now produces CBOR encoded data. It sends a png image of an on light bulb and a jpg of an off light bulb.

A example app service that receives these images is needed to demonstrate CBOR end to end.

Add support to un-marshal CBOR messages

When incoming messages are can now be either JSON or CBOR. The Message Envelope has the ContentType of the message to determine if it is JSON or CBOR. Un-marshal the CBOR encode message needs to be added.

Change import paths to edgexfoundry

The import paths in some of the code refers to github.com/edgexfoundry-holdings... Holding should be singular, but regardless just make this github.com/edgexfoundry.... This will make the move over to the real repo easier and makes it easy for reviewers that want to clone this into their GOPATH.

Initialize go.mod

The SDK should be published as a module, similar to the device-sdk-go. In addition, any dependencies should be managed accordingly using the new go module approach.

Use of os.Exit() in appsdk.MakeItRun()

appsdk.MakeItRun() calls os.Exit(0) (src/github.com/edgexfoundry/app-functions-sdk-go/appsdk/sdk.go:191) which prevents the defer close(httpErrors) statement from executing. It also prevents any SDK-based application from executing clean up code after appsdk.MakeItRun() returns.

Based on 4b9771a.

Add running "go fmt" to "make test" in makefile and run it

go fmt is required to be run for all PRs. To enforce this we are adding running go fmt to the test target in all makefiles. As part of doing this effort make test should be run to ensure all go files are formatted so that subsequent PRs don't have changes to unrelated files just for formatting.

Examples should be based on data from the new Device Virtual Go device service

Currently the simple example filter on Devices Name(s) from the old Java Device Virtual. These need to be changed to Device Name(s) from the new Go Device Virtual. Specifically, use Random-Float-Generator01 and/or any of the other device names. Not that the postman json file must also be updated with proper event data for the new virtual device(s)

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.