Working with HTTP request type (method) in CakePHP

Get the request type (method): $this->request->getMethod() (For the older versions before 3.4, use $this->request->method()) Check the request type (method): $this->request->is('post'); Documentation: https://book.cakephp.org/4/en/controllers/request-response.html#reading-the-http-method https://book.cakephp.org/4/en/controllers/request-response.html#Cake\Http\ServerRequest::is

Bootstrapping a Node.js Lambda function having MySQL support

If you need your Node.js Lambda function to have support for any given extension, add that extension locally to have your local npm download the dependencies into node_modules, then zip the folder into an archive, and create a Lambda function from that archive. You can do it from a Linux VPS, or download the ready-to-use… Continue reading Bootstrapping a Node.js Lambda function having MySQL support

Connecting AWS API Gateway to SQS

An outline, leaving out the defaults and the obvious chores such as selecting the right region: 1. Create your SQS queue 2. Create a REST API, a resource and a method – Method Request: empty, no auth – Integration Request: – Type: AWS Service – AWS Service: Simple Queue Service (SQS) – AWS Subdomain: (empty)… Continue reading Connecting AWS API Gateway to SQS