42 Matching Annotations
  1. Mar 2023
  2. Dec 2022
  3. Nov 2022
    1. Hello, Unison author here.This is definitely an issue that is real, and is currently a problem, and that we will fix; probably by giving the function author an option to salt the hash of new definitions that have some semantic meaning beyond their implementations (appropriate for most application/business logic). No salt for definitions whose meanings are defined by their implementations (appropriate for most generic "library" functions like `List.map`).We already make this distinction for data types, but not yet for value/function definitions.

      .

  4. Oct 2021
  5. Jul 2021
  6. Jun 2021
  7. May 2021
    1. you want to pass a function as an argument to higher-order functions

      Functional programming - passing functions as arguments, as opposed to data objects.

    2. Lambda functions are used when you need a function for a short period of time.

      saves time writing (& maintaining, unit testing) private utility functions.

  8. Apr 2021
  9. Mar 2021
  10. May 2020
    1. When CloudFront receives a request, you can use a Lambda function to generate an HTTP response that CloudFront returns directly to the viewer without forwarding the response to the origin. Generating HTTP responses reduces the load on the origin, and typically also reduces latency for the viewer.

      can be helpful when auth

    1. For this setup, do the following: 1.    Create a custom AWS Identity and Access Management (IAM) policy and execution role for your Lambda function. 2.    Create Lambda functions that stop and start your EC2 instances. 3.    Create CloudWatch Events rules that trigger your function on a schedule. For example, you could create a rule to stop your EC2 instances at night, and another to start them again in the morning.
  11. Apr 2020
    1. Lambda authorizers–A Lambda authorizer is simply a Lambda function that you can write to perform any custom authorization that you need. There are two types of Lambda authorizers: token and request parameter. When a client calls your API, API Gateway verifies whether a Lambda authorizer is configured for the API method. If it is, API Gateway calls the Lambda function.In this call, API Gateway supplies the authorization token (or the request parameters, based on the type of authorizer), and the Lambda function returns a policy that allows or denies the caller’s request.API Gateway also supports an optional policy cache that you can configure for your Lambda authorizer. This feature increases performance by reducing the number of invocations of your Lambda authorizer for previously authorized tokens. And with this cache, you can configure a custom time to live (TTL).To make it easy to get started with this method, you can choose the API Gateway Lambda authorizer blueprint when creating your authorizer function from the Lambda console.

    1. Why Use Lambda Functions? The power of lambda is better shown when you use them as an anonymous function inside another function. Say you have a function definition that takes one argument, and that argument will be multiplied with an unknown number: def myfunc(n):   return lambda a : a * n Use that function definition to make a function that always doubles the number you send in:
  12. Aug 2019
    1. We can definitely observe that (memory) size matters! More memory dramatically reduces duration.

      768-1024MB is optimal, and has diminishing returns

      lambda average duration

  13. Mar 2019
  14. Nov 2018
  15. Nov 2017
    1. Lambda@Edge lets you run Lambda functions at AWS Regions and Amazon CloudFront edge locations in response to CloudFront events

      Extremely happy to see such an amazing opportunity which I think will help create fined grain API's which are fast and can leverage Caching strategies which will be cheap.

  16. Oct 2017
  17. Mar 2017
    1. The lambda expression matches the delegate it is assigned to, so it defines a method that takes one parameter of type Base and that has no return value.

      Where's the Delegate the lambda expression supposedly matches

  18. Feb 2017
    1. private void setup(string someData) { Object.assignHandler((sender) => evHandler(sender,someData)); } public void evHandler(Object sender, string someData) { // need someData here!!! }

      lambda is useful