Migrating from Cloudbees to other service for #Run - java

As many of us here have probably had, I've received a message from CloudBees stating that the #Run service will soon be discontinued.
I have to migrate elsewhere and need a Dummy's Guide on how to set up a new platform where I can run my service. Are there any guides out there? All I get from Google is CloudBees' own guide which is too vague for me.
I'm running a java app, uploaded as a War connected to a MySQL DB.
Could any of you point me in the right direction?

1) Give a look at official migration documentation (point 2 has a link to google doc containing some info)
2) Check the section called "Migration CloudBees Applications" and select the provider you would like to migrate to
3) Type in google (or your prefered search engine): "CloudBees to <selected provider> migration"
(you should end-up with something like this or this.. I'm not advertising, those are just random examples)
4) Start following the steps, and if you will have an problem don't hesitate to ask more specific questions

Related

Where and how to deploy a Java Spring Boot application for free? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 1 year ago.
The community reviewed whether to reopen this question 9 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I want to know where and how can I deploy a Java web application made with Spring Boot or an app built with servlets or JSP.
Consider me a beginner in this topic. If you have suggestions about what I should learn first in order to accomplish this then please share, also if you have any links to particularly helpful blogs or videos that will do too.
Thank you all in advance.
I too have used GCP to host a Spring-Boot service. I followed this article almost religiously provided by Spring Boot(https://www.baeldung.com/spring-boot-google-app-engine) as well as this github read me that includes extra information about preparing your service to be hosted onto GCP (https://github.com/GoogleCloudPlatform/getting-started-java/tree/master/appengine-standard-java8/springboot-appengine-standard)
The main idea is that you will need to create a CLOUD SQL instance if you are using MySQL, and then add some configurations in your applications.properties (https://github.com/GoogleCloudPlatform/cloud-sql-jdbc-socket-factory)
You will need to package your Spring-Boot services to either a jar or a war. I used a war because I was able to find more resources. This is done in your pom.xml.
You will need to include all the right GCP packages to be able to host onto gcp in your pom.xml
You will need to create some sort of runtime configuration by creating an appengine/app.yaml file
You will need to extend a Servlet class in your main application file so that GCP has a main endpoint when any call is made to utilize your Spring-Boot services
Though all the answers were helpful, I found the process of deploying my spring boot app into Heroku is simpler.
First of all we need to create a github repository for our project. and commit all the codes to github from STS.
We have to have an account in Heroku. where we'll create a project which is currently empty-> Deploy -> choose Github under deployment method -> and choose the project we're trying to deploy -> Choose Deploy branch option under Manual Deploy.(you can enable automatic deploy if you want to deploy automatically after pushing an update in git). -> you're good to go.
This is only for an webapp with no database connectivities, for database related features we have to use add-ons like Heroku-postgres or jawssql .Once I do that part I'll update the answer.
here is a step by step guide:
https://www.kindsonthegenius.com/2019/11/28/devops-ci-cd-pipeline-step-by-step-tutorial-springboot-github-heroku/
You can use GCP (google cloud platform) App Engine for the deployment purpose. It's easy to learn and free to use for 1 year.
Deploy Spring Boot Application in App Engine standard
It depends on where you want to deploy the app....
If you use a private host you must generate a package and make a "manual" deploy to your own server.
The easiest way is to use Heroku. A cloud platform very user friendly for begginers. It has a free plan so you can host your app for free forever... with limitations. The apps fall asleep after 30 min of no use, for example. It's good for testing porpouses
In order to use heroku you must know how to use git. I will assume you alredy know the git basics... otherwise I suggest you to learn it first.
1-Create heroku account and log in.
2-Search for New button -> create new app.
3-choose region and app name
4-You can navigate inside your app. Look for deploy (I think it automatically goes there when creating new app)
5-You have three ways to upload an app on heroku. Using git, github or container. For the first and the last one you must install heroku CLI. Follow this guideline https://devcenter.heroku.com/articles/heroku-cli#download-and-install
6.1-If you want to upload your app using github, click on github and follow steps... very easy
6.2- If you want to use git and heroku cli.. click on heroki CLI and follow steps.. (basically you need to "heroku login" and after commiting your work just "git push heroku master"....)
If everything works, your app is in the cloud and you can use it for free....
NOTE I think heroku only is able to deploy Springboot apps...
It's quite easy following some tutorial...
With scalingo.com you get 30 days free trial. That's where I managed to host my java app and mysql DB for free. It's only 30 days but it allows you to se how deployment works and it's definitely a valuable experience for beginners.
Google cloud platform is also a good option. I haven't used it but I now there you also have free trial for 1 year I believe.
I feel Heroku and GCP are good solutions but you can try Azure as well for deployment of spring boot application as alternative.
There are very good resources (documents) about how to achieve this. Azure gives 200$ credit in starting.
Please refer below official document,
https://spring.io/guides/gs/spring-boot-for-azure/

How to make an offline java application available online?

I have developed an offline java application and i would like to host it online in internet. I am not sure how to adapt my code as an webapplication. How to adapt html css to my code? (as i already have GUI). thanks.
Not able to find the right example or how tos on internet
You can use some cloud services to run your application, for example you can use AWS (aws.amazon.com/cloud‎).
Steps you need to perform:
register your account there;
add credit card (it's gonna take like a few dollars from that);
install application container (like tomcat);
deploy your application to tomcat server (for example);
run tomcat (for example).
That's all, enjoy your application online.

How to make a connection to a Google Drive folder using the Drive API

I've searched a lot through the web about this topic (even on StackOverflow), but the questions I was looking at weren't able to help me, so, here it is (Although im very good at it, english is not my native language, so I'm sorry for any mistake made): (SKIP TO EDIT)
I'm making a simple chat program in Java (self learning), and, at first, I wanted to access a file on my computer. I soon found it hard to acomplish, and decided I wanted to access a drive folder on MY account. So, I googled about a possible Google Drive API. And I found it!!!
I downloaded a copy of the API to my PC, and then i went online to know how to use the API, but the README.txt file and the youtube tutorial were not helpful at all, because i could not understand the instructions. I Looked everywhere but still didnt find an easy-to-understand answer.>
So, im asking if any of you could provide a step-by-step tutorial on how i can accomplish my goal. Ive created projects on the API consoles, but im a bit confused on what to do with them (possibly going to delete them).
EDIT/REDO:
I'm making a chat program, and I want EVERY copy of the program to access a folder on my personal Google Drive and get certain files from it, where ever the user is, and without him having to see the OAuth 2.0 Autorization screen(if this last step cant be skipped, I'll work with that too).
The problem is that, although i have checked the README.txt and the youtube tutorial, i still dont understand how to use the API in the way i want.
So, im asking if any of you could provide a step-by-step tutorial on how i can accomplish my goal, i.e, (Some code could be of great use):
1st-Do this;
2nd-Do that;
...
(n steps)-You are ready;
Thank you in advance!!
P.S.: this is my last "free" question, so if this specific question has been answered please comment it out.
To start using Drive API, you may may want to follow and complete the steps given in Java Quickstart.
Then to integrate with the Drive UI, you may want to check the following references:
Enable the Drive Platform - to get started integrating with the Drive UI, you need to enable the Drive API and provide configuration details in your API project. This gives you access to the API as well as access to UI integration features.
Install Your App - Google Drive lets users install an app by approving an OAuth 2.0 access request.
Open Files - this page describes how to integrate your app with these Drive UI features to open files stored in Google Drive
Hope that helps!

Netbeans Java web app deployment to web host

I have created a java web application in netbeans using a glassfish server and mySql database.
The web application is working correctly in my local environment and now i want to deploy to my host name which ive purchase from 1and1. Ive transfer my Web folder to my host name via FTP but im literally stuck now.
I know i have to somehow add the glassfish server to that host name but i dont how to do this.
can anyone help me please.
thanks in advance
Basically if you a remote control it is not a big deal.
basic steps would be
- install mysql
- install jdk
- install glassfish
Assuming you have a *nix based server.
Here you can find steps related to GF3 installation. However I do not like the way GF installation described there. Moreover I do not think you are going to have X environment on your server. So if you need to install GF3 you can follow installation for JDK and install GF3 from a zip file. The process is described in the the installation tutorial for GF4. It would be the same for GF3. There also you may find instructions how to install JDK7. At least one important step is missing in that tutorial however. If you do all the steps from that tutorial, your GF instance would not start when OS is restarted. You can find how to fix this in the official documentation. There you can find how you can configure your GF to start as a service. The steps are the same for v3 and v4.
Basically I provided the first two links because of additional information like how to enable WEB console for remote access. You cannot access it right after installation. You have to enable it by changing admin's password and.. but you find the description there.
You can find many blogs tutorials even videos if you google a bit. Tutorial for ubuntu more informative from my point. Many steps are not specific for ubuntu and could be reused for other distributions.
More thoughts about where and how to install GF here on stackoverflow
Just in case couple of links for mysql 5 installation
official documentation
tutorial for different distributions
Just in case. You can use putty for remote access. If your server is configured to allow this, you would be able to connect. You may want to ask support team to clarify it.
For windows it is even simpler
you can download an installer from here for GF4 of from here for GF3. You also can download a zip file and install GF as a service. See official documentation and step-bystep simplified tutorial with pictures here.
I think jdk and mysql would not be a problem on windows based server

Android Mobile Push App example from Amazon Web Services

Have anyone tried to add AndroidMobilePushApp (is provided by AWS) into Eclipse IDE, follow by this tutorial (http://docs.aws.amazon.com/sns/latest/dg/mobile-push-gcm.html) and able to get registrationID for the Amazon Mobile Push app?
I am able to add AndroidMobilePushApp into Eclipse along with 2 extraneous library .jar (android.jar, google-play-service) without any error, created Google API project on Google APIs Console website and copied that project_number into [res/values/strings.xml] according step 3 from the tutorial above. However, when I deploy the application into an Android device (Version 2.3.6 and API level 10), the app does show up,but it doesn't run when I click on...with error says " The application Amazon Mobile Push ( process com.amazonaws.androidtest) has stopped unexpectedly. Please try again! " so It won't able to give me back registration ID as step 4 from the tutorial above.
Any idea why?
Thanks,
Don
I had trouble w/ that sample code also. I finally got AndroidMobilePush to work but not SNSMobilePush in the same tutorial.
Hard to tell what you have done or left out, but I can give you some ideas of where to look:
Check if you have changed package names any place.
I had to declare the PLAY_SERVICES_RESOLUTION_REQUEST = 9000; constant needed in checkPlayServices()
Make sure you have not blocked execution of checkPlayServices and register()
I would set a Log filter to make sure you are at least getting that far. Then, of course, set another to capture the registrationID so you can save it to log.txt. Copy that and supply it to the SNS Console in AWS when you Add Endpoints.
Read carefully Step 3, point 4 and associated image.
If you remove android.jar from the export list, your app will run fine

Categories

Resources