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

  • SEARCH
  • Home
  • 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 4014868
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T09:32:57+00:00 2026-05-20T09:32:57+00:00

I keep reading everywhere that when you ask for dependencies to be injected in

  • 0

I keep reading everywhere that when you ask for dependencies to be injected in a bean, you are injected a proxy to an instance of that resource. I believe I know what a proxy is, its an instance that knows how to forward messages to another instance. It’s also stated that it is this pattern that allows the container to provide services to this managed beans.

I don’t understand this quite well. Why is a proxy necessary? And how is this implemented? is there a proxy object for each bean? or do i have many proxies forwarding to one instance? or maybe neither?

Also, from the book design patterns from the GoF, I’ve read that you have to provide a proxy class that acts as a placeholder. But I never do that in Java EE, does the application server create proxy class during runtime?

  • 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-20T09:32:57+00:00Added an answer on May 20, 2026 at 9:32 am

    The essential assumption behind the proxy pattern is that you should not have to care about it from a “user” point of view. The proxy masquerades as the declared type and should behave the same way. The added value comes from what the proxy does before or after it forwards or returns calls to the target instance. This is how e.g. transactions and security are implemented in the container.

    As for the added question: Yes, the application server creates those proxy classes when necessary.

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

Sidebar

Related Questions

I keep reading about C99 and C++11 and all these totally sweet things that
I keep reading about people who are test infected, meaning that they don't just
I keep reading that, in C, using pointer arithmetic is generally faster than subscripting
I mostly use Java and generics are relatively new. I keep reading that Java
I keep reading about how great this new Canvas element for HTML5 is and
You'd think it would be easy, but keep reading. I can change many of
Keep in mind that I'm not looking for a list of current browsers to
I keep getting tasks that are above my skill level. How can I address this without coming accross as grossly incompetent?
I keep running across this loading image http://georgia.ubuntuforums.com/images/misc/lightbox_progress.gif which seems to have entered into
I keep hearing from associates about grid computing which, from what I can gather,

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.