Skip to content

Commit

Permalink
indexer + optimizer syscoin core
Browse files Browse the repository at this point in the history
mongodb indexer and optimize syscoin core with cnametxidtuple lookups with big data in mind.
  • Loading branch information
sidhujag committed Aug 29, 2017
1 parent 8a10450 commit 31d1c69
Show file tree
Hide file tree
Showing 3,484 changed files with 434,289 additions and 399,844 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
22 changes: 20 additions & 2 deletions .gitignore
@@ -1,3 +1,8 @@
*.sublime-project
*.sublime-workspace
todo.txt
reset-files.bash

*.tar.gz

*.exe
Expand All @@ -7,6 +12,7 @@ src/syscoin-cli
src/syscoin-tx
src/test/test_syscoin
src/qt/test/test_syscoin-qt
src/bench/bench_syscoin

# autoreconf
Makefile.in
Expand Down Expand Up @@ -42,6 +48,7 @@ src/qt/moc_*.cpp
src/qt/forms/ui_*.h

src/qt/test/moc*.cpp
libconftest.dylib*

.deps
.dirstamp
Expand All @@ -54,6 +61,7 @@ src/qt/test/moc*.cpp
*.pyc
*.o
*.o-*
*.patch
.syscoin
*.a
*.pb.cc
Expand Down Expand Up @@ -106,11 +114,21 @@ qa/pull-tester/cache/*
qa/pull-tester/test.*/*
qa/tmp
cache/
share/BitcoindComparisonTool.jar
share/SyscoindComparisonTool.jar

!src/leveldb*/Makefile

.cproject
.project
.autotools
/doc/doxygen/

libsyscoinconsensus.pc
contrib/devtools/split-debug.sh
src/qt/syscoin-qt.bash
qa/pull-tester/tests-config.sh

#development symlinks
syscoin-cli
syscoind
syscoin-qt
make
65 changes: 40 additions & 25 deletions .travis.yml
@@ -1,73 +1,88 @@
# errata:
# - A travis bug causes caches to trample eachother when using the same
# compiler key (which we don't use anyway). This is worked around for now by
# replacing the "compilers" with a build name prefixed by the no-op ":"
# command. See: https://github.com/travis-ci/travis-ci/issues/4393
# - sudo/dist/group are set so as to get Blue Box VMs, necessary for [loopback]
# IPv6 support

sudo: required
dist: trusty

#workaround for https://github.com/travis-ci/travis-ci/issues/5227
addons:
hostname: syscoin-tester
group: deprecated-2017Q3

os: linux
language: generic

cache:
apt: true
ccache: true
directories:
- depends/built
- depends/sdk-sources
- $HOME/.ccache
- depends/built
- depends/sdk-sources
- $HOME/.ccache

env:
global:
- MAKEJOBS=-j3
- MAKEJOBS=-j5
- RUN_TESTS=false
- CHECK_DOC=0
- BOOST_TEST_RANDOM=1$TRAVIS_BUILD_ID
- CCACHE_SIZE=100M
- CCACHE_SIZE=400M
- CCACHE_TEMPDIR=/tmp/.ccache-temp
- CCACHE_COMPRESS=1
- BASE_OUTDIR=$TRAVIS_BUILD_DIR/out
- SDK_URL=https://bitcoincore.org/depends-sources/sdks
- PYTHON_DEBUG=1
- WINEDEBUG=fixme-all

matrix:
# ARM
- HOST=arm-linux-gnueabihf PACKAGES="g++-arm-linux-gnueabihf" DEP_OPTS="NO_QT=1" CHECK_DOC=1 GOAL="install" SYSCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
- HOST=arm-linux-gnueabihf PPA="ppa:bitcoin/bitcoin" PACKAGES="g++-arm-linux-gnueabihf" DEP_OPTS="NO_QT=1" CHECK_DOC=1 GOAL="install" SYSCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
# Win32
- HOST=i686-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-i686 wine1.6 bc openjdk-7-jre-headless" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-reduce-exports"
- HOST=i686-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PPA="ppa:bitcoin/bitcoin" PACKAGES="python3 nsis g++-mingw-w64-i686 wine1.7 bc" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-gui --enable-reduce-exports" MAKEJOBS="-j4" WINE=true
# 32-bit + dash
- HOST=i686-pc-linux-gnu PACKAGES="g++-multilib bc python3-zmq openjdk-7-jre-headless" DEP_OPTS="NO_QT=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++" USE_SHELL="/bin/dash"
- HOST=i686-pc-linux-gnu PPA="ppa:bitcoin/bitcoin" PACKAGES="g++-multilib bc python3-zmq" DEP_OPTS="NO_QT=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++" USE_SHELL="/bin/dash" PYZMQ=true
# Win64
- HOST=x86_64-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine1.6 bc openjdk-7-jre-headless" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-reduce-exports"
# syscoind
- HOST=x86_64-unknown-linux-gnu PACKAGES="bc python3-zmq openjdk-7-jre-headless" DEP_OPTS="NO_QT=1 NO_UPNP=1 DEBUG=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports CPPFLAGS=-DDEBUG_LOCKORDER"
- HOST=x86_64-w64-mingw32 DPKG_ADD_ARCH="i386" DEP_OPTS="NO_QT=1" PPA="ppa:bitcoin/bitcoin" PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine1.7 bc" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-gui --enable-reduce-exports" MAKEJOBS="-j4" WINE=true
# dashd
- HOST=x86_64-unknown-linux-gnu PPA="ppa:bitcoin/bitcoin" PACKAGES="bc python3-zmq" DEP_OPTS="NO_QT=1 NO_UPNP=1 DEBUG=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-zmq --enable-glibc-back-compat --enable-reduce-exports" CPPFLAGS="-DDEBUG_LOCKORDER -DENABLE_SYS_DEBUG" PYZMQ=true
# No wallet
- HOST=x86_64-unknown-linux-gnu PACKAGES=" openjdk-7-jre-headless python3" DEP_OPTS="NO_WALLET=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
# - HOST=x86_64-unknown-linux-gnu PPA="ppa:bitcoin/bitcoin" PACKAGES="python3" DEP_OPTS="NO_WALLET=1" RUN_TESTS=true GOAL="install" SYSCOIN_CONFIG="--enable-glibc-back-compat --enable-reduce-exports"
# Cross-Mac
- HOST=x86_64-apple-darwin11 PACKAGES="cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev" SYSCOIN_CONFIG="--enable-reduce-exports" OSX_SDK=10.11 GOAL="deploy"
- HOST=x86_64-apple-darwin11 PPA="ppa:bitcoin/bitcoin" PACKAGES="cmake imagemagick libcap-dev librsvg2-bin libz-dev libbz2-dev libtiff-tools python-dev" SYSCOIN_CONFIG="--enable-gui --enable-reduce-exports" OSX_SDK=10.9 GOAL="deploy"

before_install:
- git clone https://github.com/dashpay/dash_hash
- travis_retry sudo apt-get install python-dev
- travis_retry sudo add-apt-repository ppa:ubuntu-wine/ppa -y
- export PATH=$(echo $PATH | tr ':' "\n" | sed '/\/opt\/python/d' | tr "\n" ":" | sed "s|::|:|g")
install:
- if [ "$PYZMQ" = "true" ]; then pip install pyzmq --user ; fi
- if [ -n "$PPA" ]; then travis_retry sudo add-apt-repository "$PPA" -y; fi
- if [ -n "$DPKG_ADD_ARCH" ]; then sudo dpkg --add-architecture "$DPKG_ADD_ARCH" ; fi
- if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get update; fi
- if [ -n "$PACKAGES" ]; then travis_retry sudo apt-get install --no-install-recommends --no-upgrade -qq $PACKAGES; fi
- cd dash_hash && python setup.py install --user && cd ..
before_script:
- unset CC; unset CXX
- if [ "$CHECK_DOC" = 1 ]; then contrib/devtools/check-doc.py; fi
- unset DISPLAY
- mkdir -p depends/SDKs depends/sdk-sources
- if [ -n "$OSX_SDK" -a ! -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then curl --location --fail $SDK_URL/MacOSX${OSX_SDK}.sdk.tar.gz -o depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
- if [ -n "$OSX_SDK" -a -f depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz ]; then tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${OSX_SDK}.sdk.tar.gz; fi
- make $MAKEJOBS -C depends HOST=$HOST $DEP_OPTS
script:
- export TRAVIS_COMMIT_LOG=`git log --format=fuller -1`
- if [ -n "$USE_SHELL" ]; then export CONFIG_SHELL="$USE_SHELL"; fi
- OUTDIR=$BASE_OUTDIR/$TRAVIS_PULL_REQUEST/$TRAVIS_JOB_NUMBER-$HOST
- SYSCOIN_CONFIG_ALL="--disable-dependency-tracking --prefix=$TRAVIS_BUILD_DIR/depends/$HOST --bindir=$OUTDIR/bin --libdir=$OUTDIR/lib"
- depends/$HOST/native/bin/ccache --max-size=$CCACHE_SIZE
- test -n "$USE_SHELL" && eval '"$USE_SHELL" -c "./autogen.sh"' || ./autogen.sh
- mkdir build && cd build
- ../configure $SYSCOIN_CONFIG_ALL $SYSCOIN_CONFIG || ( cat config.log && false)
- ./configure --cache-file=config.cache $SYSCOIN_CONFIG_ALL $SYSCOIN_CONFIG || ( cat config.log && false)
- make distdir PACKAGE=dash VERSION=$HOST
- cd syscoin-$HOST
- ./configure --cache-file=../config.cache $SYSCOIN_CONFIG_ALL $SYSCOIN_CONFIG || ( cat config.log && false)
- make $MAKEJOBS $GOAL || ( echo "Build failure. Verbose build follows." && make $GOAL V=1 ; false )
- export LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib
- if [ "$RUN_TESTS" = "true" ]; then make $MAKEJOBS check VERBOSE=1; fi
- if [ "$RUN_TESTS" = "true" -a "$WINE" != "true" ]; then make $MAKEJOBS check VERBOSE=1; fi
- if [ "$RUN_TESTS" = "true" -a "$WINE" = "true" ]; then wine src/test/test_syscoin.exe; fi
- if [ "$RUN_TESTS" = "true" ]; then qa/pull-tester/rpc-tests.py --coverage; fi
after_script:
- echo $TRAVIS_COMMIT_RANGE
- echo $TRAVIS_COMMIT_LOG
- if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then (echo "Upload goes here. Something like: scp -r $BASE_OUTDIR server" || echo "upload failed"); fi
2 changes: 1 addition & 1 deletion .tx/config
@@ -1,7 +1,7 @@
[main]
host = https://www.transifex.com

[syscoin.qt-translation-013x]
[syscoin.qt-translation-012x]
file_filter = src/qt/locale/syscoin_<lang>.ts
source_file = src/qt/locale/syscoin_en.ts
source_lang = en
32 changes: 9 additions & 23 deletions CONTRIBUTING.md
Expand Up @@ -17,13 +17,13 @@ To contribute a patch, the workflow is as follows:
- Create topic branch
- Commit patches

The project coding conventions in the [developer notes](doc/developer-notes.md) must be adhered to.
The project coding conventions in [doc/developer-notes.md](doc/developer-notes.md) must be adhered to.

In general [commits should be atomic](https://en.wikipedia.org/wiki/Atomic_commit#Atomic_commit_convention) and diffs should be easy to read. For this reason do not mix any formatting fixes or code moves with actual code changes.

Commit messages should be verbose by default consisting of a short subject line (50 chars max), a blank line and detailed explanatory text as separate paragraph(s); unless the title alone is self-explanatory (like "Corrected typo in main.cpp") then a single title line is sufficient. Commit messages should be helpful to people reading your code in the future, so explain the reasoning for your decisions. Further explanation [here](http://chris.beams.io/posts/git-commit/).

If a particular commit references another issue, please add the reference, for example `refs #1234`, or `fixes #4321`. Using the `fixes` or `closes` keywords will cause the corresponding issue to be closed when the pull request is merged.
If a particular commit references another issue, please add the reference, for example "refs #1234", or "fixes #4321". Using "fixes or closes" keywords will cause the corresponding issue to be closed when the pull request is merged.

Please refer to the [Git manual](https://git-scm.com/doc) for more information about Git.

Expand All @@ -35,27 +35,13 @@ The title of the pull request should be prefixed by the component or area that t
Consensus: Add new opcode for BIP-XXXX OP_CHECKAWESOMESIG
Net: Automatically create hidden service, listen on Tor
Qt: Add feed bump button
Trivial: Fix typo in main.cpp
Trivial: fix typo

If a pull request is specifically not to be considered for merging (yet) please prefix the title with [WIP] or use [Tasks Lists](https://help.github.com/articles/basic-writing-and-formatting-syntax/#task-lists) in the body of the pull request to indicate tasks are pending.
If a pull request is specifically not to be considered for merging (yet) please prefix the title with [WIP] or use [Tasks Lists](https://github.com/blog/1375-task-lists-in-gfm-issues-pulls-comments) in the body of the pull request to indicate tasks are pending.

The body of the pull request should contain enough description about what the patch does together with any justification/reasoning. You should include references to any discussions (for example other tickets or mailing list discussions).

At this stage one should expect comments and review from other contributors. You can add more commits to your pull request by committing them locally and pushing to your fork until you have satisfied all feedback.

Squashing Commits
---------------------------
If your pull request is accepted for merging, you may be asked by a maintainer to squash and or [rebase](https://git-scm.com/docs/git-rebase) your commits before it will be merged. The basic squashing workflow is shown below.

git checkout your_branch_name
git rebase -i HEAD~n
# n is normally the number of commits in the pull
# set commits from 'pick' to 'squash', save and quit
# on the next screen, edit/refine commit messages
# save and quit
git push -f # (force push to GitHub)

The length of time required for peer review is unpredictable and will vary from pull request to pull request.
At this stage one should expect comments and review from other contributors. You can add more commits to your pull request by committing them locally and pushing to your fork until you have satisfied all feedback. If your pull request is accepted for merging, you may be asked by a maintainer to squash and or rebase your commits before it will be merged. The length of time required for peer review is unpredictable and will vary from patch to patch.


Pull Request Philosophy
Expand All @@ -64,18 +50,18 @@ Pull Request Philosophy
Patchsets should always be focused. For example, a pull request could add a feature, fix a bug, or refactor code; but not a mixture. Please also avoid super pull requests which attempt to do too much, are overly large, or overly complex as this makes review difficult.


###Features
### Features

When adding a new feature, thought must be given to the long term technical debt and maintenance that feature may require after inclusion. Before proposing a new feature that will require maintenance, please consider if you are willing to maintain it (including bug fixing). If features get orphaned with no maintainer in the future, they may be removed by the Repository Maintainer.


###Refactoring
### Refactoring

Refactoring is a necessary part of any software project's evolution. The following guidelines cover refactoring pull requests for the project.

There are three categories of refactoring, code only moves, code style fixes, code refactoring. In general refactoring pull requests should not mix these three kinds of activity in order to make refactoring pull requests easy to review and uncontroversial. In all cases, refactoring PRs must not change the behaviour of code within the pull request (bugs must be preserved as is).

Project maintainers aim for a quick turnaround on refactoring pull requests, so where possible keep them short, uncomplex and easy to verify.
Project maintainers aim for a quick turnaround on refactoring pull requests, so where possible keep them short, uncomplex and easy to verify.


"Decision Making" Process
Expand All @@ -99,7 +85,7 @@ In general, all pull requests must:
Patches that change Syscoin consensus rules are considerably more involved than normal because they affect the entire ecosystem and so must be preceded by extensive mailing list discussions and have a numbered BIP. While each case will be different, one should be prepared to expend more time and effort than for other kinds of patches because of increased peer review and consensus building requirements.


###Peer Review
### Peer Review

Anyone may participate in peer review which is expressed by comments in the pull request. Typically reviewers will review the code for obvious errors, as well as test out the patch set and opine on the technical merits of the patch. Project maintainers take into account the peer review when determining if there is consensus to merge a pull request (remember that discussions may have been spread out over github, mailing list and IRC discussions). The following language is used within pull-request comments:

Expand Down
1 change: 1 addition & 0 deletions COPYING
@@ -1,6 +1,7 @@
The MIT License (MIT)

Copyright (c) 2009-2016 The Syscoin Core developers
Copyright (c) 2014-2017 The Syscoin Core developers

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
3 changes: 0 additions & 3 deletions End_User_Agreement.txt

This file was deleted.

31 changes: 28 additions & 3 deletions INSTALL
@@ -1,5 +1,30 @@
Building Syscoin
Building Syscoin Core

After you install the usual build tools and C++ development tools,
Syscoin Core also needs some build dependencies which are not always provided
by default by the OS package manager
(in particular BerkeleyDB 4.8 for building with wallet support).

Before trying to build, be sure to read one of these files,
depending on your environment:

doc/build-unix.md
doc/build-openbsd.md
doc/build-osx.md
doc/build-windows.md

After installing the needed dependencies,
use the autogen script to prepare the build environment.

./autogen.sh
./configure
make

Precompiled binaries are available at github, see
https://github.com/syscoin/syscoin2-binaries

Always verify the signatures and checksums.

See doc/build-*.md for instructions on building syscoind,
the intended-for-services, no-graphical-interface, reference
implementation of Syscoin.
the intended-for-services, no-graphical-interface,
reference implementation of Syscoin.
5 changes: 0 additions & 5 deletions INSTALL.md

This file was deleted.

0 comments on commit 31d1c69

Please sign in to comment.