-
Notifications
You must be signed in to change notification settings - Fork 38.8k
Closed
Labels
in: coreIssues in core modules (aop, beans, core, context, expression)Issues in core modules (aop, beans, core, context, expression)type: regressionA bug that is also a regressionA bug that is also a regression
Milestone
Description
Dimitar Makariev opened SPR-10636 and commented
The described feature works on 3.2.1.RELEASE, fails on 3.2.2.RELEASE and 3.2.3.RELEASE.
Trying to change object instance passed to service defined as @Async :
@Service
public class PopulateService {
private final List<Person> persons;
private final AsyncService asyncService;
@Autowired
public PopulateService(AsyncService asyncService) {
persons = new ArrayList<Person>();
this.asyncService = asyncService;
}
public void populatePersons(int numberOfPersons) {
asyncService.populatePersons(persons, numberOfPersons);
}
public List<Person> getPersons() {
return persons;
}
}
@Service
public class AsyncService {
@Async
public void populatePersons(List<Person> persons, int numberOfPersons) {
for (int i = 0; i < numberOfPersons; i++) {
persons.add(new Person("first " + i, "last " + i));
}
}
} Affects: 3.2.2, 3.2.3
Attachments:
- testcase.zip (7.10 kB)
Issue Links:
- method demarcated with @Async isn't executed when precompiled [SPR-10715] #15343 method demarcated with
@Asyncisn't executed when precompiled
Metadata
Metadata
Assignees
Labels
in: coreIssues in core modules (aop, beans, core, context, expression)Issues in core modules (aop, beans, core, context, expression)type: regressionA bug that is also a regressionA bug that is also a regression