You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/08/13 09:57:47 UTC

[GitHub] [shardingsphere-elasticjob] CherishCai opened a new issue #1961: Feature: ElasticJobListener has an order or Reverse order call afterJobExecuted().

CherishCai opened a new issue #1961:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/1961


   ## Feature Request
   
   **For English only**, other languages will not accept.
   
   Please pay attention on issues you submitted, because we maybe need more details. 
   If no response anymore and we cannot make decision by current information, we will **close it**.
   
   Please answer these questions before submitting your issue. Thanks!
   
   ### Is your feature request related to a problem? Describe the feature you would like.
   
   JobConfiguration can set multiple ElasticJobListeners, In some scenarios, it is expected that this listener will be triggered sequentially, and perhaps the front and rear listeners have related dependencies.
   
   So, 
   1. Maybe ElasticJobListener has an order,
   
   
   2. Or Reverse order call afterJobExecuted().
   ```java
   @Override
       public void beforeJobExecuted(final ShardingContexts shardingContexts) {
           for (ElasticJobListener each : elasticJobListeners) {
               each.beforeJobExecuted(shardingContexts);
           }
       }
       
       @Override
       public void afterJobExecuted(final ShardingContexts shardingContexts) {
           for (int i = elasticJobListeners.size() - 1; i >= 0; i--) {
               elasticJobListeners.get(i).afterJobExecuted(shardingContexts);
           }
       }
   ```
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere-elasticjob] CherishCai closed issue #1961: Feature: ElasticJobListener has an order or Reverse order call afterJobExecuted().

Posted by GitBox <gi...@apache.org>.
CherishCai closed issue #1961:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/1961


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere-elasticjob] CherishCai commented on issue #1961: Feature: ElasticJobListener has an order or Reverse order call afterJobExecuted().

Posted by GitBox <gi...@apache.org>.
CherishCai commented on issue #1961:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/1961#issuecomment-899979852


   Oh, I'm sorry, I already mentioned it. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere-elasticjob] CherishCai commented on issue #1961: Feature: ElasticJobListener has an order or Reverse order call afterJobExecuted().

Posted by GitBox <gi...@apache.org>.
CherishCai commented on issue #1961:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/1961#issuecomment-899982504


   Like this: #1943. So close.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere-elasticjob] sunkai-cai commented on issue #1961: Feature: ElasticJobListener has an order or Reverse order call afterJobExecuted().

Posted by GitBox <gi...@apache.org>.
sunkai-cai commented on issue #1961:
URL: https://github.com/apache/shardingsphere-elasticjob/issues/1961#issuecomment-899173098


   Hi @CherishCai 
   
   Thanks for your proposal, the ElasticJobListener supported it in the next version. look at this: https://github.com/apache/shardingsphere-elasticjob/pull/1943.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org