spring-cloud / spring-cloud/spring-cloud-stream

Could spring stream add a annotation "StreamFunction" ?

Open
#2,247 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

waiting-on-feedback
Dominant language
Java
Stars
1.1k
Forks
646
Avg merge
2d 3h
Merged PRs (30d)
8

Description

Add a annotation StreamFunction, indicate some function is used in stream. Avoid centralized configuration of spring.cloud.function.definition
For example:
`
@Bean
@StreamFunction
public Function<String, String> toUpperCase() {
return s -> s.toUpperCase();
}

@Bean
@StreamFunction
public Supplier date() {
return () -> new Date(12345L);
}
`

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the issue's StreamFunction examples and the existing spring.cloud.function.definition configuration. Determine how annotated Function and Supplier beans should be discovered and how their stream bindings would be selected. Done should include the annotation behavior for both examples without requiring centralized configuration.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring
Domain
backend, stream-processing
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.