Extreme Slow Cloud vs VPS (Amazon, Jelastic)

We are trying to migrate one of our web services (Java) to the cloud from the development server, here are the details:

There is a PHP interface that connects to a Java-based web service that is connected to the MySQL database (all requests to the database are sent from the web service, part of php is exchanged with Java back -end only, no direct connection to the database).

starting point

Dev Server - CentOS (cPanel), Operating System 765 MB-1.5 GB, 4CPU, Tomcat 7

* software runs fast , no performance issues, logs show normal CPU and memory usage

Script # 1

PHP interface on Elastic Beanstalk and Java web service with elastic beanstalk database

* software is about 80% slower , logs show normal CPU and memory usage

Scenario number 2

PHP front-end on VPS (same company / location with Jelastic) and Java web service with database on Jelastic

* software is about 70% slower , logs show normal CPU and memory usage

Scenario number 3

PHP front-end on VPS, Java web service with elastic beanstalk database and Jelastic (swithing)

* software is about 70-80% slower , logs show normal CPU and memory usage in both cloud environments

What I understood, regardless of where the external PHP interface is located, which will load quickly and do not look for anything here.

As soon as the Java source code moves from VPS to the cloud (it doesn't matter, Amazon or Jelastic), all the software slows down a lot. Based on the logs, and since we tried to work with two providers, this does not seem to be a resource problem.

This may not be a connectivity problem, since we tried to use PHP and Java in the same environment (scenario # 1).

This either the Java web service slows down extremely (for an unknown reason, because the logs show low resource usage), or it may be the connection between the Java application and the database (I doubt since in the first scenario all three components are on Amazon, in the same environment, location).

Has anyone had such a problem before? Any ideas? Thanks!

(note, I have no experience with cloud hosting)

+6
source share
3 answers

For a high-performance Java cloud backend, you can try Elastx's Jelastic implementation - see the performance study CloudSpectator did for them (they also used Amazon and Rackspace cloud in the study): http://blog.jelastic.com/wp-content/ uploads / 2013/09 / Elastx-Fueld-by-SolidFire-9-5-13 + Jelastic.pdf

Also, I don’t know who your current Jelastic provider is, but if you contact them by clicking Help / Contact in the Jelastic toolbar, I’m sure they will be happy to fix the problem! If this does not help, please write me offline.

+1
source

It can be associated with specific parameters in the configuration files, mainly for the database. Please check that they are the same in every test. It is also unclear how you measure performance and what β€œslower” means. And you did not specify the size of the resources on Jelastic and EB. Please double check that resources are equal.

+1
source

What you are measuring is processor memory. Since both give normal results and your application is exchanging data over the network, I suspect that network latency is the culprit. The next thing you need to pay attention to, for example, is disk I / O performance, which can slow down your application, for example, have a manual brake.

0
source

Source: https://habr.com/ru/post/956235/


All Articles