-
Notifications
You must be signed in to change notification settings - Fork 5k
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
CAMEL-20333 Camel Kotlin API #12786
CAMEL-20333 Camel Kotlin API #12786
Conversation
I added some documentation for all of this, may be that will be helpful in undestanding whats going on in this PR |
As far as i can see from logs, there is a problem in |
79bce44
to
c32dd0c
Compare
This is a massive PR. Can you tell more what is the purpose. Can you make an example of what you can do today with camel and kotlin, and say why you need this, and what it will make better. Kotlin has java interoperability so I would assume it works fine with existing java api, endpintdsl and whatnot. |
This is just yet another DSL for Camel, nothing more. I looked at what is done in existing Camel Kotlin DSL and found that Kotlin type-safe builders are used for defining beans and REST parts of configuration and arent used in other places. "Why?" - i had thought. And made fully Kotlin-ish thing. Massiveness comes only from huge number of components and EIPs - code is just copy-paste. There is nothing you cant do in Kotlin with Camel cause of Java interop. But this PR makes Camel more "native" for Kotlin ecosystem of tools. Also it provides an abitily to define routes using only CamelContext as input, without need in explicit RouteBuilder instantiation. So i consider the first question of that PR: is it suitable with Camel development vision? It not, PR should be rejected as irrelevant, i think. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This look interesting, my only point is related to maintenance. We could merge this and make it available to users, but who will maintain this Koltin DSL? My concern is related to the fact we might not have the capacity to support this DSL too. Nevertheless for me this should be part of the DSLs as experimental and it would be interesting to see it in action in a guest blog post on Camel website. What others think?
Yes its massive and great work to generate the DSLs and update the regular DSL to be more Kotlin like. But the users get the best experience with the standard DSLs that we have tooling and you can find the most examples and help with. |
@iMashtak are you interrested to stay active in the Camel community and keep contributing, and become a committer, and help maintain this Kotlin DSL and whatelse. |
Thank you for offer, i am interested. What should i do to become committer? |
Sounds good. You keep contributing and doing great. The Camel PMC will then invite you in as a committer later. |
We have updated the model DSL a little bit with more variables stuff. Not sure if this PR needs to be regenerated and updated. |
Also in camel-kotlin-api/pom.xml can you set
If not already done |
Support level has already been set, made regen, |
We have done a bit more work on the model with the languages - so this PR maybe needs to be updated. |
Fixed all issues with languages I have broken time in WSL, so my commits come from future :D |
I made Language DSL - autogen for all existing languages. Will commit tomorrow. Seems like i cant generate only model classes - EIPs and so on. As for EIPs. Feels like i need handmaided config that will describe which classes (inheritors of ProcessorDefinition) i should analyze. Maybe later i will find the way. |
Ok, language DSL is done, nothing more to commit |
We did some changes in the model today
Can this PR be updated and generated with latest code |
and btw those are the last expected model changes. So after that we should be ready for your PR |
…tor of Endpoint DSL and DataFormat DSL
…teBuilder API, added intercepts and error handling
Thanks, can you update the PR as there was a new option so there is uncommitred code changes and the CI cannot do a full test.
|
I wonder if you can make the maven plugin to only output "Generating Language DSL for simple" ... when there was some changes. Its very verbose when nothing is changed. We are doing this for the other DSLs |
4e07c23
to
739dcec
Compare
Also your unit test classes should be renamed from |
Checklist:
Questions:
kamelet
EIP in this PR? Can i delay that functionality for later time? As far as i understand,kamelet
is purposed for calling route templates, am i right?