Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [faces-dev] Faces 4.1 M2 upcomming

Hi,

On Thu, 7 Mar 2024 at 03:20, hantsy bai via faces-dev <faces-dev@xxxxxxxxxxx> wrote:
I have a question, if the Faces built-in IOC is removed and use CDI as default, will it work with Spring in future?

That built-in facility has been removed a long time ago (in Jakarta EE 10), and we fully deprecated everything even longer (in Java EE 8 / JSF 2.3). It works with Spring, as there CDI simply replaced the built-in facility, while the business logic there remains to be Spring beans. So instead of having JSF using JSF Managed Beans in a Spring app calling out to Spring beans for business, you now have Faces using CDI "Managed Beans"  in a Spring app calling out to Spring beans for business.

From the point of view of a Spring app, both JSF Managed Beans and CDI "Managed Beans" are alien.

In the latter case there's a bit of extra integration work to do to keep the two apart, but it's doable as both technologies can veto and/or exclude scanning. I always hoped we could create an integration library (and/or add something to JoinFaces) for this.

Kind regards,
Arjan Tijms


 
---

Regards,

Hantsy Bai

Self-employed consultant, fullstack developer, agile coach, freelancer/remote worker

GitHub: https://github.com/hantsy

Twitter: https://twitter.com/@hantsy

Medium: https://medium.com/@hantsy


On Thu, Mar 7, 2024 at 12:15 AM Arjan Tijms via faces-dev <faces-dev@xxxxxxxxxxx> wrote:
Hi,

On Wed, 6 Mar 2024 at 11:11, Joaquim Hangalo via faces-dev <faces-dev@xxxxxxxxxxx> wrote:
Thanks for the clarification.
Therefore, the old managed Beans were replaced by CDI, but we can use the _expression_ "Managed Beans" to talk about CDI when used at the Jakarta Faces level

Old managed beans (aka native jsf managed beans) were fully removed see https://jakarta.ee/specifications/faces/4.0/jakarta-faces-4.0#backward-compatibility-with-previous-versions

We did leave some traces of the term here and there, which are spec bugs. It's really good you mentioned this, so I'll take a look to remove them fully. The term "managed bean" was a bit overloaded. There were the JSF native ones, but also a pseudo super spec that made a lot of things in Jakarta EE managed beans (an attempt to unite all different component models), but this one failed / was overshadowed by CDI.

I think we mostly just call the CDI beans in Jakarta Faces "beans" or when they sit behind a page specifically a "backing bean".

Kind regards,
Arjan Tijms



 
_______________________________________________
faces-dev mailing list
faces-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/faces-dev
_______________________________________________
faces-dev mailing list
faces-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/faces-dev

Back to the top