Skip to content

Commit d3ebebe

Browse files
[ILX-58820] Updated API RateLimit Description (#47)
* [ILX-58820] Updated API RateLimit Description * [ILX-58820] Addressed Feedback * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update ruby.yml * Update Gemfile.lock * Update ruby.yml * Update Gemfile.lock * Update ruby.yml * Update ruby.yml * Update Gemfile * Update ruby.yml * Update ruby.yml * Update config.yml * Update config.yml * Update config.yml * Update config.yml * Update Gemfile * Update Gemfile * Update Gemfile.lock * Update Gemfile --------- Co-authored-by: Anthony Grafft <127154023+AnthonyGrafftIntelex@users.noreply.github.com>
1 parent db16acd commit d3ebebe

5 files changed

Lines changed: 22 additions & 20 deletions

File tree

.circleci/config.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ jobs:
33
build:
44
working_directory: ~/project
55
docker:
6-
- image: starefossen/ruby-node:2-8
6+
- image: cimg/ruby:2.7.8-node
77
auth:
88
username: intelexdocker
99
password: $DOCKERHUB_PASSWORD
@@ -12,19 +12,19 @@ jobs:
1212
- run:
1313
name: Install and configure dependencies
1414
command: |
15-
gem install bundler -v 2.3.26
15+
gem install bundler -v 2.4.22
1616
bundle install --jobs 4 --retry 3
1717
- run:
1818
name: Build static html
1919
command: bundle exec middleman build --clean
2020
- persist_to_workspace:
21-
root: /root/project
21+
root: ~/project
2222
paths:
2323
- build
2424
deploy:
2525
working_directory: ~/project
2626
docker:
27-
- image: starefossen/ruby-node:2-8
27+
- image: cimg/ruby:2.7.8-node
2828
auth:
2929
username: intelexdocker
3030
password: $DOCKERHUB_PASSWORD
@@ -34,7 +34,7 @@ jobs:
3434
fingerprints:
3535
- "72:81:e7:4d:d2:d4:0d:7f:59:6b:e1:74:57:3d:36:12"
3636
- attach_workspace:
37-
at: /root/project
37+
at: ~/project
3838
- run:
3939
name: Install and configure dependencies
4040
command: |

.github/workflows/ruby.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v1
10-
- name: Set up Ruby 2.6
11-
uses: actions/setup-ruby@v1
10+
- name: Set up Ruby 2.7
11+
uses: ruby/setup-ruby@v1
1212
with:
13-
ruby-version: 2.6.x
13+
ruby-version: '2.7'
14+
bundler-cache: true
1415
- name: Build and test with Rake
1516
run: |
16-
gem install bundler
17+
gem install bundler -v 2.4.22
1718
bundle install --jobs 4 --retry 3
1819
bundle exec middleman build --clean
1920
- name: GitHub Pages Deploy
20-
uses: JamesIves/github-pages-deploy-action@master
21-
env:
21+
uses: JamesIves/github-pages-deploy-action@v4
22+
with:
2223
BRANCH: "gh-pages"
2324
FOLDER: "build"
2425
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ gem 'middleman-syntax', '~> 3.0.0'
66
gem 'middleman-autoprefixer', '~> 2.7.0'
77
gem "middleman-sprockets", "~> 4.1.0"
88
gem 'rouge', '~> 2.0.5'
9-
gem 'redcarpet', '~> 3.4.0'
9+
gem 'redcarpet', '~> 3.4.0'

Gemfile.lock

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ DEPENDENCIES
120120
middleman-syntax (~> 3.0.0)
121121
redcarpet (~> 3.4.0)
122122
rouge (~> 2.0.5)
123-
wdm (~> 0.1.1)
124123

125124
BUNDLED WITH
126-
1.14.6
125+
2.4.22

source/includes/_api-reference.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -139,17 +139,19 @@ Response Code | Meaning
139139
When we make backwards-incompatible changes to the API, we release new versions. The current version is **v2** and can be determined with our API base path **/api/v2/**. Read our [Intelex platform release notes](https://community.intelex.com/library/knowledgebase/release-notes) to see our API changelog.
140140

141141
## API Rate Limiting / Quotas
142-
To ensure Intelex Platform is reliable and has the expected performance for all users, we limit the number of API calls an API user (or application) can make within a given time period. If the limit is exceeded, the API user may be throttled and subsequent requests within the same period will fail (status code 429).
142+
To ensure Intelex Platform is reliable and has the expected performance for all users, we limit the number of API calls an API user (or application) can make within a given time period. If the limit is exceeded, the API user may be throttled and subsequent requests will be rejected, returning HTTP response code 429 Too Many Requests. In such cases it is the responsibility of the client application to implement appropriate retry logic for requests that are rejected due to rate limiting.
143143

144144
### Limit
145-
The Intelex Platform API Rate limit is **2 requests per second**.
145+
The Intelex Platform API Rate limit is **6 requests per second**.
146146

147147
### Quota headers
148148
Quota details may be passed back to the API user/application via response headers.
149149

150150
Header | Description | Sample value
151151
---------- | ------- | -------
152-
X-RateLimit-Limit | The request limit per specified unit of time. | 100
153-
X-RateLimit-Remaining | The remaining number of requests that API consumers can send in the current time window. | 75
154-
X-RateLimit-Reset | The UTC epoch timestamp indicating the time of the next quota reset. Sent only when quota remains. | 1521214822
155-
X-RateLimit-Next | The UTC epoch timestamp indicating the time of the next quota reset. Sent only when quota is full. |1521215291
152+
Retry-After | Time in seconds to wait before retrying the request after rate limit is exceeded. | 600
153+
154+
### Best Practices
155+
156+
* Use HTTP clients that support automatic retries with an exponential back-off strategy when receiving 429 (Too Many Requests) responses.
157+
* Avoid spikes of traffic by spreading out API calls over time wherever possible.

0 commit comments

Comments
 (0)