[cdi-dev] do we like to define a DeploymentException type?

Martin Kouba mkouba at redhat.com
Mon Jun 18 03:17:46 EDT 2012


CDI 1.1 already has deployment-related exceptions - see CDI-118 [1].

Martin

[1]
https://issues.jboss.org/browse/CDI-118


Dne 16.6.2012 13:18, Mark Struberg napsal(a):
> Yes, was thinking in the same direction. We would still need to do this container specific detection for CDI-1.0 containers, but at least we would get a well defined behaviour for CDI-1.1.
>
> This would take a while until getting picked up though, as most Extensions will also aim to run on CDI-1.0 for a long time ...
>
> LieGrue,
> strub
>
>
>
> ----- Original Message -----
>> From: Jason Porter<lightguard.jp at gmail.com>
>> To: Mark Struberg<struberg at yahoo.de>
>> Cc: cdi-dev<cdi-dev at lists.jboss.org>
>> Sent: Friday, June 15, 2012 5:31 PM
>> Subject: Re: [cdi-dev] do we like to define a DeploymentException type?
>>
>> Having CDI define (even one) exception would be nice and would make testing
>> extensions for portability much easier. As it currently stands you have to test
>> for implementation specific exceptions.
>>
>> Sent from my iPhone
>>
>> On Jun 15, 2012, at 1:48, Mark Struberg<struberg at yahoo.de>  wrote:
>>
>>>   Hi!
>>>
>>>   While reviewing the DeltaSpike MessageBundleExtension, I (again) came to
>> the point where I didn't knew which Exception to take.
>>>
>>>
>>>   It might be nice to have a DeploymentException which indicates that a CDI
>> Extension detected a logical problem which is _not_ caused by some technical
>> problems.
>>>
>>>   E.g. if a certain annotation must not be used in conjunction with another
>> one. In our case @MessageBundle must only be used on Interfaces. We collect all
>> those problems during ProcessAnnotatedType and add them as
>> AfterBeanDiscovery#addDefinitionError.
>>>
>>>   A well defined DeploymentException could help indicating such
>> 'logical' problems, wdyt?
>>>
>>>   LieGrue,
>>>   strub
>>>
>>>   _______________________________________________
>>>   cdi-dev mailing list
>>>   cdi-dev at lists.jboss.org
>>>   https://lists.jboss.org/mailman/listinfo/cdi-dev
>>
> _______________________________________________
> cdi-dev mailing list
> cdi-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/cdi-dev


More information about the cdi-dev mailing list