Hi, Jim.

Sorry I don't understand what you mean. Does Java 5 make a difference here?

Assuming the java interface for the service is "mypkg.MyInterface" and the component name is "MyComponent", which one should we use?

1) <reference name="myRef">MyComponent/mypkg.MyInterface</reference>
2) <reference name="myRef">MyComponent/MyInterface</reference>

Thanks,
Raymond

----- Original Message ----- From: "Jim Marino" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, January 10, 2007 3:36 AM
Subject: Re: Bug in deriving the service name from a java interface?


Not if we use Java 5.

Jim

On Jan 9, 2007, at 2:11 PM, Raymond Feng wrote:

Hi,

Does it imply that if we want to reference such a service, we need to use the following syntax now?

<reference name="myRef">MyComponent/mypkg.MyInterface</reference>

Thanks,
Raymond

----- Original Message ----- From: "Jim Marino" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, January 08, 2007 11:35 PM
Subject: Re: Bug in deriving the service name from a java interface?



On Jan 8, 2007, at 3:52 PM, Raymond Feng wrote:

Hi,

The SCA Java C&I Spec says: "The service names of the defined services default to the names of the interfaces or class, without the package name."

So I assume for the following annotation:

@Service(interfaces = {MyListService.class, MyListServiceByYear.class})

We're going to have two services named as "MyListService" and "MyListServiceByYear".

The current code seems to use the fully-qualified class name as the service name. As a result, if we use <componentName>/ <serviceName> as a wire target, it will throw a "TargetServiceNotFoundException". Is this a bug?

I switched this over a while back as I think we should a raise an issue in the spec. If we don't qualify the name, it is not possible for a component to implement two services with the same simple name. I relieve it is an edge case but we should be able to accommodate that since it is valid Java.

Jim

Thanks,
Raymond

-------------------------------------------------------------------- -
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to