Skip to content

Commit

Permalink
refactor: revert #980 in favor of a jsforce solution
Browse files Browse the repository at this point in the history
  • Loading branch information
mshanemc committed Nov 14, 2023
1 parent 515b5a8 commit ac78de4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 20 deletions.
10 changes: 0 additions & 10 deletions messages/org.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,3 @@ We found more than one SandboxProcess with the SandboxName %s.
# sandboxNotResumable

The sandbox %s cannot resume with status of %s.

# UnexpectedResponse

Unexpected response from the platform

# UnexpectedResponse.actions

- Check that the instance URL is correct and the org still exists.

- See what's at the URL that's causing the problem: %s.
12 changes: 2 additions & 10 deletions src/org/org.ts
Original file line number Diff line number Diff line change
Expand Up @@ -698,17 +698,9 @@ export class Org extends AsyncOptionalCreatable<Org.Options> {
url: this.getConnection().baseUrl(),
method: 'GET',
};

const conn = this.getConnection();
try {
await conn.request(requestInfo);
} catch (e) {
// an html error page like https://computing-connect-6970-dev-ed.scratch.my.salesforce.com/services/data/v50.0
// where the message is an entire html page
if (e instanceof Error && (e.name.includes('ERROR_HTTP') || e.message.includes('<html '))) {
throw messages.createError('UnexpectedResponse', [], [conn.baseUrl()], e);
}
throw e;
}
await conn.request(requestInfo);
}

/**
Expand Down

4 comments on commit ac78de4

@svc-cli-bot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Logger Benchmarks - ubuntu-latest

Benchmark suite Current: ac78de4 Previous: 515b5a8 Ratio
Child logger creation 493333 ops/sec (±0.58%) 291961 ops/sec (±3.13%) 0.59
Logging a string on root logger 844131 ops/sec (±7.88%) 506516 ops/sec (±8.59%) 0.60
Logging an object on root logger 660597 ops/sec (±9.13%) 364444 ops/sec (±9.71%) 0.55
Logging an object with a message on root logger 28874 ops/sec (±182.97%) 260472 ops/sec (±10.15%) 9.02
Logging an object with a redacted prop on root logger 538971 ops/sec (±10.35%) 278929 ops/sec (±14.80%) 0.52
Logging a nested 3-level object on root logger 21429 ops/sec (±185.31%) 3068 ops/sec (±211.43%) 0.14

This comment was automatically generated by workflow using github-action-benchmark.

@svc-cli-bot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'Logger Benchmarks - ubuntu-latest'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: ac78de4 Previous: 515b5a8 Ratio
Logging an object with a message on root logger 28874 ops/sec (±182.97%) 260472 ops/sec (±10.15%) 9.02

This comment was automatically generated by workflow using github-action-benchmark.

@svc-cli-bot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Logger Benchmarks - windows-latest

Benchmark suite Current: ac78de4 Previous: 515b5a8 Ratio
Child logger creation 342487 ops/sec (±0.59%) 342538 ops/sec (±0.75%) 1.00
Logging a string on root logger 780924 ops/sec (±8.47%) 922875 ops/sec (±6.73%) 1.18
Logging an object on root logger 593347 ops/sec (±5.22%) 35643 ops/sec (±184.54%) 0.06007108825021446
Logging an object with a message on root logger 8579 ops/sec (±200.16%) 384860 ops/sec (±5.73%) 44.86
Logging an object with a redacted prop on root logger 449208 ops/sec (±6.93%) 480393 ops/sec (±5.87%) 1.07
Logging a nested 3-level object on root logger 336063 ops/sec (±5.57%) 22063 ops/sec (±183.35%) 0.06565138084228254

This comment was automatically generated by workflow using github-action-benchmark.

@svc-cli-bot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'Logger Benchmarks - windows-latest'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: ac78de4 Previous: 515b5a8 Ratio
Logging an object with a message on root logger 8579 ops/sec (±200.16%) 384860 ops/sec (±5.73%) 44.86

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.