Both are the same in the sense that after they start, they will live until the application finishes (or the class is garbage collected, which will not happen in a typical Java EE application until you deploy it).
- Both are shared instances, and you must ensure that they are thread safe.
From Java EE 7 Tutorial
@ApplicationScoped General state for all users to interact with a web application.
From the Spring Documentation :
Spring singleton bean Singleton, Gang of Four (GoF). GoF Singleton , ClassLoader . Spring , bean. , bean Spring, Spring , bean.
, , , oneton bean - (, EAR -), Singleton bean bean / -, EAR) Spring -, ( bean Singleton Bean), .
, , Spring, JSF DI xml/ - . , (, , ).
, @Named @ApplicationScoped + , concurrency right = profit!:)