[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-07 Thread [EMAIL PROTECTED]
http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossHelp
Moderated: HIJACK

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3922029#3922029

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3922029


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-06 Thread jsports
jboss seam use bean as a datasoure

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921965#3921965

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3921965


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-06 Thread jsports
maybe jboss seam will provide a way?

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921961#3921961

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3921961


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-06 Thread jsports
for example,I will use MC with jboss portal.

Can portlet be a bean and defined in the jboss-beans.xml?or a servlet?

if can,that's will be easy.
else,
Beans defiend in jboss-beans.xml is hard to access in portlet in a simple way.

I think that is not the MC's aim.



View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921959#3921959

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3921959


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-06 Thread jsports
Direct access gives developer more freedom to controll his code and 
architecture,more room to design ,especaily for R&d. 



View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921953#3921953

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3921953


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2006-02-06 Thread jsports
Some time the direct call is more convenience and comfortable.

wounld you like to provide a  solution?

thanks in advance.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3921951#3921951

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3921951


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-12-22 Thread belaran
I know this thread is now old and that I haven't post anything but my work took 
me away from JBoss Microcontainer for a while But finally, I understand 
what Adrian meant in his examples, and why there is no "getBean()". The whole 
idea is quite simple, but given the fact that I had hard time with it, maybe 
other will, so i'll explain here what i finally understood.

Basicly my question was "how can i get my bean from the bootstrap in a simple 
"main' program ?" . In a small spring app, i would have done this :

  | public class MyApp
  | {
  |   public static void main(String[] args)
  |   {
  | ...
  | Component comp = context.getBean("component');   
  |   }
  | }
 

When i look at JBoss Container documentation and examples, i was looking for 
this kind of behavior. A method to call, something where my program could 
actually use the 'created bean'. And there I was wrong. As Adrian stated, the 
use of a '.getBean' method ruins the all concept of IoC as it tie the program 
to a specific API ( in this case Spring API). 

I agreed ( and i still agree) but i didn't see how to do without it, even when 
i look into the example. Then, it finally struck me ( i  know, i know i'm quite 
slow) : There is actually no need for my program to get beans from the 
microcontainer as my program is another bean managed by the container. At the 
bootstrap , the microcontainer will create my program and execute its 
initialisation method ( or simply its constructor) and there the program 
actually start. So there is no 'main', no need to actually get the bean for the 
program. The progam is a POJO and its dependancies are resolved by the 
container !
We simply launch the bootstrap instead of the program.

Now this all seems so clear, i almost feel stupid...  : / 
I hope that this post will help other, stuck in the same misconception... ( 
otherwise this post will simply be another public humiliation).

Thanks again Adrian !






 

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3913975#3913975

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3913975


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-11-03 Thread belaran
"[EMAIL PROTECTED]" wrote : 
  | "Don't tie yourself to a spec defined locator, use our proprietary api 
instead?" :-)
  | 

: D 

Thanks ! I'll watch the code, the two link your provided me should be enough if 
i'm not too dumb...

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3905089#3905089

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3905089


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-11-02 Thread [EMAIL PROTECTED]
That unit test helper class with examples will be included in the next 
(1.0.2 - still unscheduled) release of the microcontainer.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3905033#3905033

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3905033


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-11-02 Thread [EMAIL PROTECTED]
"belaran" wrote : 
  | However, while doing my research an Spring and Hivemind, i found a lot of 
critics against the use of JNDI locator, which tends to tie the webApp to the 
locator, making portability and unit test not simple [ that is what i read,not 
an opinion ].
  | 

So let's rephrase it - although I doubt they were talking about getBean()
and more advocating IOC.

"Don't tie yourself to a spec defined locator, use our proprietary api 
instead?" :-)

anonymous wrote : 
  | So let's say for the purpose of the exercice that we agree that Locator is 
not an option, how can we get back the Bean from the Microcontainer ?
  | 

See the link to the code I posted or read this:
http://www.jboss.com/index.html?module=bb&op=viewtopic&t=70357

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3905029#3905029

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3905029


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-11-02 Thread belaran
First of all, thanks you Adrian for all your response. Sorry I didn't reply 
sooner.

About doing a Spring facade, i believe that will be a great idea but I don"t 
know if I got what it's take to do it. I'm still pretty new to all this and the 
person(s) doing this job should be very good with both IoC Framework. However, 
I'll consider the challenge...

anonymous wrote : I strongly discourage this usage. It defeats the whole point 
of IOC. 

I agree completly with you. The method "getBean' is, the way I see it, just a 
way to make test while trying the Spring framework...

However, while doing my research an Spring and Hivemind, i found a lot of 
critics against the use of JNDI locator, which tends to tie the webApp to the 
locator, making portability and unit test not simple [ that is what i read,not 
an opinion ].

So let's say for the purpose of the exercice that we agree that Locator is not 
an option, how can we get back the Bean from the Microcontainer ?


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3904840#3904840

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3904840


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-10-31 Thread [EMAIL PROTECTED]
"[EMAIL PROTECTED]" wrote : 
  | The xml/deployment is just a facade/convenience over the kernel controller.
  | 

If you are interested, there is an open feature request to create a Spring 
facade.
i.e. Spring xml -> JBossXB parser->JBoss MC metadata
and not just for Spring:
http://jira.jboss.com/jira/browse/JBMICROCONT-26

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3904456#3904456

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3904456


---
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-10-31 Thread [EMAIL PROTECTED]
"belaran" wrote : I read the microcontainer getting started. I can see that 
most features of the spring core are reproduced here

Actually it is an independent invention. 

The microcontainer is based on JBoss's JMX kernel, which predates Spring
by a number of years.

I was persuaded to use some of Spring's xml names,
e.g. property instead of attribute (although some of the class names still 
contain the old names)
and I did steal  when Scott pointed out this was missing. :-)

I think we also have some features that are not in Spring? 
I don't know for sure I've never directly used Spring. :-)

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3904449#3904449

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3904449


---
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Microcontainer] - Re: How to access beans created by the bootstrap

2005-10-31 Thread [EMAIL PROTECTED]
I strongly discourage this usage. It defeats the whole point of IOC.

To me, these examples from Spring represent a failure. i.e. a fallback to the 
old
service locator pattern because of a lack of thought. 

There are other service locators (such as jndi) that make your code much more 
portable across frameworks.

The xml/deployment is just a facade/convenience over the kernel controller.

Sometimes the direct access cannot be avoided, usually laziness or no 
requirement
to not depend on the framework, e.g. unit tests
http://anoncvs.forge.jboss.com/viewrep/~raw,r=1.4/JBoss/microkernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3904447#3904447

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3904447


---
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user