Wolf Siberski wrote: > I don't know if this is the expected result as specified by > the EJB spec (I suspect that this is a specification hole), > but I would not call that result "correct". > > In "design-by-contract"-speak: findByName( name ) has the > following postcondition: for each entity in the result set the > expression "result.getName().equals( name )" evaluates to "true". This may be true. However, the post-condition only holds _after the method has completed_, at which time the results will be written to the database, since we are talking about container managed transactions, here (I would consider method completion to include the container's work of writing the changes). Before the method is complete, the the post-condition will not hold. > No. The responsibility of "findByName" is to return all > entities with the specified name. If that can't be fulfilled > for implementation reasons (and I understand the implementation > problems well), the spec should at least state that > "calling finder methods after modifications of entity > beans in the same transaction yields undefined results" > or something like that. Perhaps this statement should be made as supplemental information, but the spec certainly does indicate that this will be the behavior, as it clearly describes the behavior of container-managed transactions. This is not a container implementation issue; it is an issue with the application. -Kevin
begin:vcard n:Lewis;Kevin tel;work:214-523-9061 x-mozilla-html:TRUE url:http://www.AxysSolutions.com/ org:Axys Solutions version:2.1 email;internet:[EMAIL PROTECTED] title:Middle-Reliever adr;quoted-printable:;;2911 Turtle Creek Blvd.=0D=0ASuite 300;Dallas;TX;75219; fn:Kevin Lewis end:vcard
