-
Notifications
You must be signed in to change notification settings - Fork 83
build: Update to the latest version of log-surgeon. #1033
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 49 commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
88ccce7
Updated log-surgeon to use simulation branch.
SharafMohamed 8aa0350
Update schema to have all timestamps and capture.
SharafMohamed b3f217b
Testing new log surgeon.
SharafMohamed ea09df0
Testing log surgeon x2.
SharafMohamed 551447f
Add timers.
SharafMohamed ee3f682
Switch timers.
SharafMohamed 042a4f6
Make make dictionaries compilable.
SharafMohamed c311fb8
Merge branch 'main' into new-log-surgeon
SharafMohamed 4b53427
Lint and try to reduce the number of jobs during deps:core to avoid m…
SharafMohamed 3d27fdf
Remove JOBS from task, the correct way is to set the parallel tasks v…
SharafMohamed 018eccb
Remove components/core/submodules/log-surgeon.
davidlion 5971025
Unset PROF_ENABLED.
davidlion b932b6a
Get clp building with log surgeon locally.
davidlion 8637db5
Merge remote-tracking branch 'upstream/main' into pr-1033
davidlion 50cfd39
Unit tests build, but fail with possible logical errors.
davidlion 0e17e3f
Merge branch 'new-log-surgeon' of https://github.com/SharafMohamed/cl…
SharafMohamed 2083aa4
Remove duplicate REQUIRE check.
SharafMohamed e778979
Fix unit-test bugs.
SharafMohamed da18646
Fix unit-test typo and spacing.
SharafMohamed 8b4b24c
Merge branch 'main' into new-log-surgeon
SharafMohamed 6dcadca
Update log-surgeon to newest version.
SharafMohamed 0844041
Remove profiling changes.
SharafMohamed 3c20be7
Test disabling macos-14.
SharafMohamed e8d5fbb
Test disabling macos-13.
SharafMohamed c8edd58
Readd macos-13 and macos-14 to the CI.
SharafMohamed c0f86e9
Bump log-surgeon version.
davidlion f631545
Add spacing to schemas.txt.
davidlion bb23a83
Drop unused parameter from load_lexer_from_file.
davidlion ea777c3
Remove a missed benchmark change.
SharafMohamed 1d63a20
Format fix.
davidlion dcf3734
Merge commit 'refs/pull/1033/head' of https://github.com/y-scope/clp …
davidlion 9552272
Remove reverse lexer; Rename forward lexer to just lexer.
SharafMohamed 5cc0b14
Lint.
SharafMohamed 23de2c3
Remove TODO.
SharafMohamed 1fa8b79
Merge branch 'main' into new-log-surgeon
SharafMohamed bd2ae8e
Add heading comments to schemas.
davidlion b6c02bf
Merge commit 'refs/pull/1033/head' of https://github.com/y-scope/clp …
davidlion d43c4c7
Update schema timestamps to escape '.'.
SharafMohamed 327d41e
Merge branch 'main' into new-log-surgeon
SharafMohamed d557467
Update regex in schema for leading spaces.
SharafMohamed a41ee92
Add issue link in schemas.txt.
davidlion f3f3c59
Merge commit 'refs/pull/1033/head' of https://github.com/y-scope/clp …
davidlion fbf6195
Make lexer safer in clo; Remove dead declaration in clg.
davidlion d1756ef
Update components/core/config/schemas.txt
davidlion 8d12a2b
Update components/core/config/schemas.txt
davidlion 46bc35f
Update components/core/config/schemas.txt
davidlion 063297d
Delete redundant timestamps.
davidlion 75dab67
Allow dates with space + single digit.
davidlion 716e871
Tweak schemas.
davidlion 70db06f
Consolidate timestamps into fewer regex supporting many more combinat…
davidlion 64c0216
Add missing date case caught by rabbit.
davidlion 4a05836
Avoid recreating the lexer object.
SharafMohamed 4a730a4
Use Lexer object directly instead of a unique_ptr.
SharafMohamed d654f46
Throw error if parsed timestamp can't be encoded.
SharafMohamed a02efee
Reogranize schema slightly.
davidlion 82f9825
Update error message; Reorded if statement; Lint.
SharafMohamed dd5a8a4
Merge branch 'new-log-surgeon' of https://github.com/SharafMohamed/cl…
SharafMohamed 922053b
Add relative timestamp regex.
SharafMohamed 88cea99
Merge branch 'main' into new-log-surgeon
davidlion e0169f1
Merge branch 'main' into new-log-surgeon
davidlion 09889d6
Revert schemas.txt.
davidlion b37b7c1
Merge commit 'refs/pull/1033/head' of https://github.com/y-scope/clp …
davidlion File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,19 +1,102 @@ | ||
| // Delimiters | ||
| delimiters: \t\r\n!"#$%&'\(\)\*,:;<>?@\[\]\^_`\{\|\}~ | ||
| // === | ||
| // Timestamps | ||
| // === | ||
|
|
||
| // Timestamps (using the `timestamp` keyword) | ||
| // E.g. 2015-01-31 15:50:45,392 | ||
| // E.g. 2015-01-31T15:50:45.392 | ||
| // E.g. 2015-01-31T15:50:45,392 | ||
| // E.g. 2015-01-31 15:50:45.392 | ||
| // E.g. 2015-01-31 15:50:45,392 | ||
| // E.g. 2015/01/31T15:50:45.123 | ||
| // E.g. 2015/01/31T15:50:45,123 | ||
| // E.g. 2015/01/31 15:50:45.123 | ||
| // E.g. 2015/01/31 15:50:45,123 | ||
| timestamp:\d{4}[\-/]\d{2}[\-/]\d{2}[T ]\d{2}:\d{2}:\d{2}[,\.]\d{3} | ||
|
|
||
| // E.g. 2015-01-31T15:50:45 | ||
| // E.g. 2015-01-31T15:50:45 | ||
| // E.g. 2015-01-31 15:50:45 | ||
| timestamp:\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2}(\.\d{3}){0,1} | ||
| // E.g. [20150131-15:50:45] | ||
| timestamp:\[\d{8}\-\d{2}:\d{2}:\d{2}\] | ||
| // E.g. 2015-01-31 15:50:45 | ||
| // E.g. 2015/01/31T15:50:45 | ||
| // E.g. 2015/01/31T15:50:45 | ||
| // E.g. 2015/01/31 15:50:45 | ||
| // E.g. 2015/01/31 15:50:45 | ||
| timestamp:\d{4}[\-/]\d{2}[\-/]\d{2}[T ]\d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. [2015-01-31T15:50:45 | ||
| timestamp:\[\d{4}\-\d{2}\-\d{2}T\d{2}:\d{2}:\d{2} | ||
|
|
||
SharafMohamed marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| // E.g. [20170106-16:56:41] | ||
| timestamp:\[\d{4}\d{2}\d{2}\-\d{2}:\d{2}:\d{2}\] | ||
|
|
||
| // E.g. [2015-01-31 15:50:45,085] | ||
| timestamp:\[\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2},\d{3}\] | ||
|
|
||
| // E.g. 2015-01-31 15:50:45 | ||
| // E.g. Started POST /api/v3/internal/allowed for 127.0.0.1 at 2017-06-18 00:20:44 | ||
| // E.g. update-alternatives 2015-01-31 15:50:45 | ||
| timestamp:\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2} | ||
|
|
||
SharafMohamed marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| // E.g. Start-Date: 2015-01-31 15:50:45 | ||
| timestamp:\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. 15/01/31 15:50:45 | ||
| timestamp:\d{2}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. 150131 9:50:45 | ||
| timestamp:\d{2}\d{2}\d{2} [ \d]\d:\d{2}:\d{2} | ||
|
|
||
| // E.g. 01 Jan 2016 15:50:17,085 | ||
| timestamp:[ \d]\d [A-Z][a-z]{2} \d{4} \d{2}:\d{2}:\d{2},\d{3} | ||
|
|
||
| // E.g. Jan 01, 2016 3:50:17 PM | ||
| timestamp:[A-Z][a-z]{2} [ \d]\d, \d{4} [ \d]\d:\d{2}:\d{2} [AP]M | ||
|
|
||
| // E.g. January 31, 2015 15:50 | ||
| timestamp:[A-Z][a-z]+ \d{2}, \d{4} \d{2}:\d{2} | ||
coderabbitai[bot] marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| // E.g. E [31/Jan/2015:15:50:45 | ||
| // E.g. localhost - - [01/Jan/2016:15:50:17 | ||
| // E.g. 192.168.4.5 - - [01/Jan/2016:15:50:17 | ||
| timestamp:\[\d{2}/[A-Z][a-z]{2}/\d{4}:\d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. 192.168.4.5 - - [01/01/2016:15:50:17 | ||
| timestamp:\[\d{2}/\d{2}/\d{4}:\d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. ERROR: apport (pid 4557) Sun Jan 1 15:50:45 2015 | ||
| timestamp:[A-Z][a-z]{2} [A-Z][a-z]{2} [ \d]\d \d{2}:\d{2}:\d{2} \d{4} | ||
|
|
||
| // E.g. <<<2016-11-10 03:02:29:936 | ||
| timestamp:\<\<\<\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2}:\d{3} | ||
|
|
||
| // E.g. Jan 21 11:56:42 | ||
| timestamp:[A-Z][a-z]{2} [ \d]\d \d{2}:\d{2}:\d{2} | ||
|
|
||
| // E.g. 01-21 11:56:42.392 | ||
| timestamp:\d{2}\-\d{2} \d{2}:\d{2}:\d{2}\.\d{3} | ||
|
|
||
| // E.g. 2016-05-08 11:34:04.083464 | ||
| timestamp:\d{4}\-\d{2}\-\d{2} \d{2}:\d{2}:\d{2}\.\d{6} | ||
|
|
||
| // === | ||
| // Delimiters | ||
| // === | ||
|
|
||
| delimiters: \t\r\n!"#$%&'\(\)\*,:;\<=\>\?@\[\]\^_`\{\|\}~ | ||
|
|
||
| // === | ||
| // Specially-encoded variables (using the `int` and `float` keywords) | ||
| // === | ||
|
|
||
| int:\-{0,1}[0-9]+ | ||
| float:\-{0,1}[0-9]+\.[0-9]+ | ||
|
|
||
| // === | ||
| // Dictionary variables | ||
| // === | ||
|
|
||
| hex:[a-fA-F]+ | ||
|
|
||
SharafMohamed marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| // NOTE: `equals` and `hasNumber` only work if `=` is a delimiter, due to | ||
| // https://github.com/y-scope/log-surgeon/issues/131 | ||
| equals:.*=(?<val>.*[a-zA-Z0-9].*) | ||
| hasNumber:.*\d.* | ||
SharafMohamed marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| equals:.*=.*[a-zA-Z0-9].* | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this cover all the known timestamp patterns in
TimestampPattern.cpp?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is best effort, but all patterns in
TimestampPattern.cppshould be in the schema now. The timestamps requiring log boundary knowledge are categorized separately and will be addressed in the future.