Categories
General

PHPUnit, how to stop on failure ?

Find below the command that exit out phpunit ghracefully when a first error pop out=

phpunit --stop-on-failure
phpunit David Raleche
phpunit David Raleche
Categories
General

How to get the exponent symbol (^) ?

well just copy it below :

^

Categories
Technical

How to story point your project ? Fibonacci Sequence

0, 1, 2, 3, 5, 8, 13, 21, 34

This is the Fibonacci Sequence to use when updating your story points

1 – Easy (1-2 days)

2 – Medium (1-2 days)

3 – Hard (3-5 days)

5- Very hard (3-8 days)

8 – Difficult (8-12 days)

13 – Very difficult (8-15 days)

Categories
General Technical

How to define latency in computer science ? ?

Latency is the delay between a user’s action and a web application’s response to that action, often referred to in networking terms as the total round trip time it takes for a data packet to travel.

How to reduce latency

Content Delivery Network (CDN) providers provide customers with private networks that allow them to bypass the public internet. Therefore, these private networks reduce latency by providing more efficient paths for data packets to travel on.

Also the caching techniques is resolving the latency issue

How Latency Works

Consider that you are buying a product through an online shop and you press the “Add to Cart” button for a product that you like.

The chain of events that occur when you press that button are as follow :

  1. Firstly, You press the “Add to Cart” button.
  2. Secondly, The browser identifies this as an event and initiates a request to the website’s servers. The clock for latency starts now.
  3. Thirdly, The request travels to the site’s server with all the relevant information.
  4. Then, The site’s server acknowledges the request. The first half of the latency is complete.
  5. The server accept the request status.
  6. The site’s server replies to the request with relevant information.
  7. The request reaches your browser and in the card the system adds the product. With this, the latency cycle is completed.

The latency is the time that it takes for all these events to complete.

latency
latency

source https://blog.stackpath.com/latency/

Categories
General

How to find the RAM memory ?

Many times you have to figure out the RAM memory on a server or your laptop let’s say. it works with a Macbook. The easiest way is to open a terminal and execute the following command

free -h

unix logo
unix logo
Categories
General

How to find the microprocessor speed ?

Here is the command to find the microprocessor speed in unix machine. MacOs is a unix machine so you can run the following command :

lscpu

unix logo
unix logo
Categories
API General Web API

How to improve an API speed performance ?

Today’s challenge : investigate the slow responsiveness of the api. I was assigned the task to investigate the performance report produced the day before. The report concluded in the most unclear manner that the backend was lacking in term of performance. No precision regarding the list of failing api calls was provided. I used newRelic and discovered that indeed during the specific timeframe mentioned a clear bottleneck was surfacing an a specific api call to a specific internal server.

I reached out to the developer mainly responsible of this server. The newRelic information [pointing out the entanglement] was challenged in the most defensive and almost aggressive manner to my stupefaction.

Developer do not like to be pointed out or criticized. What/How should have approach this developer ?=

The developer challenged the results by saying “I just executed the specified api endpoint with the specified payload and guess what; the result came back under one second”. Omitting the context of Heavy Test Performance. So being pushed back multiple time, I moved on to the sysOp department to get more information on what was going on.

The slow server obviously was not monitored with newRelic. A coordination with sysOp was necessary to get this server under surveillance. During our meeting, it was established that the server was under provisioned in term of CPU power and memory space. We did increase these metrics.

The tests were ran and passed successfully. The main challenges were to get the approval from the CIO to have sysOp moving and the developer’s resistance to acknowledge a possible glitch on the server.

My approach toward this developer although very specific and data documented should have been persuasive rather than convincing.

Categories
General

What is the command line of the day ? valet use [email protected]

valet use [email protected]

Categories
Technical

What is a Developer Love Dream ?

No more time wasted in configuration => Just develop!

Developers spend considerable time configuring their work environment. This is an exhausting task and it is tiring. Software engineering is Joy when we can develop and think about logic and Speed performance.

Surprise david.raleche.com is there to facilitate development for software engineers and myself !

Starting with providing tips about best devices and tools and of course articles and solutions about diverse configuration issues

Categories
MySql

What is the easiest way to run Mysql on a Mac ?

The easiest way to run MySQL on a Mac is to install MAMP. The advantage is that it does not conflict with valet which is another powerful tool for local development specially with Laravel. If you do not want to face the same issue as the lost of your mysql password after installing with homebrew, MAMP is the my fastest solution

See StackOverflow issue : MacOSX homebrew mysql root password