-
Notifications
You must be signed in to change notification settings - Fork 370
Conversation
Hey @CodeMonkeySteve, Thanks for the PR! If you decide to do the neccessary changes, please also create a new PearlDiverConfig interface. |
1 similar comment
Hey @CodeMonkeySteve, Thanks for the PR! If you decide to do the neccessary changes, please also create a new PearlDiverConfig interface. |
Hey @CodeMonkeySteve, Thanks for the PR! If you decide to do the neccessary changes, please also create a new PearlDiverConfig interface. |
I added the PearlDiver config, mimicking the other config, but there doesn't seem to be any effect from setting Any insight would be greatly appreciated (I am not really a Java developer, as you may have noticed). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not bad :-)
Do the changes and try the INI file again :-)
|
||
@JsonProperty | ||
@Parameter(names = "--pow-threads", description = PearlDiverConfig.Descriptions.POW_THREADS) | ||
protected void setPoWThreads(int powThreads) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change to setPowThreads
protected void setPoWThreads(int powThreads) { | |
protected void setPowThreads(int powThreads) { |
Jackson knows how to translate the name to snake_case. This is why ini wasn't working
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, thanks so much, that fixed it.
/** | ||
* Configurations for PearlDiver proof-of-work hasher. | ||
*/ | ||
public interface PearlDiverConfig extends Config { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer PowConfig
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Er, you originally asked for PearlDiverConfig. I think that's more appropriate, as there may be other config fields added later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great!
Awesome stuff, thank you @CodeMonkeySteve! |
Happy to help. It's also in my own best interest, as I'm creating >10k transactions per day, so I need to make use of all the CPU cores I have. |
Description
Add configuration variable for the number of PoW threads, for manual control.
Fixes #1016
Type of change
How Has This Been Tested?
Deployed to production IOTA node, verified specified number of threads were used by CPU load.
Checklist: