Running WSO2 API Manager on Heroku - heroku

Is there a straightforward way to run WSO2 API Manager on Heroku? I've been through the basic Heroku docs on how to deploy Java applications and understand that process but it seems like jumping through hoops that maybe aren't needed.
I'd like to be able to simply upload the installed application (binary version of application) and a procfile that defines the bootstrap class file as the starting point.
Is this possible? Is there another way to get Java apps to run in Heroku without defining a pom.xml and having it build the application prior to deployment?
Thanks,
Dave

WSO2 offers the hybrid API model to deploy your WSO2 API gateway on Heroku and use WSO2 API Cloud to manage your APIs.
You can use WSO2 WSO2 Heroku Add-on which can be used as WSO2 API publisher and Store. Then use Heroku Button to deploy WSO2 API Gateway on Heroku.
More info: https://devcenter.heroku.com/articles/wso2apicloud

It looks like there is no straightforward way to run WSO2 API Manager on Heroku. I looked at how Java programs are run on Heroku and it seems your requirement cannot be achieved currently. Heroku seems to be depending on Maven projects.
WSO2 API Manager product is built from WSO2 Carbon platform, which is not a simple Maven Java project.
Heroku also runs the Java application on OpenJDK, which is not supported by WSO2 API Manager. Only Oracle JDK is supported as mentioned in Installation Prerequisites.
I hope this helps.

Related

How can I deploy a Spring Boot REST API to BanaHost cPanel?

I created a full stack application (Angular front end, java spring boot back end, mysql database), and I was able to upload successfully both the angular files and mysql into BanaHost cPanel, however I have not found useful information on how to upload spring boot REST API, as a consequence only the front end is working. How can I deploy this REST API on cpanel?
Spring Boot Applications can't just upload and deploy if you're utilizing a cPanel Web hosting (shared) plan, like you deployed the Angular Application by uploading.
For spring boot you must do it yourself, a Virtual Private Server or Dedicated Server will unlock the site hosting restriction. If you are not much familiar with the Linux command line, you can use a Window VPS instead. Providers like, Digital Ocean, Linode, and Oracle Cloud all provide free trials.
And also, there are platforms, such as Heroku (Platform as a Service(PaSS)), where you can deploy your app without the need for a VPS. You can refer their documentation regarding this:
https://devcenter.heroku.com/articles/deploying-spring-boot-apps-to-heroku

Deploy my spring boot application into google cloud computer engine

I got a query to ask you all. I am looking for guides that help me deploy my spring boot application on google cloud computer engine, I type in my instance IP address when I test my spring boot application I unable to access it in REST API.
May I know do you have any guides or steps for me to follow to deploy successfully in google cloud computing engine. Why do I need to deploy in computer engine is because I deployed my angular at it and I deploy it both it seems that my angular project being replaced by my spring boot application.
Codelabs GCP / Spring series has deployment tutorials:
https://codelabs.developers.google.com/spring/
GCP has some "Getting Started" tutorials you can use here:
https://cloud.google.com/java/docs/
where the specific one for deploying a java app to GCE is here:
https://cloud.google.com/java/docs/tutorials/bookshelf-on-compute-engine
But the basic steps are as follows:
Write your Spring app
Build your Spring app
Run / test your jar locally
Push your jar to a location in Storage
Create a startup script for your GCE instance
Create a new GCE VM which uses your startup script using Console, Deployment API, or gcloud tool
After that, you need to ensure you have the proper network rules in place to be able to access your API publicly. If you do not wish to learn how to use GCE, I would suggest you look into using App Engine instead because then you do not need to learn how to deploy and instead can concentrate on your api. Here is a guide to do that

Keycloak Server on Heroku

Currently I'm working on a Spring Boot 2 project where we use Heroku as our Cloud Service. We push our changes to Github and our instance on Heroku cloud gets provisioned and deployed. After participating Javaday in my city, I attended to a speech and got to know about this amazing framework, Keycloak. After some investigation, we have decided using Keycloak as our identity and access management.
From what I understand, we need to start a Keycloak standalone server as explained here https://www.keycloak.org/docs/latest/server_installation/index.html.
But the problem is, we cannot access to filesystem on Heroku instance and thus, cannot extract the Keycloak files and start the server.
I tried to follow these steps https://github.com/yurtsevich/keycloak-swarm-heroku yurtsevich has provided but I noticed that latest version of Keycloak Swarm is not compatible with Spring Boot 2.
Can we start Keycloak server on the same Heroku instance we have? I'm unable to find any solution to this at this moment.
Edit: this button from readme will deploy Keycloak on Heroku with free dynos: https://github.com/sannonaragao/keycloak-heroku
This button deploys the lastest version straight to Heroku.
https://elements.heroku.com/buttons/mieckert/keycloak-heroku
Beware! It deploys at the Performance-M dyno, you must change to free right after if you don't want to pay some use fee.

how to develop msf4j-apps and deploy them in wso2ei

the about-page of wso2ei 6.1.1 (https://docs.wso2.com/display/EI611/About+this+Release)
mentioned the possibility to develop and especially to deploy msf4j apps in wso2ei:
From WSO2 EI 6.1.0 onwards, it does not ship the functionalities of
WSO2 Application Server (AS). However, you can develop applications
using MSF4J, JAX-RS or JAX-WS technologies and deploy in WSO2 EI. If
you already have applications in WAR or AAR formats, use WSO2 AS 5.3.0
or Tomcat as the server to deploy web apps. Nevertheless, WSO2 still
provides complete development and production support for WSO2 AS.
I am very interested to do this, but unfortunally I can not find any information on this topic. I would be happy to receive information and links to this topic.
You can develop a service using MSF4J and deployed it with the MSF4J profile which is available with the WSO2 EI. Sample is mentioned in Doc 1
Highlevel steps would be
Develop the MSF4J service
Put that jar file in <EI_HOME>/wso2/msf4j/deployment directory
Start the MSF4J profile in EI <EI_HOME>/wso2/msf4j/bin/carbon.sh

UI application in Pivotal Cloud Foundry

I have a UI application built using Angular , Bootstrap and HTML5 which interacts with number of backend services. In order to deploy this application in PCF , should this be converted to a Spring Boot app? Or is there a way to use any of available buildpacks to deploy this UI app in PCF?
In case there is no need to deploy backend services, I would go with the cloudfoundry static buildpack.
http://docs.cloudfoundry.org/buildpacks/staticfile/index.html
Otherwise you will need to decide how you are going to deploy the backend services for this application. There are a number of buildpacks available that could be used for deploying the backend services and delivering the frontend content within the same app (one of them being, as you mentioned the java buildpack that can be used to deploy a spring boot app). Here is a list of available buildpacks:
http://docs.cloudfoundry.org/buildpacks/
Its not needed to convert your application to spring boot, but doing so will definitely make life easier for you, trust me. Once u convert ur app to a spring boot right, you can remote debug ur application by jst running ur app as a spring boot app.

Resources