|
6 | 6 | import * as vscode from 'vscode'
|
7 | 7 | import { CLOUDWATCH_LOGS_SCHEME } from '../../shared/constants'
|
8 | 8 | import { CloudWatchLogsGroupInfo, LogDataRegistry } from '../registry/logDataRegistry'
|
9 |
| -import { createURIFromArgs, isLogStreamUri, parseCloudWatchLogsUri } from '../cloudWatchLogsUtils' |
| 9 | +import { |
| 10 | + CloudWatchLogsSettings, |
| 11 | + createURIFromArgs, |
| 12 | + isLogStreamUri, |
| 13 | + parseCloudWatchLogsUri, |
| 14 | +} from '../cloudWatchLogsUtils' |
10 | 15 | import { LogDataDocumentProvider } from './logDataDocumentProvider'
|
11 | 16 |
|
12 | 17 | type IdWithLine = { streamId: string; lineNum: number }
|
@@ -57,7 +62,9 @@ export class LogStreamCodeLensProvider implements vscode.CodeLensProvider {
|
57 | 62 | }
|
58 | 63 |
|
59 | 64 | createLogStreamCodeLens(logGroupInfo: CloudWatchLogsGroupInfo, idWithLine: IdWithLine): vscode.CodeLens {
|
60 |
| - const streamUri = createURIFromArgs({ ...logGroupInfo, streamName: idWithLine.streamId }, { limit: 1000 }) |
| 65 | + const settings = new CloudWatchLogsSettings() |
| 66 | + const limit = settings.get('limit', 1000) |
| 67 | + const streamUri = createURIFromArgs({ ...logGroupInfo, streamName: idWithLine.streamId }, { limit: limit }) |
61 | 68 | const cmd: vscode.Command = {
|
62 | 69 | command: 'aws.loadLogStreamFile',
|
63 | 70 | arguments: [streamUri, this.registry],
|
|
0 commit comments