Skip to content

Feature/boilerplate#853

Draft
bassosimone wants to merge 89 commits intomasterfrom
feature/boilerplate
Draft

Feature/boilerplate#853
bassosimone wants to merge 89 commits intomasterfrom
feature/boilerplate

Conversation

@bassosimone
Copy link
Copy Markdown
Contributor

Checklist

  • I have read the contribution guidelines
  • reference issue for this pull request:
  • if you changed anything related how experiments work and you need to reflect these changes in the ooni/spec repository, please link to the related ooni/spec pull request:

Description

Please, insert here a more detailed description.

This mechanical refactoring moves model.Engine to the model
package. This changce is functional to subsequent changes to
more easily generate and maintain existing experiments.
Like the previous commit, here the idea is to move things around
in a mechanical fashion before working on more substantial changes.
Here the idea is that the logic for creating an experiment lives in
internal/registry along with a list of experiments.

In turn, this design will allow us soon to make it very easy to add a
new experiment, by making each experiment register itself.

However, before doing that, I need to refactor the code so that
each experiment and the engine can both import from registry.

    +---------------+                 +--------+
    | An experiment |                _| engine |
    +---------------+               | +--------+
              |                     |
              |                     |
              |      +----------+   |
              `----->| registry |<--.  imports
          imports    +----------+

Once the above is possible, then each experiment can register itself.
This design allows us to automatically add new experiments by
writing files in the proper package.
Also, make it opportunistic rather than measuring each time.

So, we'll have some more measurements.
Conflicts:
	go.mod
	internal/measurexlite/trace.go
Conflicts:
	internal/measurexlite/conn.go
	internal/measurexlite/dialer.go
	internal/model/archival.go
1. adapt the template to allow for collecting the data we need

2. recognize that support for cookies is optional, so it should
probably always be there
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant