Skip to content

0.4.0-dev.1

Pre-release
Pre-release
Compare
Choose a tag to compare
@b-cho b-cho released this 12 May 21:41
· 49 commits to develop since this release

This is a development build. Stability is not guaranteed, and new features may change at any time.


0.4.0-dev.1

Added

  • Add significant rate limiting functionality using the bottleneck library
    • Support for a user-specified number of retry attempts after receiving HTTP 429 errors
    • Automatic rate limiting with retry timing automatically determined based on response headers
    • New max-concurrent and min-time options for Riot API requests
  • Setting multiple Action properties simultaneously from an object using .set()
    const summonerData = await galeforce.lol.summoner().set({
      region: galeforce.regions.lol.NORTH_AMERICA,
      summonerName: 'name'
    }).exec();

Changed

  • [breaking] Update the structure of the config object passed into the GaleforceModule() constructor
    • Now merges the provided configuration object with a default object

      {
        'riot-api': {
            key: '',
        },
        'rate-limit': {
            type: 'bottleneck',
            cache: {
                type: 'internal',
                'key-id': 'galeforce',
                uri: undefined,
            },
            options: {
                intervals: {},
                'max-concurrent': null,
                'min-time': 0,
                'retry-count-after-429': 3,
            },
        },
        debug: [],
      }
  • Updated galeforce:rate-limit debugging output