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

Refactor NRTM4 Database to emulate WHOIS Database #1579

Open
wants to merge 116 commits into
base: master
Choose a base branch
from

Conversation

MiguelAHM
Copy link
Contributor

No description provided.

@eshryane
Copy link
Member

Don't duplicate the RIPE database schema in nrtm_update_schema.sql but just use whois_schema.sql


if (snapshot == null){
LOGGER.error("Snapshot cannot be null in the notification file");
return Maps.newHashMap();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this fail? i.e. throw an exception

Copy link
Contributor Author

@MiguelAHM MiguelAHM Nov 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

well, it is more or less the same that we talked in the office today?
We will retry this in a minute and the error is already in the logs because of the LOGGER.error

final int version = jsonObject.getInt("version");
final String sessionId = jsonObject.getString("session_id");
if (!sessionId.equals(updateNotificationFile.getSessionID())) {
// TODO: [MH] if the service is wrong for any reason...we have here a non-ending loop, we need to
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolve TODO

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know how to resolve it. I put this here to discuss with you

@MiguelAHM
Copy link
Contributor Author

MiguelAHM commented Nov 14, 2024

Don't duplicate the RIPE database schema in nrtm_update_schema.sql but just use whois_schema.sql

This is risky, I don't want to use the main schema where we are storing all the data for this.
Imagine that we deploy this at some point in PROD and by mistake we turn on the NRTM4 client in properties...
I don't feel comfortable using the main schema...it can be overwritten or we can put dirt on it by mistake

@MiguelAHM
Copy link
Contributor Author

Don't duplicate the RIPE database schema in nrtm_update_schema.sql but just use whois_schema.sql

This is risky, I don't want to use the main schema where we are storing all the data for this. Imagine that we deploy this at some point in PROD and by mistake we turn on the NRTM4 client in properties... I don't feel comfortable using the main schema...it can be overwritten or we can put dirt on it by mistake

Correction after discussing: Basically don't copy paste this...we will still use another schema but don't copy paste the .sql

@MiguelAHM MiguelAHM marked this pull request as ready for review November 14, 2024 14:52
@eshryane
Copy link
Member

Don't duplicate the RIPE database schema in nrtm_update_schema.sql but just use whois_schema.sql
...
Correction after discussing: Basically don't copy paste this...we will still use another schema but don't copy paste the .sql

Yes, use the whois_schema.sql to setup the mirror database for importing RPSL objects (including integration tests).

@MiguelAHM
Copy link
Contributor Author

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.

2 participants