Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] [Java] Add "additionalModelTypeAnnotations" to enable using Lombok #2085

Open
2 tasks done
keks42 opened this issue Aug 7, 2024 · 3 comments
Open
2 tasks done
Labels
enhancement New feature or request stale

Comments

@keks42
Copy link

keks42 commented Aug 7, 2024

Why do we need this improvement?

In our project we use lombok, specifically @lombok.Builder for models. The openapi-generator for spring has an option to set Annotations for model classes ("additionalModelTypeAnnotations"). [1]

It would be helpful to have such an opportunity for async api model generation as well.

[1] https://openapi-generator.tech/docs/generators/spring/

How will this change help?

With this featuer we would be able to use Lombok consistently.

Screenshots

No response

How could it be implemented/designed?

A parameter could be added ("javaClassAnnotations" would be a better name in the context of this project) that takes a String which is copied into every java class just in front of the line "public class...".

Default should be an empty string which makes it backwards-compatible.

🚧 Breaking changes

No

👀 Have you checked for similar open issues?

  • I checked and didn't find a similar issue

🏢 Have you read the Contributing Guidelines?

Are you willing to work on this issue?

Yes I am willing to submit a PR, but as I don't have a lot of time, feel free to work on it!

@keks42 keks42 added the enhancement New feature or request label Aug 7, 2024
Copy link
Contributor

github-actions bot commented Aug 7, 2024

Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

@jonaslagoni
Copy link
Member

@keks42 if you want others to pick this issue up, I would suggest to add concrete output and the new output you are looking for 🙂

But it sounds like something presets can solve and happy to accept a PR ✌️

Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity 😴

It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation.

There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here.

Thank you for your patience ❤️

@github-actions github-actions bot added the stale label Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request stale
Projects
None yet
Development

No branches or pull requests

2 participants