Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Issue deploying the edge-developer-training-backend proxy

Hi, I am going through the coursera course "API Design and Fundamentals of Google Cloud's Apigee API Platform", and I am having an issue when trying to setup the backend proxies in my environment for the labs.

Initially I had an access issue since it's my work computer and I installed the "setup" folder under C\program files, which required permission. After rextracting the "setup" folder to a more eneric path, the install went through, after running "npm install" again in new "setup" path.

Then I executed "node setup" and even though is started the install and it went through mostly ok, it threw 2errors, which I am not sure they are critical or not. Could you please help? Do I need to reinstall something or can I move on?

[...] -> first error in the middle of the download

Downloading from central: http://repo1.maven.org/maven2/org/apache/commons/commons-parent/35/commons-parent-35.pom Downloaded from central: http://repo1.maven.org/maven2/org/apache/commons/commons-parent/35/commons-parent-35.pom (58 kB at 434 kB/s) Downloading from central: http://repo1.maven.org/maven2/org/apache/apache/15/apache-15.pom n.Downloaoderdg fro/m central: http://rmeapvo1.maven.oen2/rgo/rmg/aavpean2/ocrgh/apaceh/ec/oampmaconhse//1c5/oapacmhmeo-n1s5.pom (1-5 kBp aart 142e kB/s)n t/35/commons-parent-35.pom (0 B at 0 B/s) Downloading from central: http://repo1.maven.org/maven2/org/bouncycastle/bcprov-jdk15on/1.55/bcprov-jdk15on-1.55.pom Downloading from central: http://repo1.maven.org/maven2/org/bouncycastle/bcprov-jdk15on/1.55/bcprov-jdk15on-1.55.pom Downloaded from central: http://repo1.maven.org/maven2/org/bouncycastle/bcprov-jdk15on/1.55/bcprov-jdk15on-1.55.pom (1.2 kB at 9.2 kB/s) [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 36.D83o7wn lsoa aleIdNFO] Finished at: 2019 -06-07T15:44fr:o4m2+ 0c2e:n0t0r :[ httIpN:F/O/r]e po-1-.-m--a--v-e-n-.-o-r-g-/-m-a-v-e-n2-/-o-r-g-/-b-o-uncy-c-as--tle/b-cp-r-o-v---j-d-k-1-5-o-n-/-1-.-5-5-/-b-c-p-r-o-v---j-dk-1-5-o-n---1--------. [ERROR]5 Failed to execute goal io.apigee.build-tools.enterprise4g:apigee-edge-maven-plugin:1.1.6:configure (configure-bundle) on project edge-developer-training-idp: Execution configure-bundle 5of goal io.apigee.bui.ldp-otmo o(l0s .eBn taetrpri se40g :B/asp)i gee-edge-maven-plugin:1.1.6:configure failed: Plugin io.apigee.build-tools.enterprise4g:apigee-edge-maven-plugin:1.1.6 or one of its dependencies could not be resolved: Failed to collect dependencies at io.apigee.build-tools.enterprise4g:apigee-edge-maven-plugin:jar:1.1.6 -> org.apache.axis2:axis2-kernel:jar:1.3 -> annogen:annogen:jar:0.1.0: Failed to read artifact descriptor for annogen:annogen:jar:0.1.0: Could not transfer artifact annogen:annogen:pom:0.1.0 from/to central (http://repo1.maven.org/maven2): C:\Users\csfz\.m2\repository\annogen\annogen\0.1.0\annogen-0.1.0.pom.part.lock (Access is denied) -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException Downloading from central: http://repo1.maven.org/maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.jar Downloading from central: http://repo1.maven.org/maven2/org/codehaus/jackson/jackson-core-asl/1.9.4/jackson-core-asl-1.9.4.jar Downloading from central: http://repo1.maven.org/maven2/org/apache/httpcomponents/httpcore/4.0.1/httpcore-4.0.1.jar Downloading from central: http://repo1.maven.org/maven2/org/apache/httpcomponents/httpclient/4.0.3/httpclient-4.0.3.jar Downloading from central: http://repo1.maven.org/maven2/com/google/http-client/google-http-client/1.10.3-beta/google-http-clie... Progress (4(node:7500) UnhandledPromiseRejectionWarning: #<Object>

[...] -> second error towards the end

Request prepared for the server ************************** POST https://api.enterprise.apigee.com/v1/organizations/carlosfernandez-eval/environments/test/targetserv... accept: application/json accept-encoding: gzip authorization: Basic [Not shown in log] content-type: application/json [Request body] {"port":443,"isEnabled":true,"name":"edge-developer-training-backend","host":"apigee-developer-trainin-cc200.firebaseio.com\/","sSLInfo":{"enabled":"true"}} [ERROR] Apigee call failed 400 Bad Request { "code" : "messaging.config.beans.InvalidHostName", "message" : "Invalid host name apigee-developer-trainin-cc200.firebaseio.com/.", "contexts" : [ ] } [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 01:11 min [INFO] Finished at: 2019-06-07T15:45:16+02:00 [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal com.apigee.edge.config:apigee-config-maven-plugin:1.2.1:targetservers (create-config-targetserver) on project edge-developer-training-backend: Apigee network call error 400 Bad Request [ERROR] { [ERROR] "code" : "messaging.config.beans.InvalidHostName", [ERROR] "message" : "Invalid host name apigee-developer-trainin-cc200.firebaseio.com/.", [ERROR] "contexts" : [ ] [ERROR] } [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException (node:7500) UnhandledPromiseRejectionWarning: #<Object> (node:7500) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)

Solved Solved
0 7 726
1 ACCEPTED SOLUTION

Hi. In the end my problem was that I haven't removed the final "/" from the hostname:

apigee-developer-trainin-cc200.firebaseio.com

When I realised I ran again node setup and it went through correctly. I did a first test using postman to try to connect to the db from the proxy and it works. So to me that was the issue.

Just in case someone had same problem.

Thanks for those who read/posted.

View solution in original post

7 REPLIES 7