Skip to content
This repository has been archived by the owner on Jan 12, 2022. It is now read-only.

looker: log series with synthetic time source coupled to wall time (part 1) #1310

Merged
merged 31 commits into from
Aug 23, 2021

Conversation

jgehrcke
Copy link
Contributor

@jgehrcke jgehrcke commented Aug 20, 2021

From: #982

Implement the "synthetic time source loosely coupled to wall time" approach also for logs mode.

That's what this PR is mainly about. It does not fully implement this 'feature' yet, but is just a significant milestone on the path to that state.

In addition to that, this PR:

Batch rename from #1009 was going into
the 'wrong' direction :).

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Instead of having one option using the unit
`ms` and another option using the unit `ns`
use the same for both series types.

With that, common constructor logic can be
deduplicated much easier.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Also, set walltime coupling options for
both cases. With this commit, there should
be no behavioral change for log series as
well as metric series.

tsc shows no error.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
already with slight adjustments, but incomplete
also does not compile yet

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
And validation logic. This starts to look
good.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Interface / stubs were moved to base class,
rebuild previous logic by filling in

lastSampleSecondsSinceEpoch()
and
leapForward()

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
I saw on a this PR that looker artifact
collection is now broken because it terminates
the calling script (as of errexit opt) before
that can invoke the collection commands.

change paradigm: use errexit in invoke-looker.sh
and call via a new shell -- capture exit
code of that process.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Breaking change, for sure. Has to to be done.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
cannot serialize bigint to json, so take this
route and do runtime type validation

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Also, there seems to be a formatting update.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Important: factor 1000
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
queryLoki(): change req timeout cfg: bump
'request' timeout parameter (covering all
request phases) by a little more than
factor two. Kind of unexpected to help.
But if it does: interesting to learn about
_why_.

Most importantly, I'd like to understand
based on log output how many requests
are really made during the polling
loop and how those fail that currently
do not generate log output.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Can be re-used in children

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Initialized on base class now.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
And also adjust child classes here and there.
This is almost complete but does not
compile yet.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Now that the LogSeries class also supports
the loose walltime coupling the two cases
here can be treated the same way, using
generateNextFragmentOrSkip()

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
Make it so that `minLagSeconds` comes
with a guarantee (never make the actual
lag smaller than that).

This makes the throttling criterion
easier to build and read.

This removes the need for validation
(`mtls` code removal).

This required proper introduction of
`fragmentTimeLeapSeconds`.

All these are nice.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
The stringified options were getting a little
long. This wasn't useful anymore. What's more
useful is showing the unique properties of the
time series -- which are given by the
query string.

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
also reduce time constant (follow-up
from previous commit where I bumped
from 5 to 12 but I think this is
better)

Signed-off-by: Dr. Jan-Philip Gehrcke <jp@opstrace.com>
@jgehrcke jgehrcke changed the title looker: log series with synthetic time source coupled to wall time (wip) looker: log series with synthetic time source coupled to wall time (part 1) Aug 23, 2021
@jgehrcke
Copy link
Contributor Author

good state, merging now to land CI improvements. follow-up pr for looker upcoming.

@jgehrcke jgehrcke merged commit 3b39a22 into main Aug 23, 2021
@jgehrcke jgehrcke deleted the jp/looker-logs-coupled-to-walltime branch August 23, 2021 12:33
@jgehrcke
Copy link
Contributor Author

main-test-aws failed via
https://buildkite.com/opstrace/prs/builds/5605#fca52896-4220-4818-be7d-a6355f906125/6-1297

which is caused by #1226 but shows a skewed symptom because of retry not being 0 in the got options

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant