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

[WIP] Free flag on smt (bsc#970990) #264

Closed
wants to merge 2 commits into from

Conversation

Projects
None yet
2 participants
@lslezak
Copy link
Member

commented Jul 24, 2016

See bug https://bugzilla.suse.com/show_bug.cgi?id=970990

Unfortunately this won't work correctly in all cases. The SCC vs. SMT detection is currently done via the registration server URL.

This will work correctly with the SCC or an SMT server. However, this will break when using the SCC Proxy. In that case the URL is different than the SCC server but the specified server (the proxy) just forwards the registration to the real SCC. And SCC (in contrast to SMT) will require registration codes.

Unfortunately the SCC Proxy is used in openQA so we cannot ignore this use case.

The proposed solutions:

  • Add a new flag in the server response. In addition to free, which defines whether the addon is paid, we could add a new flag (e.g. regcode_required) which would tell that the server requires a reg. code for this addon.
    Unfortunately this would need a change on the SMT and SCC side. (Or at least on the SCC side, we could use default false for SMT when the value is missing in the response.)
  • Detect SMT via some API call which returns different value on SCC or SMT (or returns an different error). Or check the HTTP header?
    The question is whether this is possible and how reliable it is...
  • Change the registration workflow - first try registering without any reg. code if it fails with "No reg. code" error ask user for the reg. code and try again.
    Trying blindly registering an addon sounds a bit strange, we would need carefully check for the errors, esp. finding that it's just because of a missing reg. code would be tricky and likely fragile.

Any other opinions, suggestions?

lslezak added some commits Jul 20, 2016

@coveralls

This comment has been minimized.

Copy link

commented Jul 24, 2016

Coverage Status

Coverage increased (+0.01%) to 84.433% when pulling f8723fa on free_flag_on_smt into cfc09ca on master.

@lslezak

This comment has been minimized.

Copy link
Member Author

commented Aug 16, 2016

I'm closing this as it currently seems we do not need this change.

I'll keep the branch so we can reopen if needed in the end.

See the discussion at https://bugzilla.suse.com/show_bug.cgi?id=970990.

@lslezak lslezak closed this Aug 16, 2016

@jreidinger jreidinger deleted the free_flag_on_smt branch Jun 7, 2017

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