Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 920381
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T18:42:13+00:00 2026-05-15T18:42:13+00:00

JSR-250 says all @Resource annotated methods will be called before the @PostConstruct method.. My

  • 0

JSR-250 says all @Resource annotated methods will be called before the @PostConstruct method..

My question is:

Does that mean that all @Resource annotated methods on all beans in a context will be called before any @PostConstruct annotated methods are called?
Or in other words can a beans @PostConstruct method be called once its dependencies have been injected even if other beans in the context still haven’t had there dependences injected?

Regards,
Tim.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T18:42:13+00:00Added an answer on May 15, 2026 at 6:42 pm

    It is guaranteed that when a given bean’s @PostConstruct gets called, that all of its @Resource fields will have been injected. If any of those injections are themselves beans with their own @Resource and @PostConstruct, then those will have already been called. In other words, by the time any given @PostConstruct is called, it is guaranteed that all of its dependencies have been fully initialized.

    It is possible, and in fact likely, that BeanA will be constructed and initialized via @PostConstruct before BeanB has even been instantiated, if BeanB has no expressed dependency on BeanA.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a data transfer object that's annotated with JSR-303 constraints like... public class
What is the relevance of JSR and how does one optimize it for one's
JSR-299 (CDI) introduces the (unfortunately named) concept of a resource: http://docs.jboss.org/weld/reference/1.0.0/en-US/html/resources.html#d0e4373 You can think
JSR-296 (Swing Application Framework) is no longer developed and will not become part of
How can I use JSR-299 CDI to inject (not annotated) beans from external libraries?
I know that Spring 3 supports JSR-286 (portlets version '2.0'). However I can't find
It seems JSR 292 will add support for dynamic languages to the JVM but
I have a host device that connects to anything running JSR-82. The problem is
I'm trying to deploy a JSR-286 portlet application that has its own lucene version
I am writing a JSR-168 portlet that can be added to a container multiple

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.