Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

execute @Before and @After aspect for Runnable.run method which invoked through lambda expression. [SPR-16680] #21221

Closed
spring-projects-issues opened this issue Apr 2, 2018 · 1 comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) status: invalid An issue that we don't feel is valid

Comments

@spring-projects-issues
Copy link
Collaborator

Manoj Kumar opened SPR-16680 and commented

How to create a pointcut for Runnable.run method So that @Before and @After aspect can be invoked in java 8 lambda expression.

  1. Create pointcut for Runnable.run method
  2. Create @Before aspect for pointcut in step 1 . ---> Print Before runnbale
  3. Create @Aefore aspect for pointcut in step 1 . ---> Print After runnable

When below line invoked

executor.runAsync(() -> {
System.out.println("Runnable invoked");
})

Output expected :

Before runnable
Runnable invoked
After runnable


No further details from SPR-16680

@spring-projects-issues
Copy link
Collaborator Author

Juergen Hoeller commented

I'm afraid this is not a bug report or concrete enhancement request but rather a question that is better off at StackOverflow.

@spring-projects-issues spring-projects-issues added type: bug A general bug status: invalid An issue that we don't feel is valid in: core Issues in core modules (aop, beans, core, context, expression) and removed type: bug A general bug labels Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) status: invalid An issue that we don't feel is valid
Projects
None yet
Development

No branches or pull requests

1 participant