Skip to content
This repository has been archived by the owner on Jun 14, 2020. It is now read-only.

Commit

Permalink
We're overloaded // #143
Browse files Browse the repository at this point in the history
  • Loading branch information
lourot committed Sep 11, 2018
1 parent 61ffed7 commit e3b0f2b
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 20 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<!-- issue143 -->
> **WARNING**: We're overloaded at the moment and we can't handle any new profile request. We're
> sorry and will come back soon with a system that scales better. See
> https://news.ycombinator.com/item?id=17951478
> [#143](https://github.com/AurelienLourot/ghuser.io/issues/143).
[![Build Status](https://travis-ci.org/AurelienLourot/ghuser.io.svg?branch=master)](https://travis-ci.org/AurelienLourot/ghuser.io)
[![All Contributors](https://img.shields.io/badge/all_contributors-21-orange.svg?style=flat-square)](#contributors)
Expand Down
6 changes: 2 additions & 4 deletions db/fetchBot/bot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function waitForJob {
getNextSqsMessage 0
job="$(echo $msg | cut -d',' -f1)"
if [ ! -z "$job" ]; then
job=""
job="" # break # temporarily disable because of issue143
fi

if [ "$(($lastRun + 10 * 60 * 60))" -le "$(now)" ]; then
Expand All @@ -91,9 +91,7 @@ while true; do
if [[ ! -z "$job" ]]; then
addUser "$job"
fi
if [[ "$job" != "AurelienLourot" ]] && [[ "$job" != "brillout" ]] && [[ "$job" != "ShonFrazier" ]] && [[ "$job" != "kdaoudieh" ]]; then
updateDb
fi
updateDb
if [[ ! -z "$job" ]]; then
echo "Deleting $job's profile request..."
getNextSqsMessage 10
Expand Down
4 changes: 3 additions & 1 deletion db/fetchBot/getNext200.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

set -e

# temporary script for issue143

source ../../aws/sqs/utils.sh

function getNextSqsMessage {
Expand All @@ -11,7 +13,7 @@ function getNextSqsMessage {
msg="$requestBody,$requestReceiptHandle"
}

for i in $(seq 1 195); do
for i in $(seq 1 200); do
getNextSqsMessage 10
login="$(echo $msg | cut -d',' -f1)"
echo "$login"
Expand Down
2 changes: 1 addition & 1 deletion reframe/server/start.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ async function start() {
let login;
try {
login = request.auth.credentials.profile.raw.login;
// await raven.captureMessage(`Profile request: ${login}`);
// temporarily disabled for issue143: await raven.captureMessage(`Profile request: ${login}`);
const avatar_url = request.auth.credentials.profile.raw.avatar_url;
await sendSqsMsg(`${login},${avatar_url}`);
} catch (e) {
Expand Down
12 changes: 9 additions & 3 deletions reframe/views/Creating.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import './All.css';
class Creating extends React.Component {
componentDidMount() {
setTimeout(() => {
//window.location.replace(`/${this.props.username}`);
// temporarily disabled for issue143: window.location.replace(`/${this.props.username}`);
}, 5000);
}

Expand All @@ -19,9 +19,15 @@ class Creating extends React.Component {
<NavBar/>
<Content>
<div className="container container-lg mt-2">
<!-- temporarily disabled for issue143
<i className="fas fa-spinner fa-pulse"></i> {this.props.username}'s profile is being
created. You'll be redirected to&nbsp;
<a href={`/${this.props.username}`}>
{urls.landing}/{this.props.username}
</a> in a few seconds...-->
Sorry, we're overloaded, we had to freeze the <i>profile requests</i> for now. See&nbsp;
<a href="https://news.ycombinator.com/item?id=17951478" target="_blank" className="external">
https://news.ycombinator.com/item?id=17951478
<a href="https://github.com/AurelienLourot/ghuser.io/issues/143" target="_blank" className="external">
#143
</a>.
</div>
</Content>
Expand Down
17 changes: 7 additions & 10 deletions reframe/views/profile/rightpanel/RightPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,16 +75,13 @@ const RightPanel = props => {
} else {
repos.push(
<div key="alert" className={alertCssClasses} role="alert">
This profile doesn't exist yet.<br /><br />
And we're quite overloaded at the moment, see&nbsp;
<a href="https://news.ycombinator.com/item?id=17951478" target="_blank" className="external">
https://news.ycombinator.com/item?id=17951478
</a>. If you have clicked on "Get your profile" already, please don't click again, your
profile is being created and it will take a few hours.<br /><br />
<a href="https://github.com/AurelienLourot/github-contribs#why-is-it-so-slow"
target="_blank" className="external">
Why does it take so long?
</a>
This profile doesn't exist yet.
<!-- temporary for issue143: -->
<br /><br />
And we're overloaded at the moment, see&nbsp;
<a href="https://github.com/AurelienLourot/ghuser.io/issues/143" target="_blank" className="external">
#143
</a>. We can't onboard any new users for now. We'll be back soon, thanks!
</div>
);
}
Expand Down

0 comments on commit e3b0f2b

Please sign in to comment.