candlerb opened a new issue #5520: Missing documentation for window functions
URL: https://github.com/apache/pulsar/issues/5520
 
 
   **Describe the bug**
   There is no documentation for window functions, and no python examples for 
window functions.
   
   **To Reproduce**
   Search for "window" in the docs (site2).
   
   It's mentioned in passing:
   
   > A Java function listens for the sanitized-sentences topic, counts the 
number of times each word appears **within a specified time window**, and 
publishes the results to a results topic
   
   (my emphasis)
   
   In some CLI flags:
   
   ```
   ./docs/functions-cli.md:sliding-interval-count | The number of messages 
after which the window slides. |  |
   ./docs/functions-cli.md:sliding-interval-duration-ms | The time duration 
after which the window slides. |  |
   ./docs/functions-cli.md:window-length-count | The number of messages per 
window. |  |
   ./docs/functions-cli.md:window-length-duration-ms | The time duration of the 
window in milliseconds. | |
   ```
   
   And in a reference to release notes:
   
   > * Add Windowfunction interface to functions api 
[#3324](https://github.com/apache/pulsar/pull/3324)
   
   **Expected behavior**
   N/A
   
   **Screenshots**
   N/A
   
   **Desktop (please complete the following information):**
   N/A
   
   **Additional context**
   This functionality is really interesting to me, and I'd like to know (a) 
what it can do, and (b) if I can use it from python.
   
   I'm particularly interested if it's possible to do e.g. a ten-minute rolling 
window, where I can add 1 to an internal counter for an event which enters the 
window, and remove 1 from a count when that event leaves the window, thus 
maintaining a running count.
   
   It could be done without external support, but would require in-RAM 
buffering for all events over than 10 minute window - but buffering is what 
pulsar is for :-)
   
   Externally I could maintain two readers: one at the current location and one 
at T-10 mins.  But that wouldn't work as a pulsar function AFAICS.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to