Skip to content
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

FDB table with history capabilities #9804

Merged
merged 13 commits into from Feb 21, 2019

Conversation

Projects
None yet
2 participants
@PipoCanaja
Copy link
Contributor

commented Feb 11, 2019

Hi,

Let's work at the implementation for FDB table history.

Cleaning is done in daily.sh

PipoCanaja

DO NOT DELETE THIS TEXT

Please note

Please read this information carefully. You can run ./scripts/pre-commit.php to check your code before submitting.

Testers

If you would like to test this pull request then please run: ./scripts/github-apply <pr_id>, i.e ./scripts/github-apply 9804
After you are done testing, you can remove the changes with ./scripts/github-remove. If there are schema changes, you can ask on discord how to revert.

@PipoCanaja PipoCanaja added the Feature label Feb 11, 2019

@murrant

This comment has been minimized.

Copy link
Member

commented Feb 11, 2019

The daily script matches a lot of other tables and saves mysql load during polling.

(Off topic, we should have a validation check for records older than cleanup values in the validation script)

@PipoCanaja

This comment has been minimized.

Copy link
Contributor Author

commented Feb 11, 2019

OK, I'll have a look at how daily.sh does his magic. Never opened it so far.

@PipoCanaja

This comment has been minimized.

Copy link
Contributor Author

commented Feb 11, 2019

Ahaha,
A funny issue with Travis now. How do we deal with timestamps in a test ? Of course, they don't match :

          1 => Array (
              'mac_address' => '001b382a7bc6'
 -            'date_discovered' => '2019-02-11 21:44:39'
 -            'date_last_seen' => '2019-02-11 21:44:39'
 +            'date_discovered' => '2019-02-11 21:24:40'
 +            'date_last_seen' => '2019-02-11 21:24:40'
              'ifIndex' => 9
              'vlan_vlan' => 1170
          )
@murrant

This comment has been minimized.

Copy link
Member

commented Feb 13, 2019

@PipoCanaja usually I exclude fields from that from being captured. Kinda means we don't test them, but those fields don't really work in integration tests.

@PipoCanaja

This comment has been minimized.

Copy link
Contributor Author

commented Feb 13, 2019

@PipoCanaja usually I exclude fields from that from being captured. Kinda means we don't test them, but those fields don't really work in integration tests.

@murrant : How do you exclude them ? just not collecting FDB data at all ?

@PipoCanaja PipoCanaja force-pushed the PipoCanaja:fdb-history branch from cb995d7 to d3d29d6 Feb 13, 2019

@PipoCanaja

This comment has been minimized.

Copy link
Contributor Author

commented Feb 13, 2019

@murrant : How do you exclude them ? just not collecting FDB data at all ?

Found it.

@murrant

This comment has been minimized.

Copy link
Member

commented Feb 14, 2019

@PipoCanaja I tested this and it works great. The only thing I was wondering is about a way to show only current fdb entries.

@PipoCanaja PipoCanaja force-pushed the PipoCanaja:fdb-history branch from e9c6dcc to 7314fb2 Feb 16, 2019

@PipoCanaja

This comment has been minimized.

Copy link
Contributor Author

commented Feb 16, 2019

@PipoCanaja I tested this and it works great. The only thing I was wondering is about a way to show only current fdb entries.

@murrant : Good question. My idea now is to only display and allow sorting (and of course searching).
That should provide both the current view and the history view depending on how you filter the data. Most probably users will let us know if they lack a way of displaying things.

@PipoCanaja PipoCanaja changed the title WIP - FDB table with history capabilities FDB table with history capabilities Feb 16, 2019

Show resolved Hide resolved daily.php

PipoCanaja added some commits Feb 20, 2019

@murrant
Copy link
Member

left a comment

LGTM

@PipoCanaja PipoCanaja merged commit e2f835a into librenms:master Feb 21, 2019

5 of 6 checks passed

codeclimate 5 issues to fix
Details
Inspection Summary
Details
Node: analysis
Details
Travis CI - Pull Request Build Passed
Details
WIP Ready for review
Details
license/cla Contributor License Agreement is signed.
Details

@PipoCanaja PipoCanaja deleted the PipoCanaja:fdb-history branch Feb 21, 2019

@lock lock bot locked as resolved and limited conversation to collaborators Apr 22, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.