Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

@Activate method not getting invoked

Avatar

Level 2

Dear All,

We have one service class with one @activate method  which is not getting invoked, But is working fine in other class of the same app. Is there a constraint that only one @activate can be used in one app-core?

 

Thanks in advance

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @NaziyaP 

Method with @Activate annotation will only be called once your Component(or Service) is activated. If Component has any dependencies it won't be activated hence your activate method won't be executed. Check if your Component/Service has any dependencies and try to resolve.

AG

View solution in original post

6 Replies

Avatar

Community Advisor

Hi @NaziyaP,

There is no constraints as such, can you please add code snippet/screenshot of class where this activate method is not getting invoked.

Avatar

Community Advisor

Please check logs for any errors and paste the code here

Avatar

Correct answer by
Community Advisor

Hi @NaziyaP 

Method with @Activate annotation will only be called once your Component(or Service) is activated. If Component has any dependencies it won't be activated hence your activate method won't be executed. Check if your Component/Service has any dependencies and try to resolve.

AG

Avatar

Level 4

There is no such constraint

Could you please go to systsem console and inder components tab go to your service and see if it is axtive or not not some refrences are in satisfied state.

If its not active it will not work, try to resolve dependencies.

Hope this helps