I have seen a few instances with the following error:
"System.ArgumentException: The endpoint associated withcontract :HcmMassBenefitExpirationEngine is not found.
at Microsoft.Dynamics.Ax.WCFDynamicProxy.DynamicProxyFactory.GetEndpoint(StringcontractName, String contractNamespace)
at RunAsync(interpret* ip)"
This error occurs when trying mass expire a benefit. The following steps will help you to allow this benefit to use the mass expiration functionality.
1. Click on AOT | Service Groups | HCMServices. Right Click on HCMServices and select Deploy Service Group
2. Once the deployment has completed, close the info log.
3. Click on AOT | Data Dictionary | Tables | AIFPortActionPolicy. Right click on the AIFPortActionPolicy Table and select Open.
4. We now need to create new record to enter the HCMMassBenefitExpirationEngineService.runExpirationProcess.
Press Control + N on the keyboard to add a new line.
In the Action ID field, select HCMMassBenefitExpirationEngineService.runExpirationProcess.
In the Port field, select AxClient
5. Save the record and close the form.
6. Close the Developer Workspace.
7. Click System Administration | Setup | Services and Application Integration Framework | Inbound Ports.
8. Select HcmService and click Deactivate. Once the deactivation is complete, click Activate to re-activate the service.
9. Select AxClient and click Deactivate. Once the deactivation is complete, click Activate to re-activate the service.
10. Close the Inbound Ports form.
11. Click on Human Resources | Common | Benefits | Benefits.
12. Select the Benefit you wish to mass expire and click on Mass Benefit Expiration.
13. Click on Expire.
As we can see, we were now able to mass expire the benefit.
I followed your instructions and it did fix this error, but actually there's an easier way, which worked for me on another box with the same issue.
Just re-deploy the AxClient service group, and it will create the entry for the mass expiration service action on the AxClient endpoint (which is what you do manually through the table browser on AifPortActionPolicy in your instructions)
That was enough in my case to resolve the issue, as ultimately that's what causes the error message to show. You don't need the HcmServices service group to be deployed at all for this functionality to work successfully.