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

Geth "Miner and DAG" management API's implemented (web3-eth-miner) #2660

Merged
merged 29 commits into from
Apr 16, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
42b4b6a
Miner core methods added
princesinha19 Apr 7, 2019
ac53f8d
web3-eth-miner implemented
princesinha19 Apr 7, 2019
37f09d2
Merge branch '1.0' into miner-methods
princesinha19 Apr 8, 2019
b0b08d9
web3-eth-miner documentation
princesinha19 Apr 8, 2019
1aff76c
requested changes
princesinha19 Apr 9, 2019
ffb12a2
updated package.json
princesinha19 Apr 9, 2019
2b9fe8b
Removed web3-eth dependency
princesinha19 Apr 12, 2019
a16c5d5
Removed web3-eth dependency
princesinha19 Apr 12, 2019
5840947
Name fix
princesinha19 Apr 15, 2019
5643414
dependency fix
princesinha19 Apr 15, 2019
d95cbc7
Merge branch '1.0' into miner-methods
nivida Apr 15, 2019
93f965e
Merge branch '1.0' into miner-documentation
nivida Apr 15, 2019
bbf0571
pipelibe fix
princesinha19 Apr 15, 2019
47a9e4d
Merge branch 'miner-methods' of https://github.com/princesinha18/web3…
princesinha19 Apr 15, 2019
97963f2
pipeline fix
princesinha19 Apr 15, 2019
17f94a6
Merge branch 'miner-documentation' of https://github.com/princesinha1…
princesinha19 Apr 15, 2019
f78836e
multiple blankline fix
princesinha19 Apr 15, 2019
569941c
pipeline fix
princesinha19 Apr 15, 2019
6fb1560
pipeline fix
princesinha19 Apr 15, 2019
e8776fd
pipeline fix
princesinha19 Apr 15, 2019
0fb9d63
Removed accounts dependency
princesinha19 Apr 15, 2019
aec127b
Revert "Merge branch 'miner-documentation' of https://github.com/prin…
princesinha19 Apr 15, 2019
4d0fdd7
Conflict resolved
princesinha19 Apr 15, 2019
bb825c0
Conflict resolved
princesinha19 Apr 15, 2019
7b3c50c
Conflict resolved
princesinha19 Apr 15, 2019
cc70dcb
rsolve conflict
princesinha19 Apr 15, 2019
51f2dd5
Merge branch '1.0' into miner-methods
princesinha19 Apr 15, 2019
462182b
resolve comflict
princesinha19 Apr 15, 2019
4ab586e
Merge branch '1.0' into miner-methods
nivida Apr 16, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 22 additions & 25 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 9 additions & 1 deletion packages/web3-core-method/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
*/
/**
* @file index.js
* @author Samuel Furter <samuel@ethereum.org>, Prince Sinha <sinhaprince013@gmail.com>
* @author Samuel Furter <samuel@ethereum.org>
* @author Prince Sinha <sinhaprince013@gmail.com>
* @date 2018
*/

Expand Down Expand Up @@ -135,3 +136,10 @@ export StartWsMethod from './methods/admin/StartWsMethod';
export StopRpcMethod from './methods/admin/StopRpcMethod';
export StopWsMethod from './methods/admin/StopWsMethod';

// Miner
export SetEtherBaseMethod from './methods/miner/SetEtherBaseMethod';
export SetExtraMethod from './methods/miner/SetExtraMethod';
export SetGasPriceMethod from './methods/miner/SetGasPriceMethod';
export StartMinerMethod from './methods/miner/StartMinerMethod';
export StopMinerMethod from './methods/miner/StopMinerMethod';

36 changes: 36 additions & 0 deletions packages/web3-core-method/src/methods/miner/SetEtherBaseMethod.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
This file is part of web3.js.

web3.js is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

web3.js is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with web3.js. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @file SetEtherBaseMethod.js
* @author Prince Sinha <sinhaprince013@gmail.com>
* @date 2019
*/

import AbstractMethod from '../../../lib/methods/AbstractMethod';

export default class SetEtherBaseMethod extends AbstractMethod {
/**
* @param {Utils} utils
* @param {Object} formatters
* @param {AbstractWeb3Module} moduleInstance
*
* @constructor
*/
constructor(utils, formatters, moduleInstance) {
super('miner_setEtherbase', 1, utils, formatters, moduleInstance);
}
}
36 changes: 36 additions & 0 deletions packages/web3-core-method/src/methods/miner/SetExtraMethod.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
This file is part of web3.js.

web3.js is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

web3.js is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with web3.js. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @file SetExtraMethod.js
* @author Prince Sinha <sinhaprince013@gmail.com>
* @date 2019
*/

import AbstractMethod from '../../../lib/methods/AbstractMethod';

export default class SetExtraMethod extends AbstractMethod {
/**
* @param {Utils} utils
* @param {Object} formatters
* @param {AbstractWeb3Module} moduleInstance
*
* @constructor
*/
constructor(utils, formatters, moduleInstance) {
super('miner_setExtra', 1, utils, formatters, moduleInstance);
}
}
36 changes: 36 additions & 0 deletions packages/web3-core-method/src/methods/miner/SetGasPriceMethod.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
This file is part of web3.js.

web3.js is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

web3.js is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with web3.js. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @file SetGasPriceMethod.js
* @author Prince Sinha <sinhaprince013@gmail.com>
* @date 2019
*/

import AbstractMethod from '../../../lib/methods/AbstractMethod';

export default class SetGasPriceMethod extends AbstractMethod {
/**
* @param {Utils} utils
* @param {Object} formatters
* @param {AbstractWeb3Module} moduleInstance
*
* @constructor
*/
constructor(utils, formatters, moduleInstance) {
super('miner_setGasPrice', 1, utils, formatters, moduleInstance);
}
}
36 changes: 36 additions & 0 deletions packages/web3-core-method/src/methods/miner/StartMinerMethod.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
This file is part of web3.js.

web3.js is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

web3.js is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with web3.js. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @file StartMinerMethod.js
* @author Prince Sinha <sinhaprince013@gmail.com>
* @date 2019
*/

import AbstractMethod from '../../../lib/methods/AbstractMethod';

export default class StartMinerMethod extends AbstractMethod {
/**
* @param {Utils} utils
* @param {Object} formatters
* @param {AbstractWeb3Module} moduleInstance
*
* @constructor
*/
constructor(utils, formatters, moduleInstance) {
super('miner_start', 1, utils, formatters, moduleInstance);
}
}
Loading