[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: Precedence

alesj do-not-reply at jboss.com
Fri Jul 6 11:37:45 EDT 2007


"adrian at jboss.org" wrote : 
  | What is relevant is that A inputs from C, so the correct orders is either
  | 1) C, A, B
  | 2) B, C, A
  | 3) C, B, A
  | 
  | (3) is obviously wrong since C and B are unrelated by attachment
  | they should be ordered by Ordered.COMPARATOR
  | but either (1) or (2) is correct.
  | 
  | The test assumes the following heuristic (which was true of the old sort): 
  | "Favour the order in which deployers are deployed".
  | 
  | i.e. Since B was deployed after A and there is no reason why B should be
  | sorted in front of A, therefore it always remains after A.
  | i.e. (1) is the correct order.

Why would (3) be wrong?
Do we really care if there is an unrelated one in the middle?

I'll see if I can document my heuristic. :-)

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

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



More information about the jboss-dev-forums mailing list