-
Notifications
You must be signed in to change notification settings - Fork 463
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
Computing prefs 2.0 #2993
Comments
Why not? |
If it's done as a pure HTML/CSS/JS design, it can then be trivially used on almost any platform without needing separate code-bases, including possibly being directly usable for the web-based preferences editor, and in turn means that any new preferences need to make a change in exactly one location in the code to have them usable by everybody. Whether or not that is worth it is another question of course. |
Personally I (and many other users) will be confused: why some web-page is shown while I want to change local settings? As far as I know, no other application do like this |
I took the liberty to add some markup to the initial proposal because it was hard to read with almost all of the HTML tags missing. Just some quick thoughts:
|
I started implementing this in the dpa_prefs2 branch; |
Can you add a ram limit the prefs, so I can simulate less ram that the detected ram like with CPU's. My use case is running multiple instances of boinc but they both think they have the full ram ammount |
When computer is in use, use at most X %
|
Yeh, I guess I was thinking more about a real number like the config method not the client method. Everything gets complex since the project I use does not set the rsc_memory_bound properly |
The example at the top of this thread shows the procedure
This would be quite useful for Boinc gridcoin miners where a GPU has failed and needs to be immediately excluded from the pool of available GPUs. Along with, or even preceding this preference change, could be the useful tool: |
BOINC grids such as WCG & LHC are mixing very different kinds of projects under the same Preferences. E.g., WCG now has two projects that require a fast turn around; the serial FAH2 and long ARF with sparse checkpoints. Clients need more effective ways to control their work.
And even better would be.
|
Not sure if I understand this feature request correctly, so let me check with a real-world example case (and the reason I found this request): |
@DennisvdPluijm, yes |
Please add device name to windows / linux / mac clients. |
Just a few comments from the trenches (based on decades of first-hand gripes):
Thanks |
The current prefs system can't handle some plausible requirements,
e.g. disabling a particular GPU when the computer is in use.
This is a proposal for a more general prefs system, which I'll call P2.
P2 is intended to be as general as possible,
i.e. it allows any conceivable preferences to be expressed.
That way we only have to do this once.
Like the current system, P2 uses XML to represent preference sets.
It would be possible to use another data representation language such as JSON,
or to use an embedded programming language like Tcl,
but I think XML is the best choice.
A P2 spec consists of a sequence of "clauses".
Each clause consists of a "condition" specifying when it's in effect,
and one or more preferences.
For example, the preference mentioned above would be represented as:
If no condition is given, the clause is always in effect.
Typically a spec will begin with such a clause.
The clauses are evaluated in order.
Later clauses (if their conditions are met) override earlier ones.
For example, if we want to enable GPU use from 5PM to 7AM,
regardless of idleness, we'd add another clause
Conditions
P2 conditions are boolean expressions.
The primitives are
<idle_time_more_than>
true if mouse/keyboard input in last N seconds
<on_batteries>
true if running on batteries
<program_running>name</program_running>
true if "name" is executing
<daytime>X:Y</daytime>
true if day is in range X and time is in range Y
<cpu_usage_more_than>X</cpu_usage_more_than>
non-BOINC CPU usage exceeds X
<external>X</external>
the GUI has told us that condition "X" holds.
<battery_charge_more_than>
<battery_temperature_more_than>
<on_wifi>
connected via WiFi (mobile)
Boolean expression can be formed using
<not>X</not>
negation of X
<or>...</or>
or of 2 or more expressions
<and>...</and>
and of 2 or more expressions
Expressions can be nested.
Prefs
The following are typically static but it doesn't hurt to make them dynamic.
Implementation, Phase 1
The goal of this phase is to make the features of P2
available to users who are willing to write XML specs.
Steps:
a) define a C++ data structure to represent a P2 preference set.
b) write code that parses an old-style specs (global_prefs.xml, cc_config.xml)
into this data structure.
c) enforce prefs based on the new data structure, rather than GLOBAL_PREFS.
Need to evaluate prefs when
This is entirely within the client; I should do this part.
Implementation, Phase 2
The goal of this phase is to provide GUIs for editing P2 prefs.
In both web and desktop, the primary GUI should be choosing a preset
(standard, max computing, green, etc.).
An "Advanced" button leads to a full-featured prefs editor, which lets you
This editor should be implemented using HTML and Javascript.
There are various JS frameworks that could be used.
In the desktop case (i.e. BOINC Manager or Android GUI)
the Advanced button should take you to a prefs-editor web page,
served from the BOINC web site.
The "Save" button writes the resulting XML to a local file.
In other words, we should NOT implement P2 prefs editors
in the WxWidgets and Android GUIs.
Developing the editor is a self-contained task and anyone
with HTML/JS experience could do it.
Integrating it with the BOINC web code and with the GUIs
would be a small amount of additional work.
The text was updated successfully, but these errors were encountered: