[ 
https://issues.apache.org/jira/browse/AVRO-1342?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dmitry Kovalev updated AVRO-1342:
---------------------------------

         Priority: Major  (was: Minor)
    Fix Version/s: 1.7.8
       Issue Type: Bug  (was: Improvement)

I would argue that it can actually be classified as a bug, and a fairly major 
one, because:

a) it breaks the implicit contract of FindType method which accepts bool 
throwError as parameter and is not supposed to throw if it is set to false

b) while it works with "clean" setup, it almost always throws in a "real-life" 
enterprise environment, for example when Avro is used in an Excel add-in which 
is hosted in Excel executable together with a few other add-ins targeting 
different .NET platforms - and thus makes it unusable

I have submitted a patch which attempts to collect all exception information,  
log it, and then re-throw but only if the type was not found and throwError was 
set to true. This handling also should have made redundant the hard-coded check 
for Mono, so I have removed it as well.

Please could you review and include in the next release.


> ObjectCreator fails if bad assemblies loaded
> --------------------------------------------
>
>                 Key: AVRO-1342
>                 URL: https://issues.apache.org/jira/browse/AVRO-1342
>             Project: Avro
>          Issue Type: Bug
>          Components: csharp
>    Affects Versions: 1.7.4
>         Environment: Windows, Visual Studio
>            Reporter: David Taylor
>             Fix For: 1.7.8
>
>         Attachments: AVRO-1342-csharp-ObjectCreator-fix.patch, 
> continue-on-exception.diff
>
>
> When iterating over the list of assemblies in ObjectCreator.cs the GetTypes() 
> call can fail with an exception if there is a load error on an assembly.  
> Currently this exception is propagated but really does not need to be.  I 
> think a more reasonable approach is to note the error and then try the next 
> assembly. 



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to