Commit Graph

99 Commits

Author SHA1 Message Date
Chris Beams 936de35cff
Restore JDK 8 source compatibility in ethereumj-studio
This partially reverts commit c95f5ea, restoring use of Java 8 language
features and APIs to ethereumj-studio, while leaving etherumj-core
pinned to the Java 7 language level for Dalvik compatibility reasons.
For further details, see the prior commit and
https://github.com/ethereum/ethereumj/commit/c95f5ea#commitcomment-9119435.
2014-12-30 20:09:20 +01:00
Roman Mandeleil c95f5ea75f reverting for java7 2014-12-30 13:45:16 +02:00
Chris Beams d099100adf
Replace anonymous types with lambdas and method refs 2014-12-27 03:53:34 +01:00
Chris Beams 18b0f6f52c
Replace explicit types with <> syntax 2014-12-27 03:30:42 +01:00
Chris Beams 6c4502150e
Remove redundant type casts 2014-12-27 03:30:17 +01:00
Chris Beams 780393dae9
Organize imports with shared IDEA configuration
Add .idea/codeStyleSettings.xml with explicit settings for each
2nd-level package used within ethereumj, adding a separator between
each (unfortunately there is no other way to gain this level of control
in IDEA).

Imports are generally in alphabetical order, with two key exceptions:

 - org.ethereumj.* imports are always sorted at top, to simplify the
process of seeing how one ethereumj type relates to all others. This is
especially useful in the practice of avoiding cyclic package
dependencies.

 - java.* and javax.* and sun.* imports are always sorted at bottom.

Wildcard imports are used for static imports whenever two or more
members of the same type are statically imported, but wildcards are
never used for non-static imports. This policy of explicitness helps
identify classes that are too "fat", i.e. have too many dependencies on
other types.

The root .gitignore file has been updated to allow
.idea/codeStyleSettings.xml, so as to automatically share it with other
team members. Any changes made to import organization settings will be
reflected in this file and should be checked in.
2014-12-27 02:16:02 +01:00
Chris Beams d7671814b7
Remove unused imports 2014-12-27 01:44:27 +01:00
Chris Beams 75443aaa13
Support running ethereumj-studio as executable jar
See updated ethereumj-studio/README.md for details. Note that this
commit removes the `build-post-package.xml` ant file (for now) to
simplify the Gradle arrangement. This functionality can be re-introduced
later and more simply using Gradle's native DSL. In the meantime, both
the -core and -studio projects can be run using `gradle run` or run as
executable jars by running `gradle shadowJar` followed by the usual
`java -jar` execution of the resulting `-all` jar file found in each
project's respective `build/libs` directory.
2014-12-27 01:44:25 +01:00
Chris Beams 0900039bdd
Introduce top-level Gradle build
- Convert ethereumj-studio build from Maven to Gradle as well
 - Extract common build elements to top-level build.gradle
 - Update top-level README accordingly
2014-12-27 01:44:24 +01:00
Chris Beams c396eb11ea
Compensate for removal of gas price methods in poc-7
Block#getMinGasPrice and Blockchain#getGasPrice were removed in commit
aad53ba, causing compilation failures in ethereumj-studio when building
against current master of ethereumj-core. As it is unclear whether these
methods have proper replacements, this commit simply replaces calls to
these now-missing methods with the value `42`. Obviously this is a
stopgap measure and should be addressed properly as soon as possible.
2014-12-26 23:45:06 +01:00
Chris Beams a63f6445cc
Remove urls from class-level Javadoc
Prior to this change, the affected classes had Javadoc containing a url
as the first sentence. There were several issues with this:

 - The url used was inconsistent, varying between www.etherj.com,
   www.ethereumj.com and www.ethergit.com

 - Use of a url in the first sentence of a Javadoc comment is not
   consistent with Javadoc idioms. The first sentence should be the
   a short, self-contained description--in this case, the description of
   the class. If no such description is yet available, it is best to
   simply omit all text, leaving any tags (such as @author or @since).

 - Information about the project that this code belongs to should be
   expressed in the license header for each file. Currently, most files
   in ethereumj do not have license headers. This can be added in a
   later commit.
2014-12-26 11:57:21 +01:00
Chris Beams 7d2cf7f954
Use @since tags in Javadoc vs. "created on" metadata
- @since is recognized by Javadoc processor; "created on:" is not
 - Remove hh:mm information as it is unnecessary
 - Replace slashes in dates with dots, e.g. 26/12/2014 => 26.12.2014
2014-12-26 11:47:47 +01:00
Chris Beams c38907bc34
Use correct syntax for Javadoc @author tags 2014-12-26 11:38:30 +01:00
Chris Beams 58874cfc7e
Apply basic formatting
- Do not align assignments on equals signs
 - Use spaces before opening curly braces
 - Add spaces between parameters as necessary
 - Insert newlines between method declarations
 - Other minor changes

This formatting pass is not comprehensive. For the most part, it does
not deal with Javadoc formatting, line wrapping, parameter alignment
rules or a number of other items that can be addressed later.
2014-12-26 11:22:44 +01:00
Chris Beams e5fcf5b48e
Strip trailing whitespace 2014-12-26 09:45:14 +01:00
Chris Beams 0827fb5c8f
Convert tabs to spaces
Prior to this change, 78% of lines in .java files with leading
whitespace used four-space indentation, while 22% used tabs.
2014-12-26 09:42:39 +01:00
ligi 99af4432a9 fix an error ( Error: Unable to access jarfile ./lib/ethereumj-0.7.9.jar ) 2014-12-10 17:00:06 +01:00
romanman f443bb6157 Bumping versions 2014-11-23 21:43:55 +01:00
romanman 8bf61332ae Repository redesign:
+ clean and structured design of the tracker
+ batch write to the db at end of the process
+ record blocks for runnable test scenario
2014-11-19 12:46:28 -05:00
romanman b94065e173 Cardinal Redesign:
+ Spring IoC introduced
+ Block Store by sql/hibernate introduced
- Cache for blocks vanished
+ CLI for start
+ Connection architecture redesign for multiple connections
+ Server for incoming connections
+ Test adaption for new architecture and fix
+ Performance major improve: loading empty blocks: 10,000 for 40 secs
+ Blocks forking/alternative chains sollution
2014-11-16 14:19:40 -05:00
romanman 31037d2bcd minor fixes:
+ studio console back to work
+ onRecvMsg/onSendMsg listener fixed
2014-11-04 16:42:22 -05:00
romanman db1388a279 Follow up merge 2014-11-03 13:59:45 -05:00
nicksavers a63f100dda Remove unused protocol property 2014-11-03 17:23:49 +01:00
romanman 1a01f17f4c Transaction structure adapt for 0.7.8 and several bug fix
* it's possible now to have full block chain sync with 0.7.8 peer
2014-11-03 10:59:17 -05:00
romanman e436879e3f update EtherJ dependency 2014-10-31 10:34:13 -05:00
romanman 9d9c84f862 introducing structural tracing for VM 2014-10-31 10:18:40 -05:00
romanman e0aa458aa8 udpate EtherJ lib for the studio 2014-10-29 15:20:31 -05:00
romanman e487f3475f update geet-peers new spec requirement 2014-10-29 15:17:14 -05:00
romanman 5f413d0ffb minor fixes 2014-10-28 23:25:45 -05:00
romanman ee8065ed36 Merge remote-tracking branch 'origin/master' 2014-10-25 09:57:48 -05:00
romanman 5364edf9a3 active peer bug fix 2014-10-25 09:57:41 -05:00
nicksavers 5e8809487a Turn PeerDiscovery off by default 2014-10-25 09:10:13 +02:00
romanman 328a3cc0ad peer discovery fixes 2014-10-25 00:35:47 -05:00
romanman 779bebc2b3 peer discovery fixes 2014-10-25 00:07:54 -05:00
romanman e9bbc95ee5 peer discovery fixes 2014-10-24 23:17:04 -05:00
romanman b70315532e merge tiny changes 2014-10-24 21:15:49 -05:00
nicksavers aa204e3475 Pass peerdiscovery boolean to EthHandler 2014-10-24 17:51:42 +02:00
nicksavers 3613002557 Merge branch 'vmfixes' 2014-10-24 17:48:53 +02:00
romanman b25e62a69b tiny PeerInfo adjust 2014-10-23 21:42:28 -05:00
romanman 7768107386 peer discovery enhancement for more info about connected peer 2014-10-23 21:00:39 -05:00
nicksavers 7aa2370057 Restructure Unit tests and VM fixes 2014-10-24 00:49:52 +02:00
romanman 2a2f34f7c3 make peer discovery work again 2014-10-23 15:23:26 -05:00
romanman 44fe6763d7 fix for tiny compile compatibility 2014-10-22 08:12:13 -05:00
romanman 34999f335b Network stack redesign and several fixes
+ Network redesign for better user expirience, all the handlers are known to PeerClient now, and MessageQueue is also managed in the PeerClient
+ Listener callback for sync done
+ tx.isCreateContract() bug fix
+ repository.getBlock() bug fix
2014-10-22 07:41:08 -05:00
nicksavers 49e23d2e24 Fix system.properties for poc-7 2014-10-18 17:29:15 +02:00
nicksavers 83ea504448 Cleanup and put back javadoc after move 2014-10-18 09:51:51 +02:00
romanman 12d014272e POC-7: networking
+ Status msg fix
+ NewBlock msg support - after the sync process (GET_BLOCK_HASHES & GET_BLOCKS) the new block received by NEW_BLOCK announcement
2014-10-17 23:12:11 -05:00
romanman e8cb84e83b Implementation for POC-7 network structure
+ adaptive message id support
+ dynamic add of [shh] -- todo: yet to be implemented
2014-10-15 22:00:10 -05:00
nicksavers 4d4d188def Fix HelloMessage unit test 2014-10-15 11:09:40 +02:00
nicksavers 91913ff912 Fix missing version update 2014-10-13 16:28:48 +02:00