How do I deploy a Java AppEngine app using a Serverless VPC access connector with Google plugin for Eclipse? - google-plugin-eclipse

I created a Java AppEngine Standard application and managed the deployment through Google plugin for Eclipse. Then, I added a Serverless VPC access connector for a specific need. According to Google documentation, deployment must be done with the "beta" option:
Note: To use Serverless VPC Access, make sure you use gcloud beta to deploy your service.
How do I manage this deployment with Google plugin for Eclipse?
I use Gradle

Unfortunately, using the gcloud beta feature is not supported in the Cloud Tools for Eclipse plugin (CT4E). (By the way, Google Plugin for Eclipse (GPE) is deprecated, but it is not clear if you are using CT4E or GPE.)
However, the latest App Engine Maven/Gradle plugins (Cloud SDK-based) support using the gcloud beta feature through the gclodeMode parameter for deployment, so as a workaround, you could run the plugins on the command line (or invoke through IDE).

Related

Integrating Amazon SQS service into Eclipse

I am trying to integrate Amazon SQS into eclipse but I'm having a hard time and I have no clue how to do that. I have watched many you tube videos and they all are with intelliJ or with visual studio code.
I tried with visual studio code but by default location is changing in the credentials.
Can anyone let me know the dependencies to add and how to create a project so that I can integrate AWS and also how to run the final application and how to make changes in the queue created?
To use the AWS SDK for Java V2 in Eclipse, all you need to do is create a Maven Project in Eclipse. Then look at the AWS SDK Github repo here:
https://github.com/awsdocs/aws-doc-sdk-examples/tree/master/javav2/example_code/sqs
See this illustration.
Open the POM located here and copy and paste it into your Maven project's POM file. That will add the required dependencies into your project. Now you can add the examples to your project to get SQS examples working in Eclipse.
Of course, you need to setup your development environment - which includes setting up your AWS credentials. To learn how to do this, see this topic:
Get started with the AWS SDK for Java 2.x

How to change the Google App Engine SDK location in Eclipse Neon.3?

I have installed the latest Google Cloud SDK (200.0.0) and Google Cloud Tools on Eclipse Neon.3. The GCloud App Java Extensions have also been installed as below.
It seems the latest Google App Engine SDK 1.9.63 has been installed at:
C:\Users{USERNAME}.m2\repository\com\google\appengine\appengine-api-1.0-sdk\1.9.63
According to Google App Engine online documentation, I had to download and unzip the SDK (appengine-java-sdk-1.9.63) to a different directory.
I would like to use the SDK that I downloaded but the one in Maven. How can I change the location of the installed Google App Engine SDK in Eclipse?
EDIT:
I would like to clarify a few things:
.m2\repository is where Maven customarily caches Maven artifacts. Whenever any Maven projects make use of any JARs, they will generally be cached in that local repository. Since it is just a cache, you can safely delete the repository anytime in general. mvn package, for example, will download and cache necessary JARs again.
That said, .m2\repository\com\google\appengine\appengine-api-1.0-sdk\1.9.63 just contains a cached JAR: appengine-api-1.0-sdk-1.6.3-jar. Certainly, you wouldn't call a single JAR "Software Development Kit (SDK)"; I would call it, if I have to, an App Engine API JAR. Also, the JAR might have been cached by someone else than "Google Cloud SDK"; any Maven project that makes use of the classes in the JAR would automatically cache it.
"Cloud SDK" is a collection of tools and libraries for Google Cloud development and management.
"App Engine SDK for Java" as in https://cloud.google.com/appengine/docs/standard/java/download is another, different collection of tools and libraries for App Engine Java development, which you won't probably need here. The SDK is separate and independent from the Cloud SDK.
You don't need to download "App Engine SDK for Java" when using "Cloud Tools for Eclipse" (CT4E). CT4E is Cloud SDK-based and not App Engine SDK-based. Why do you need to manually download the App Engine API JAR? For example, you can add the JAR to your project in Eclipse by Preferences > Java Build Path > Libraries > Add Library > Google Cloud Platform Libraries > App Engine API > Finish.
You cannot configure App Engine SDK in Eclipse, you can just configure Google Cloud SDK inside Eclipse Google Cloud Tools.
Google App Engine SDK is a component of the Google Cloud SDK {1} so you can install it this way:
gcloud components install [COMPONENT-ID]
If you are using Java, [COMPONENT-ID] would be app-engine-java.
Good luck!
{1}: https://cloud.google.com/sdk/docs/components

Deployment of java application to bluemix

I have created an java Application in Eclipse IDE.
Can anyone help out how to edit a Java application in Eclipse & trigger a deploy to Bluemix.
The official IBM Bluemix plugin for Eclipse can do this for you.
Grab it from the Eclipse Marketplace here: http://marketplace.eclipse.org/content/ibm-eclipse-tools-bluemix#.VHAf-1Xd9E4
Here is some documentation about the plugin: https://developer.ibm.com/wasdev/downloads/#asset/tools-IBM_Eclipse_Tools_for_Bluemix
Once you install this, you should be able to connect your Bluemix account and package / deploy apps with the push of a button.
You will find the steps by steps to see how you can deploy you app in bluemix. You can use CF API, or download the eclipse plugin. Here you can see how to use the CF API for Bluemix.
Basically you need three commands:
cf api bluemix_domain
cf login -u username
cf push appname -p appname.war
you can get official eclipse plugin from IBM and deploy it to Bluemix.
Below is the link to download and get started on this:
https://developer.ibm.com/wasdev/downloads/#asset/tools-IBM_Eclipse_Tools_for_Bluemix

Eclipse(+AppEngine SDK) & Google "push-to-deploy" GIT repository

Is it possible to use Eclipse (with AppEngine SDK plugin) and Google "push-to-deploy" together? I have managed to install "gcloud"-tools and initialize a project fine! But now I can't figure out how to combine Eclipse project structure and the structure generated by "gcloud init". I mean I would like to do this:
1) Use Eclipse to edit the application and test it locally in Development server as before
2) But also utilize Google "Push-to-deploy" GIT repository (instead of GitHub)
Is this possible or feasible and is there any instructions how to do this kind of project setup correctly.
Thanks for any tips!
After some more experiments with gcloud (Google Cloud SDK) I would recommend creating the project with Maven and use Maven for building & running the development server. Still you can import the Maven project in Eclipse and use that as Java editor + remote debugger. Here's the instruction to get started:
https://developers.google.com/appengine/docs/java/tools/maven
Also Google Endpoints is quite nice tool for building REST APIs (though it still has some weaknesses, like limited support for HttpServletRequest data and poor authorization support in Development server)
https://developers.google.com/appengine/docs/java/endpoints/

Deploy project in Google app engine using command prompt

How do you deploy a project in Google App Engine using Eclipse? Is there a reference for the command line options required? Can it even be automated into a single action for the Eclipse IDE?
using Java appcfg update war
for python appcfg.py update <appdir>