Re: @Resource.mappedName processing
On Oct 23, 2007, at 9:50 PM, Jarek Gawor wrote: Some questions on @Resource.mappedName processing. When an ejb is deployed that has some @Resource annotated fields, OpenEJB will process them and create the appropriate resource-ref entires in the DD and pass it to Geronimo. But before the DD is passed into Geronimo the mappedName attributes of the entires are cleared (see EjbModuleBuilder.unmapReferences()). Why is that cleared? IIRC, when the original integration was going on (back in 2.0 m2) there were issues in the xmlbeans tree in Geronimo such that it didn't contain the mappedName element. As a workaround we had to clear the mappedName data out so things wouldn't blow up. We can probably delete the code in EjbModuleBuilder that clears them out. -David
Re: @Resource.mappedName processing
On 10/24/07, David Jencks [EMAIL PROTECTED] wrote: On Oct 23, 2007, at 9:50 PM, Jarek Gawor wrote: Some questions on @Resource.mappedName processing. When an ejb is deployed that has some @Resource annotated fields, OpenEJB will process them and create the appropriate resource-ref entires in the DD and pass it to Geronimo. But before the DD is passed into Geronimo the mappedName attributes of the entires are cleared (see EjbModuleBuilder.unmapReferences()). Why is that cleared? Is it because they are internally resolved to something OpenEJB specific? After the OpenEJB updated DD is passed to Geronimo, the Geronimo's Resource annotation processor kicks in and it now tries to process the annotation. But since the annotation is already in the DD, the DD entry is pretty much ignored. So the end result is that the mappedName attribute of the annotation never ends up in the DD. It's probably not a big deal now since AFAIK we don't use mappedName much but could become an issue in the future. So should we modify Geronimo's annotation processor to update the mappedName attribute of the DD entry? If not, how else should we handle this? If you want to modify the annotation processor to copy the mappedName into the xml that's fine with me but I'm not sure exactly what the point is since we don't use it for anything. If you want to suggest semantics for the mappedName we can certainly talk about that. Right, ok. Maybe I'll just file an issue in jira to record this and leave the code as is. Thanks, Jarek
Re: @Resource.mappedName processing
On Oct 23, 2007, at 9:50 PM, Jarek Gawor wrote: Some questions on @Resource.mappedName processing. When an ejb is deployed that has some @Resource annotated fields, OpenEJB will process them and create the appropriate resource-ref entires in the DD and pass it to Geronimo. But before the DD is passed into Geronimo the mappedName attributes of the entires are cleared (see EjbModuleBuilder.unmapReferences()). Why is that cleared? Is it because they are internally resolved to something OpenEJB specific? After the OpenEJB updated DD is passed to Geronimo, the Geronimo's Resource annotation processor kicks in and it now tries to process the annotation. But since the annotation is already in the DD, the DD entry is pretty much ignored. So the end result is that the mappedName attribute of the annotation never ends up in the DD. It's probably not a big deal now since AFAIK we don't use mappedName much but could become an issue in the future. So should we modify Geronimo's annotation processor to update the mappedName attribute of the DD entry? If not, how else should we handle this? If you want to modify the annotation processor to copy the mappedName into the xml that's fine with me but I'm not sure exactly what the point is since we don't use it for anything. If you want to suggest semantics for the mappedName we can certainly talk about that. thanks david jencks Jarek
@Resource.mappedName processing
Some questions on @Resource.mappedName processing. When an ejb is deployed that has some @Resource annotated fields, OpenEJB will process them and create the appropriate resource-ref entires in the DD and pass it to Geronimo. But before the DD is passed into Geronimo the mappedName attributes of the entires are cleared (see EjbModuleBuilder.unmapReferences()). Why is that cleared? Is it because they are internally resolved to something OpenEJB specific? After the OpenEJB updated DD is passed to Geronimo, the Geronimo's Resource annotation processor kicks in and it now tries to process the annotation. But since the annotation is already in the DD, the DD entry is pretty much ignored. So the end result is that the mappedName attribute of the annotation never ends up in the DD. It's probably not a big deal now since AFAIK we don't use mappedName much but could become an issue in the future. So should we modify Geronimo's annotation processor to update the mappedName attribute of the DD entry? If not, how else should we handle this? Jarek