Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error:Execution failed for task ':backend:appengineEndpointsGetClientLibs

When adding a Google Cloud Endpoint backend to a Android app using the Google App Engine Java Module Template, two classes (amongst other things) are added to the project.

We are then encouraged to modify these classes to our own requirements. So, I decided to delete the model class (MyBean) and the endpoint class (MyEndpoint) and replace them with my own classes. When I tried to rebuild/clean the project, I get the error message:

 Error:Execution failed for task ':backend:appengineEndpointsGetClientLibs'.    
 There was an error running endpoints command get-client-lib:  
 <package-name>.MyEndpoint

I looked for a couple of hours for a solution to this problem until I found the cause.So I decided to share it since this question does not even exist on SO (Please correct me if I am wrong)

like image 961
Ojonugwa Jude Ochalifu Avatar asked Apr 13 '15 06:04

Ojonugwa Jude Ochalifu


1 Answers

Go to backend\src\main\webapp\WEB-INF\web.xml

In the web.xml file, look for the init-param and change the parameter value to the new endpoint class you've just added.

<init-param>
        <param-name>services</param-name>
        <param-value>com.mycompany.backend.New-Endpoint-Class-Name</param-value>
    </init-param>

Rebuild the project and everything should be just fine.

like image 198
Ojonugwa Jude Ochalifu Avatar answered Oct 23 '22 07:10

Ojonugwa Jude Ochalifu