Comments (2)
For Python, we can use filter to log the transaction information.
One question is that transaction ID is managed as an object, which also other implemented methods besides the id itself, in openwhisk core. Do we need the same approach or just an ID?
When and how do we generate the ID, if it is not something we can directly get?
from openwhisk-package-kafka.
This transaction ID will be specific to the feed provider. That is, it will only be used by the feed provider and will be different from any TID created by the OpenWhisk system. Because this feed provider operates independently of the OW core, it cannot possibly obtain a TID generated by the core.
It is at our discretion about when to create new TIDs, but it should be easy to identify these situations when we consider that the purpose of the TID is to de-interleave log messages. So the first rule of TIDs is: You only need a TID when there is a potential to interleave log messages. For a counter example, I don't think that any messages logged by the "doctor" thread need a TID, because the doctor is a single thread, and can't possibly result in interleaved log messages, so long as they are properly identified as being from the doctor - which they already are 😉
Similarly, the polling loop of each Consumer is already grouped by logging the ID of the trigger. And since each Consumer runs in its own unique thread, it is not possible for messages from the same Consumer to be interleaved with each other. As such, as long as the log message includes the trigger ID, then there is no need to generate a TID for (as an example) each Consumer, or each poll()
loop of each Consumer.
However, there is a need for a TID when a request to create or delete a trigger comes in. These are clearly separate "transactions" and can be interleaved. All log messages pertaining to the fulfillment of these requests should have a unique, but shared TID until each request is completed.
from openwhisk-package-kafka.
Related Issues (20)
- Binary Encoding causes Corruption HOT 2
- Handle Action Error HOT 2
- Improve logging in the kafkaFeedWeb.js
- Improve Promise usage by using chaining HOT 2
- Should decode not encode UTF-8 messages? HOT 11
- Confusing deprecation comment in doc HOT 5
- [Questions] Java based Kafka Producer to trigger OpenWhisk action HOT 8
- [Proposition] incubator-openwhisk-package-kafka/devGuide.md improvement HOT 3
- [Question] Setting up a localhost Message Hub package in a localhost environment HOT 2
- [Issue] The supplied authentication is not authorized to access 'whisk.system/messaging'. HOT 2
- Naming of Bluemix and MessageHub HOT 1
- Remove MessageHub references where possible and/or replace with "Event Streams" HOT 1
- Use authKey from action parameters instead of __OW_API_KEY
- Please provide example/alternative to deprecated messageHubProduce statement HOT 1
- gradlew test failure "Could not resolve all files"
- Support for subscribing to topic patterns
- Replaying messages already in topics
- Update actions from nodejs:6 to nodejs:10 HOT 5
- I have installed openwhisk-package-kafka, but I cannot find it under the /whisk.system/messaging path
- Kafka trigger not reading messages from Kafka
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openwhisk-package-kafka.