├── .dockerignore ├── .gitattributes ├── .gitignore ├── .travis.yml ├── 3rdparty └── jvm │ └── BUILD ├── BUILD.tools ├── Dockerfile ├── LICENSE ├── README.md ├── build-support ├── ivy │ ├── BUILD.netrc │ ├── pgp.ivysettings.xml │ ├── publish.ivysettings.xml │ └── pushdb │ │ └── com.madavan │ │ ├── caustic-common_2.12 │ │ └── publish.properties │ │ ├── caustic-compiler_2.12 │ │ └── publish.properties │ │ ├── caustic-grammar │ │ └── publish.properties │ │ ├── caustic-library_2.12 │ │ └── publish.properties │ │ ├── caustic-runtime_2.12 │ │ └── publish.properties │ │ ├── caustic-service_2.12 │ │ └── publish.properties │ │ └── caustic-thrift │ │ └── publish.properties ├── pants │ └── publish │ │ ├── __init__.py │ │ └── register.py └── travis │ └── pants.ini ├── caustic-assets ├── README.md ├── images │ ├── caustic-banner.png │ ├── caustic-logo.png │ ├── runtime-latency.png │ ├── runtime-throughput.png │ ├── ycsb-runtime.png │ └── ycsb-throughput.png ├── results │ ├── profile │ │ ├── jprofiler_images │ │ │ ├── ff00c400_bff000000.png │ │ │ ├── hotspot_16.png │ │ │ ├── pixel_ff800000.png │ │ │ ├── selector_group_16.png │ │ │ └── tree │ │ │ │ ├── menu_bar_18.gif │ │ │ │ ├── menu_corner_18.gif │ │ │ │ ├── menu_corner_minus_18.gif │ │ │ │ ├── menu_corner_plus_18.gif │ │ │ │ ├── menu_tee_18.gif │ │ │ │ ├── menu_tee_minus_18.gif │ │ │ │ ├── menu_tee_plus_18.gif │ │ │ │ └── pixel_transparent_1.gif │ │ └── mysql-execute.html │ └── runtime │ │ ├── css │ │ ├── bootstrap-slider.css │ │ ├── bootstrap.min.css │ │ ├── icons.gif │ │ ├── index.css │ │ ├── jquery-ui-1.10.3.custom.css │ │ ├── ui.dynatree.css │ │ └── vline.gif │ │ ├── img │ │ ├── arrow.png │ │ └── glyphicons-halflings.png │ │ ├── index.html │ │ ├── js │ │ ├── ScalaMeter │ │ │ ├── chart.js │ │ │ ├── data.js │ │ │ ├── dimensions.js │ │ │ ├── filter.js │ │ │ ├── helper.js │ │ │ ├── main.js │ │ │ └── permalink.js │ │ ├── bootstrap.min.js │ │ ├── crossfilter.min.js │ │ ├── d3.v3.min.js │ │ ├── jquery-1.9.1.js │ │ ├── jquery-compat.js │ │ ├── jquery-ui-1.10.3.custom.min.js │ │ └── jquery.dynatree.js │ │ └── report │ │ ├── css │ │ ├── bootstrap-slider.css │ │ ├── bootstrap.min.css │ │ ├── icons.gif │ │ ├── index.css │ │ ├── jquery-ui-1.10.3.custom.css │ │ ├── ui.dynatree.css │ │ └── vline.gif │ │ ├── img │ │ ├── arrow.png │ │ └── glyphicons-halflings.png │ │ ├── index.html │ │ └── js │ │ ├── ScalaMeter │ │ ├── chart.js │ │ ├── data.js │ │ ├── dimensions.js │ │ ├── filter.js │ │ ├── helper.js │ │ ├── main.js │ │ └── permalink.js │ │ ├── bootstrap.min.js │ │ ├── crossfilter.min.js │ │ ├── d3.v3.min.js │ │ ├── jquery-1.9.1.js │ │ ├── jquery-compat.js │ │ ├── jquery-ui-1.10.3.custom.min.js │ │ └── jquery.dynatree.js └── review │ └── main.tex ├── caustic-benchmark ├── README.md └── src │ └── main │ └── scala │ ├── BUILD │ └── caustic │ └── benchmark │ ├── Suite.scala │ └── runtime │ ├── LatencyBenchmark.scala │ ├── ProfileBenchmark.scala │ ├── ThroughputBenchmark.scala │ └── VolumeBenchmark.scala ├── caustic-compiler ├── README.md └── src │ ├── main │ ├── antlr │ │ ├── BUILD │ │ └── Caustic.g4 │ ├── python │ │ ├── BUILD │ │ └── caustic │ │ │ ├── __init__.py │ │ │ └── pants │ │ │ ├── __init__.py │ │ │ ├── register.py │ │ │ ├── targets │ │ │ ├── __init__.py │ │ │ └── caustic_library.py │ │ │ └── tasks │ │ │ ├── __init__.py │ │ │ └── caustic_gen.py │ ├── scala │ │ ├── BUILD │ │ └── caustic │ │ │ └── compiler │ │ │ ├── Causticc.scala │ │ │ ├── error │ │ │ ├── Error.scala │ │ │ ├── Handler.scala │ │ │ └── Trace.scala │ │ │ ├── gen │ │ │ ├── Gen.scala │ │ │ ├── GenBlock.scala │ │ │ ├── GenComment.scala │ │ │ ├── GenExternal.scala │ │ │ ├── GenInternal.scala │ │ │ ├── GenParameters.scala │ │ │ └── GenType.scala │ │ │ ├── reflect │ │ │ ├── Result.scala │ │ │ ├── Universe.scala │ │ │ ├── binding.scala │ │ │ └── package.scala │ │ │ └── util │ │ │ ├── Indenter.scala │ │ │ └── package.scala │ └── tmbundle │ │ ├── Preferences │ │ └── balance.tmPreferences │ │ ├── Snippets │ │ ├── if.tmSnippet │ │ └── while.tmSnippet │ │ ├── Syntaxes │ │ └── Caustic.tmLanguage │ │ └── info.plist │ └── test │ └── scala │ ├── BUILD │ └── caustic │ └── compiler │ └── CausticcTest.scala ├── caustic-example └── src │ └── main │ └── caustic │ ├── BUILD │ └── caustic │ └── example │ ├── counter.acid │ ├── fs.acid │ ├── lock.acid │ └── queue.acid ├── caustic-library ├── README.md └── src │ ├── main │ └── scala │ │ ├── BUILD │ │ └── caustic │ │ └── library │ │ ├── Context.scala │ │ ├── control │ │ └── package.scala │ │ ├── math │ │ └── package.scala │ │ └── typing │ │ ├── Constant.scala │ │ ├── Conversion.scala │ │ ├── Internal.scala │ │ ├── Pointer.scala │ │ ├── Value.scala │ │ ├── Variable.scala │ │ ├── collection │ │ ├── Collection.scala │ │ ├── List.scala │ │ ├── Map.scala │ │ └── Set.scala │ │ ├── package.scala │ │ ├── primitive.scala │ │ └── record │ │ ├── Field.scala │ │ ├── Reference.scala │ │ └── ops │ │ ├── delete.scala │ │ ├── equal.scala │ │ ├── json.scala │ │ └── move.scala │ └── test │ └── scala │ ├── BUILD │ └── caustic │ └── library │ ├── math │ └── PackageTest.scala │ └── typing │ └── record │ └── ReferenceTest.scala ├── caustic-runtime ├── README.md └── src │ ├── main │ └── scala │ │ ├── BUILD │ │ └── caustic │ │ └── runtime │ │ ├── Builder.scala │ │ ├── Runtime.scala │ │ ├── Volume.scala │ │ ├── operator.scala │ │ ├── package.scala │ │ └── program.scala │ └── test │ └── scala │ ├── BUILD │ └── caustic │ └── runtime │ ├── BuilderTest.scala │ └── RuntimeTest.scala ├── pants ├── pants.ini └── release.sh /.dockerignore: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | # .dockerignore # 3 | #################################################################################################### 4 | # macOS 5 | .DS_Store 6 | 7 | # IntelliJ 8 | .idea/ 9 | *.iml 10 | 11 | # Git 12 | .git 13 | .gitignore 14 | 15 | # Pants 16 | .cache 17 | dist 18 | .pants.d 19 | .pants.workdir.file_lock 20 | .pids 21 | 22 | # Generated 23 | target/ 24 | 25 | # Miscellaneous 26 | caustic-assets 27 | LICENSE 28 | README.md 29 | release.sh 30 | .travis.yml 31 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | caustic-assets/* linguist-vendored 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | # .gitignore # 3 | #################################################################################################### 4 | # macOS 5 | .DS_Store 6 | 7 | # Java 8 | *.class 9 | *.jar 10 | 11 | # Python 12 | *.pyc 13 | 14 | # Vim 15 | .*.swo 16 | .*.swp 17 | 18 | # IntelliJ 19 | .idea/ 20 | *.iml 21 | 22 | # Pants 23 | .cache 24 | dist 25 | .pants.d 26 | .pants.workdir.file_lock 27 | .pids 28 | 29 | # Generated 30 | target/ 31 | 32 | # LaTeX 33 | *.aux 34 | *.bbl 35 | *.bcf 36 | *.blg 37 | *.dvi 38 | *.log 39 | *.out 40 | *.run.xml 41 | *.toc -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | # Setup Pants # 3 | # https://github.com/build/pants/blob/master/.travis.yml # 4 | #################################################################################################### 5 | env: 6 | global: 7 | - JAVA_HOME="$HOME/opt/jdk1.8.0_131" 8 | - PANTS_CONFIG_OVERRIDE="['pants.ini', 'build-support/travis/pants.ini']" 9 | 10 | before_cache: 11 | - sudo chown -R travis:travis "${HOME}" "${TRAVIS_BUILD_DIR}" 12 | - find build-support -name "*.py[co]" -delete 13 | - find ${HOME}/.ivy2/pants -type f -name "ivydata-*.properties" -delete 14 | - rm -f ${HOME}/.ivy2/pants/*.{css,properties,xml,xsl} 15 | - rm -rf ${HOME}/.ivy2/pants/com.example 16 | - rm -rf ${HOME}/.cache/pants/stats 17 | 18 | cache: 19 | directories: 20 | - ${HOME}/.cache/pants 21 | - ${HOME}/.ivy2/pants 22 | 23 | #################################################################################################### 24 | # Setup JDK # 25 | # https://github.com/foursquare/fsqio/blob/master/.travis.yml # 26 | #################################################################################################### 27 | before_script: | 28 | if ! ${HOME}/opt/jdk1.8.0_131/bin/java -version; then 29 | mkdir -p ~/opt 30 | wget --no-cookies --no-check-certificate --header \ 31 | "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \ 32 | "http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.tar.gz" 33 | tar xzf jdk-8u131-linux-x64.tar.gz -C ~/opt 34 | fi 35 | 36 | #################################################################################################### 37 | # Setup Databases # 38 | # https://docs.travis-ci.com/user/database-setup # 39 | #################################################################################################### 40 | services: 41 | - mysql 42 | - postgresql 43 | 44 | addons: 45 | postgresql: "9.5" 46 | 47 | before_install: 48 | - mysql -e 'CREATE DATABASE IF NOT EXISTS test;' 49 | - psql -c 'CREATE DATABASE test;' -U postgres 50 | 51 | #################################################################################################### 52 | # Compile and Test # 53 | # https://github.com/foursquare/fsqio/blob/master/.travis.yml # 54 | #################################################################################################### 55 | language: python 56 | python: 57 | - '2.7' 58 | 59 | script: | 60 | ./pants compile :: 61 | ./pants test :: 62 | 63 | #################################################################################################### 64 | # Push to Docker # 65 | # https://docs.travis-ci.com/user/docker/ # 66 | #################################################################################################### 67 | services: 68 | - docker 69 | 70 | after_success: | 71 | if [ "$TRAVIS_BRANCH" == "master" ] ; then 72 | docker build -t ashwin153/caustic . 73 | docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD" 74 | docker push ashwin153/caustic 75 | fi 76 | -------------------------------------------------------------------------------- /3rdparty/jvm/BUILD: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | # Compile # 3 | #################################################################################################### 4 | # Beaker Client 5 | jar_library(name='beaker-client', jars=[ 6 | jar(org='com.madavan', name='beaker-client_2.12', rev='2.0.1'), 7 | ]) 8 | 9 | # Shapeless 10 | jar_library(name='shapeless', jars=[ 11 | jar(org='com.chuusai', name='shapeless_2.12', rev='2.3.2'), 12 | ]) 13 | 14 | # SLF4J 15 | jar_library(name='slf4j-simple', jars=[ 16 | jar(org='org.slf4j', name='slf4j-simple', rev='1.7.25'), 17 | ]) 18 | 19 | # Spray JSON 20 | jar_library(name='spray-json', jars=[ 21 | jar(org='io.spray', name='spray-json_2.12', rev='1.3.3'), 22 | ]) 23 | 24 | #################################################################################################### 25 | # Build # 26 | #################################################################################################### 27 | # Ammonite 28 | jar_library(name='ammonite', jars=[ 29 | jar(org='com.lihaoyi', name='ammonite_2.12.3', rev='1.0.5'), 30 | ]) 31 | 32 | # ANTLR 33 | jar_library(name='antlr', jars=[ 34 | jar(org='org.antlr', name='antlr4', rev='4.7'), 35 | jar(org='org.antlr', name='antlr4-runtime', rev='4.7'), 36 | ]) 37 | 38 | # Causticc 39 | jar_library(name='caustic-compiler', jars=[ 40 | jar(org='com.madavan', name='caustic-compiler_2.12', rev='2.0.3'), 41 | ]) 42 | 43 | # Scalac 44 | jar_library(name='scala-compiler', dependencies=[':scala-library', ':scala-reflect'], jars=[ 45 | jar(org='org.scala-lang', name='scala-compiler', rev='2.12.3'), 46 | ]) 47 | 48 | # Scala Library 49 | jar_library(name='scala-library', jars=[ 50 | jar(org='org.scala-lang', name='scala-library', rev='2.12.3'), 51 | ]) 52 | 53 | # Scala Reflection 54 | jar_library(name='scala-reflect', jars=[ 55 | jar(org='org.scala-lang', name='scala-reflect', rev='2.12.3', intransitive=True), 56 | ]) 57 | 58 | #################################################################################################### 59 | # Test # 60 | #################################################################################################### 61 | # JUnit 62 | jar_library(name='junit', jars=[ 63 | jar(org='junit', name='junit', rev='4.12'), 64 | jar(org='org.pantsbuild', name='junit-runner-annotations', rev='0.0.17'), 65 | ]) 66 | 67 | # Mockito 68 | jar_library(name='mockito', jars=[ 69 | jar(org='org.mockito', name='mockito-core', rev='2.7.11'), 70 | ]) 71 | 72 | # Scalameter 73 | jar_library(name='scalameter', jars=[ 74 | jar(org='com.storm-enroute', name='scalameter_2.12', rev='0.8.2') 75 | ]) 76 | 77 | # Scalatest 78 | jar_library(name='scalatest', dependencies=[':scala-library', ':scala-reflect'], jars=[ 79 | jar(org='org.scalatest', name='scalatest_2.12', rev='3.0.0', excludes=[exclude('org.scala-lang')]), 80 | ]) 81 | -------------------------------------------------------------------------------- /BUILD.tools: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | # ANTLR # 3 | # https://git.io/vd1nU # 4 | #################################################################################################### 5 | target(name='antlr-4', dependencies=['3rdparty/jvm:antlr']) 6 | 7 | #################################################################################################### 8 | # Caustic # 9 | # https://github.com/ashwin153/caustic # 10 | #################################################################################################### 11 | target(name='causticc', dependencies=['3rdparty/jvm:caustic-compiler']) 12 | 13 | #################################################################################################### 14 | # Scala # 15 | # https://www.pantsbuild.org/scala.html # 16 | #################################################################################################### 17 | target(name='scalac', dependencies=['3rdparty/jvm:scala-compiler']) 18 | target(name='scala-library', dependencies=['3rdparty/jvm:scala-library']) 19 | target(name='scala-reflect', dependencies=['3rdparty/jvm:scala-reflect']) 20 | target(name='scala-repl', dependencies=['3rdparty/jvm:ammonite']) 21 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:latest 2 | MAINTAINER Ashwin Madavan (ashwin.madavan@gmail.com) 3 | 4 | #################################################################################################### 5 | # Install Pants Dependencies # 6 | # https://github.com/pantsbuild/pants/blob/master/README.md#requirements # 7 | #################################################################################################### 8 | RUN apt-get update && apt-get -y install curl build-essential python python-dev openjdk-8-jdk 9 | 10 | #################################################################################################### 11 | # Compile Caustic # 12 | # Automatically bootstraps Pants and downloads dependencies. # 13 | #################################################################################################### 14 | COPY . /caustic/ 15 | RUN cd /caustic && ./pants compile :: 16 | WORKDIR /caustic 17 | -------------------------------------------------------------------------------- /build-support/ivy/BUILD.netrc: -------------------------------------------------------------------------------- 1 | # Enable ~/.netrc for credentials management of jvm publishing. 2 | 3 | # These credentials are used by our 'public' publish repo defined in [publish]repos in `pants.ini` 4 | # and the username and password here are templated in to a credentials configuration for 5 | # oss.sonatype.org in `build-support/ivy/publish.ivysettings.xml`. This setup is complex, but 6 | # documented well here: http://pantsbuild.org/setup_repo.html#enabling-pants-publish 7 | netrc_credentials(name='netrc') 8 | -------------------------------------------------------------------------------- /build-support/ivy/pgp.ivysettings.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /build-support/ivy/publish.ivysettings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 12 | 13 | 14 | 15 | 16 | 20 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 37 | 38 | 39 | 40 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-common_2.12/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-common_2.12=1 2 | revision.minor.com.madavan%caustic-common_2.12=3 3 | revision.patch.com.madavan%caustic-common_2.12=1 4 | revision.snapshot.com.madavan%caustic-common_2.12=false 5 | revision.named_is_latest.com.madavan%caustic-common_2.12=false 6 | revision.sha.com.madavan%caustic-common_2.12=6e722a3024cd4398f5f19074a174d5fe0ee4a1d8 7 | revision.fingerprint.com.madavan%caustic-common_2.12=a240d2876d4df0a69470368e10ec57c4c572c73e 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-compiler_2.12/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-compiler_2.12=2 2 | revision.minor.com.madavan%caustic-compiler_2.12=0 3 | revision.patch.com.madavan%caustic-compiler_2.12=3 4 | revision.snapshot.com.madavan%caustic-compiler_2.12=false 5 | revision.named_is_latest.com.madavan%caustic-compiler_2.12=false 6 | revision.sha.com.madavan%caustic-compiler_2.12=9f3074f4c474364a950606c12d8f6cf50a76dc05 7 | revision.fingerprint.com.madavan%caustic-compiler_2.12=2371aaa48baeb74071a8133a6efb6e8b21b45d45 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-grammar/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-grammar=2 2 | revision.minor.com.madavan%caustic-grammar=0 3 | revision.patch.com.madavan%caustic-grammar=3 4 | revision.snapshot.com.madavan%caustic-grammar=false 5 | revision.named_is_latest.com.madavan%caustic-grammar=false 6 | revision.sha.com.madavan%caustic-grammar=9f3074f4c474364a950606c12d8f6cf50a76dc05 7 | revision.fingerprint.com.madavan%caustic-grammar=1f66946226d07872e25a10b15dec4928082a77a2 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-library_2.12/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-library_2.12=2 2 | revision.minor.com.madavan%caustic-library_2.12=0 3 | revision.patch.com.madavan%caustic-library_2.12=3 4 | revision.snapshot.com.madavan%caustic-library_2.12=false 5 | revision.named_is_latest.com.madavan%caustic-library_2.12=false 6 | revision.sha.com.madavan%caustic-library_2.12=9f3074f4c474364a950606c12d8f6cf50a76dc05 7 | revision.fingerprint.com.madavan%caustic-library_2.12=60839b1b0b11945bbd6b91224a4b0cb845b36118 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-runtime_2.12/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-runtime_2.12=2 2 | revision.minor.com.madavan%caustic-runtime_2.12=0 3 | revision.patch.com.madavan%caustic-runtime_2.12=3 4 | revision.snapshot.com.madavan%caustic-runtime_2.12=false 5 | revision.named_is_latest.com.madavan%caustic-runtime_2.12=false 6 | revision.sha.com.madavan%caustic-runtime_2.12=9f3074f4c474364a950606c12d8f6cf50a76dc05 7 | revision.fingerprint.com.madavan%caustic-runtime_2.12=3ccd9f0fb6b13c4954c9b71ef75c0b514ea487c4 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-service_2.12/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-service_2.12=1 2 | revision.minor.com.madavan%caustic-service_2.12=4 3 | revision.patch.com.madavan%caustic-service_2.12=1 4 | revision.snapshot.com.madavan%caustic-service_2.12=false 5 | revision.named_is_latest.com.madavan%caustic-service_2.12=false 6 | revision.sha.com.madavan%caustic-service_2.12=77463670b605954acfc8a9940ac4da04a204511f 7 | revision.fingerprint.com.madavan%caustic-service_2.12=96a5ad0770d295d7ae834b68af0f7656d3a0f8b3 8 | -------------------------------------------------------------------------------- /build-support/ivy/pushdb/com.madavan/caustic-thrift/publish.properties: -------------------------------------------------------------------------------- 1 | revision.major.com.madavan%caustic-thrift=1 2 | revision.minor.com.madavan%caustic-thrift=4 3 | revision.patch.com.madavan%caustic-thrift=1 4 | revision.snapshot.com.madavan%caustic-thrift=false 5 | revision.named_is_latest.com.madavan%caustic-thrift=false 6 | revision.sha.com.madavan%caustic-thrift=77463670b605954acfc8a9940ac4da04a204511f 7 | revision.fingerprint.com.madavan%caustic-thrift=376681a4c390ad73c6fefd801604004d1f2a153b 8 | -------------------------------------------------------------------------------- /build-support/pants/publish/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/build-support/pants/publish/__init__.py -------------------------------------------------------------------------------- /build-support/pants/publish/register.py: -------------------------------------------------------------------------------- 1 | # pants/publish/register.py 2 | from pants.build_graph.build_file_aliases import BuildFileAliases 3 | from pants.backend.jvm.repository import Repository 4 | from pants.backend.jvm.ossrh_publication_metadata import ( 5 | Developer, License, OSSRHPublicationMetadata, Scm 6 | ) 7 | 8 | import os 9 | 10 | repository = Repository( 11 | name='public', 12 | url='https://oss.sonatype.org/#stagingRepositories', 13 | push_db_basedir=os.path.join('build-support', 'ivy', 'pushdb') 14 | ) 15 | 16 | metadata = OSSRHPublicationMetadata( 17 | description='Reinventing database transactions', 18 | url='https://github.com/ashwin153/caustic', 19 | licenses=[ 20 | License( 21 | name='Apache License, Version 2.0', 22 | url='http://www.apache.org/licenses/LICENSE-2.0' 23 | ) 24 | ], 25 | developers=[ 26 | Developer( 27 | name='Ashwin Madavan', 28 | email='ashwin.madavan@gmail.com', 29 | url='https://madavan.me' 30 | ) 31 | ], 32 | scm=Scm.github( 33 | user='ashwin153', 34 | repo='caustic' 35 | ) 36 | ) 37 | 38 | 39 | def build_file_aliases(): 40 | return BuildFileAliases(objects={ 41 | 'public': repository, 42 | 'describe': metadata, 43 | }) 44 | -------------------------------------------------------------------------------- /build-support/travis/pants.ini: -------------------------------------------------------------------------------- 1 | [DEFAULT] 2 | # Turn off all nailgun use. 3 | use_nailgun: False 4 | 5 | [compile.zinc] 6 | # The Travis free tier OOMs with more than one worker. 7 | worker_count: 1 8 | 9 | [jvm-distributions] 10 | # The JDK install is managed within the .travis.yml. 11 | paths: { 12 | 'linux': [ 13 | '%(homedir)s/opt/jdk1.8.0_40', 14 | ], 15 | } 16 | 17 | [test.junit] 18 | parallel_threads: 8 19 | 20 | [test.pytest] 21 | options: ['--duration=3'] 22 | -------------------------------------------------------------------------------- /caustic-assets/README.md: -------------------------------------------------------------------------------- 1 | # References 2 | - [Some Principles of Good Language Design][1], 3 | C. J. Date. 4 | - [Dandelion: A Compiler and Runtime for Heterogeneous Systems][2], 5 | C. J. Rossbach, Y. Yu, J. Currey, J. Martin, D. Fetterly. 6 | 7 | [1]: https://view.publitas.com/a2c3fd5c-c83c-4d8b-a70b-8899d5edbf01/some-principles-of-good-language-design-by-c-j-date/page/6-7 8 | [2]: http://sigops.org/sosp/sosp13/papers/p49-rossbach.pdf -------------------------------------------------------------------------------- /caustic-assets/images/caustic-banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/caustic-banner.png -------------------------------------------------------------------------------- /caustic-assets/images/caustic-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/caustic-logo.png -------------------------------------------------------------------------------- /caustic-assets/images/runtime-latency.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/runtime-latency.png -------------------------------------------------------------------------------- /caustic-assets/images/runtime-throughput.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/runtime-throughput.png -------------------------------------------------------------------------------- /caustic-assets/images/ycsb-runtime.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/ycsb-runtime.png -------------------------------------------------------------------------------- /caustic-assets/images/ycsb-throughput.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/images/ycsb-throughput.png -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/ff00c400_bff000000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/ff00c400_bff000000.png -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/hotspot_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/hotspot_16.png -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/pixel_ff800000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/pixel_ff800000.png -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/selector_group_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/selector_group_16.png -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_bar_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_bar_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_corner_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_corner_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_corner_minus_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_corner_minus_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_corner_plus_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_corner_plus_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_tee_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_tee_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_tee_minus_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_tee_minus_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/menu_tee_plus_18.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/menu_tee_plus_18.gif -------------------------------------------------------------------------------- /caustic-assets/results/profile/jprofiler_images/tree/pixel_transparent_1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/profile/jprofiler_images/tree/pixel_transparent_1.gif -------------------------------------------------------------------------------- /caustic-assets/results/runtime/css/bootstrap-slider.css: -------------------------------------------------------------------------------- 1 | .ui-slider .ui-slider-range { 2 | position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0; 3 | color: #ffffff; 4 | background-color: #0064cd; 5 | background-repeat: repeat-x; 6 | background-image: -khtml-gradient(linear, left top, left bottom, from(#049cdb), to(#0064cd)); 7 | background-image: -moz-linear-gradient(top, #049cdb, #0064cd); 8 | background-image: -ms-linear-gradient(top, #049cdb, #0064cd); 9 | background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #049cdb), color-stop(100%, #0064cd)); 10 | background-image: -webkit-linear-gradient(top, #049cdb, #0064cd); 11 | background-image: -o-linear-gradient(top, #049cdb, #0064cd); 12 | background-image: linear-gradient(top, #049cdb, #0064cd); 13 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#049cdb', endColorstr='#0064cd', GradientType=0); 14 | text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); 15 | border-color: #0064cd #0064cd #003f81; 16 | border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); 17 | } 18 | .ui-widget-header { 19 | font-weight:bold; 20 | border-color: #0064cd #0064cd #003f81; 21 | border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); 22 | border:1px solid #666; 23 | } 24 | .ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { 25 | 26 | background-color: #e6e6e6; 27 | background-repeat: no-repeat; 28 | background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), color-stop(25%, #ffffff), to(#e6e6e6)); 29 | background-image: -webkit-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); 30 | background-image: -moz-linear-gradient(top, #ffffff, #ffffff 25%, #e6e6e6); 31 | background-image: -ms-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); 32 | background-image: -o-linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); 33 | background-image: linear-gradient(#ffffff, #ffffff 25%, #e6e6e6); 34 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#e6e6e6', GradientType=0); 35 | 36 | text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75); 37 | 38 | color: #333; 39 | /*font-size: 13px;*/ 40 | line-height: normal; 41 | border: 1px solid #ccc; 42 | border-bottom-color: #bbb; 43 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); 44 | -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); 45 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); 46 | -webkit-transition: 0.1s linear background-image; 47 | -moz-transition: 0.1s linear background-image; 48 | -ms-transition: 0.1s linear background-image; 49 | -o-transition: 0.1s linear background-image; 50 | transition: 0.1s linear background-image; 51 | overflow: visible; 52 | 53 | } -------------------------------------------------------------------------------- /caustic-assets/results/runtime/css/icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/runtime/css/icons.gif -------------------------------------------------------------------------------- /caustic-assets/results/runtime/css/vline.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/runtime/css/vline.gif -------------------------------------------------------------------------------- /caustic-assets/results/runtime/img/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/runtime/img/arrow.png -------------------------------------------------------------------------------- /caustic-assets/results/runtime/img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ashwin153/caustic/d640c71a7e3f537bbe4f81062a187ef7e86997a3/caustic-assets/results/runtime/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /caustic-assets/results/runtime/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Performance Report 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 30 |
31 |
32 | 33 | 34 | 50 | 51 | 52 |
53 | 54 |
55 |
x-axis
56 |
57 | 58 | 62 | 63 | 66 |
67 |
68 | 69 | 70 | 97 | -------------------------------------------------------------------------------- /caustic-assets/results/runtime/js/ScalaMeter/dimensions.js: -------------------------------------------------------------------------------- 1 | var ScalaMeter = (function(parent) { 2 | var my = { name: "dimensions" }; 3 | 4 | /* 5 | * ----- imports ----- 6 | */ 7 | var h; 8 | 9 | var keys_, 10 | params_; 11 | 12 | my.init = function() { 13 | h = parent.helper; 14 | 15 | keys_ = []; 16 | params_ = d3.map(); 17 | }; 18 | 19 | my.addParam = function(key) { 20 | if (!params_.has(key)) { 21 | params_.set(key, addDimension(key, key.substr(h.dKey.paramPrefix.length))); 22 | keys_.push(key); 23 | } 24 | }; 25 | 26 | my.filterValues = function(data, legendOrder) { 27 | keys_.forEach(function(key, i) { 28 | var dim = params_.get(key); 29 | dim.filteredValues(h.unique(data, dim.keyFn(), i == 0 ? d3.ascending : legendOrder, true)); 30 | }); 31 | }; 32 | 33 | my.add = function(key) { 34 | var newDim = addDimension(key, key); 35 | params_.set(key, newDim); 36 | keys_.push(key); 37 | return newDim; 38 | } 39 | 40 | my.get = function(key) { 41 | return params_.get(key); 42 | }; 43 | 44 | my.getAll = function() { 45 | return keys_.map(function(key) { 46 | return params_.get(key); 47 | }); 48 | }; 49 | 50 | my.keys = function(_) { 51 | if (!arguments.length) return keys_; 52 | keys_ = _; 53 | }; 54 | 55 | function addDimension(key, caption) { 56 | return (function() { 57 | var key_ = key, 58 | caption_ = caption, 59 | selectMode_ = h.selectModes.single, 60 | selectedValues_ = d3.set(), 61 | expanded_ = false, 62 | format_ = h.numberFormat, 63 | keyFn_ = h.mapKey(key), 64 | filterContainer_, 65 | values_, 66 | filteredValues_, 67 | cfDimension_; 68 | 69 | function updateCrossfilter() { 70 | cfDimension_.filterFunction(function(d) { 71 | return d == null || selectedValues_.has(d); 72 | }); 73 | } 74 | 75 | function updateSelectMode() { 76 | switch (selectMode_) { 77 | case h.selectModes.single: 78 | var selectedValue = values_[0]; 79 | for (var i = 0; i < values_.length; i++) { 80 | if (selectedValues_.has(values_[i])) { 81 | selectedValue = values_[i]; 82 | break; 83 | } 84 | } 85 | selectedValues_ = d3.set([selectedValue]); 86 | break; 87 | case h.selectModes.all: 88 | selectedValues_ = d3.set(values_); 89 | break; 90 | } 91 | } 92 | 93 | return { 94 | init: function(data, cfDimension) { 95 | values_ = h.unique(data, h.mapKey(key), d3.ascending); 96 | 97 | // if (key == h.dKey.date) { 98 | // //generate random dates over the past 5 years 99 | // var today = +new Date(); 100 | // for(i=0; i<5000; i++){ 101 | // values_.push(today - 50 * 86400 * 1000 - Math.round(Math.random() * 5 * 365 * 86400 * 1000)); 102 | // } 103 | // values_.sort(d3.ascending); 104 | // } 105 | 106 | selectedValues_ = d3.set(values_); 107 | cfDimension_ = cfDimension; 108 | }, 109 | 110 | updateCrossfilter : updateCrossfilter, 111 | 112 | selectMode: function(_) { 113 | if (!arguments.length) return selectMode_; 114 | selectMode_ = _; 115 | updateSelectMode(); 116 | }, 117 | 118 | selectedValues: function(_) { 119 | if (!arguments.length) return selectedValues_; 120 | selectedValues_ = _; 121 | }, 122 | 123 | filteredValues: function(_) { 124 | if (!arguments.length) return filteredValues_; 125 | filteredValues_ = _; 126 | }, 127 | 128 | caption: function(_) { 129 | if (!arguments.length) return caption_; 130 | caption_ = _; 131 | }, 132 | 133 | format: function(_) { 134 | if (!arguments.length) return format_; 135 | format_ = _; 136 | }, 137 | 138 | filterContainer: function(_) { 139 | if (!arguments.length) return filterContainer_; 140 | filterContainer_ = _; 141 | }, 142 | 143 | expanded: function(_) { 144 | if (!arguments.length) return expanded_; 145 | expanded_ = _; 146 | }, 147 | 148 | key: function() { 149 | return key_; 150 | }, 151 | 152 | keyFn: function() { 153 | return keyFn_; 154 | }, 155 | 156 | clickValue: function(value) { 157 | if (selectMode_ == h.selectModes.single) { 158 | selectedValues_ = d3.set([value]); 159 | } else { 160 | if (selectedValues_.has(value)) { 161 | selectedValues_.remove(value); 162 | } else { 163 | selectedValues_.add(value); 164 | } 165 | if (selectedValues_.values().length == values_.length) { 166 | selectMode_ = h.selectModes.all; 167 | } else { 168 | selectMode_ = h.selectModes.select; 169 | } 170 | } 171 | }, 172 | 173 | getAllValues: function() { 174 | return values_; 175 | }, 176 | 177 | selectLast: function() { 178 | selectedValues_ = d3.set([values_[values_.length - 1]]); 179 | } 180 | }; 181 | })(); 182 | } 183 | 184 | parent[my.name] = my; 185 | 186 | return parent; 187 | })(ScalaMeter || {}); -------------------------------------------------------------------------------- /caustic-assets/results/runtime/js/ScalaMeter/helper.js: -------------------------------------------------------------------------------- 1 | var ScalaMeter = (function(parent) { 2 | var my = { name: "helper" }; 3 | 4 | var TSV_DATA_KEYS = { 5 | date: "date", 6 | paramPrefix: "param-", 7 | param: "param-size", 8 | value: "value", 9 | success: "success", 10 | cilo: "cilo", 11 | cihi: "cihi", 12 | complete: "complete", 13 | curve: "curve", 14 | index: "index" 15 | }; 16 | 17 | var SELECT_MODES = obj2enum({ 18 | single: "Single", 19 | select: "Select", 20 | all: "All" 21 | }); 22 | 23 | var LABEL_NULL = "none"; 24 | 25 | var DATE_FORMAT = (function(d) {return d3.time.format("%Y-%m-%d %H:%M:%S")(new Date(+d)); }); 26 | 27 | var NUMBER_FORMAT = createNumberFormat("\u202F"); // 202F: narrow no-break space 28 | 29 | my.curveKey = mapKey(TSV_DATA_KEYS.curve); 30 | 31 | my.dKey = TSV_DATA_KEYS; 32 | 33 | my.isDef = isDef; 34 | 35 | my.mapKey = mapKey; 36 | 37 | my.selectModes = SELECT_MODES; 38 | 39 | my.dateFormat = DATE_FORMAT; 40 | 41 | my.numberFormat = NUMBER_FORMAT; 42 | 43 | my.mainColors = (function() { 44 | var nGroups = 10; 45 | var groups = d3.scale.category10().domain(d3.range(nGroups)); 46 | return function(i) { 47 | return groups(i % nGroups); 48 | }; 49 | })(); 50 | 51 | my.ident = function(d) { 52 | return d; 53 | }; 54 | 55 | my.ascendingToInt = function(a, b) { 56 | return d3.ascending(+a, +b); 57 | }; 58 | 59 | my.sortBy = function(fn) { 60 | return function(a, b) { 61 | return d3.ascending(fn(a), fn(b)); 62 | }; 63 | }; 64 | 65 | my.fKey = function(d) { 66 | return d.key; 67 | }; 68 | 69 | my.fValue = function(d) { 70 | return d.value; 71 | }; 72 | 73 | my.unique = function(data, key, sort, includeNull){ 74 | includeNull = isDef(includeNull) ? includeNull : false; 75 | var values = d3.nest().key(key).map(data, d3.map).keys(); 76 | var hasNull = false; 77 | values = values.filter(function(d) { 78 | var isNull = (d == "null"); 79 | hasNull = hasNull || isNull; 80 | return !isNull; 81 | }).map(toInt); 82 | if (isDef(sort)) { 83 | values = values.sort(sort); 84 | } 85 | if (includeNull && hasNull) { 86 | values.unshift(null); 87 | } 88 | return values; 89 | }; 90 | 91 | function isDef(value) { 92 | return typeof value !== 'undefined'; 93 | } 94 | 95 | function mapKey(key) { 96 | return function(d) { return d.hasOwnProperty(key) ? d[key] : null }; 97 | } 98 | 99 | function obj2enum(obj) { 100 | var result = { enumAll: [] }; 101 | for (var key in obj) { 102 | result[key] = { 103 | key: key, 104 | value: obj[key] 105 | }; 106 | result.enumAll.push(result[key]); 107 | } 108 | return result; 109 | }; 110 | 111 | function toInt(d) { 112 | return +d; 113 | } 114 | 115 | function createNumberFormat(thousandsSeparator) { 116 | return function(d) { 117 | if (d == null) { 118 | return LABEL_NULL; 119 | } else { 120 | var parts = d.toString().split("."); 121 | parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, thousandsSeparator); 122 | return parts.join("."); 123 | } 124 | }; 125 | } 126 | 127 | parent[my.name] = my; 128 | 129 | return parent; 130 | })(ScalaMeter || {}); -------------------------------------------------------------------------------- /caustic-assets/results/runtime/js/ScalaMeter/main.js: -------------------------------------------------------------------------------- 1 | var ScalaMeter = (function(parent) { 2 | var my = { name: "main" }; 3 | 4 | /* 5 | * ----- public functions ----- 6 | */ 7 | 8 | my.init = function() { 9 | parent.chart.init(); 10 | parent.filter.init(); 11 | parent.dimensions.init(); 12 | parent.permalink.init(); 13 | 14 | load(); 15 | }; 16 | 17 | function load() { 18 | loadModules([parent.filter, parent.chart], parent.filter.update); 19 | } 20 | 21 | function loadModules(modules, onLoad) { 22 | var nWaiting = modules.length; 23 | 24 | modules.forEach(function(module) { 25 | module.load(function() { 26 | nWaiting--; 27 | if (nWaiting == 0) { 28 | onLoad(); 29 | } 30 | }); 31 | }); 32 | } 33 | 34 | parent[my.name] = my; 35 | 36 | return parent; 37 | })(ScalaMeter || {}); -------------------------------------------------------------------------------- /caustic-assets/results/runtime/js/ScalaMeter/permalink.js: -------------------------------------------------------------------------------- 1 | var ScalaMeter = (function(parent) { 2 | var my = { name: "permalink" }; 3 | 4 | var BITLY_ACCESS_TOKEN = "34fda5dc3ef2ea36e6caf295f4a6443b4afa7401"; 5 | 6 | var URL_PARAM_NAME = "config"; 7 | 8 | var storedData_; 9 | 10 | /* 11 | * ----- public functions ----- 12 | */ 13 | 14 | my.init = function() { 15 | storedData_ = parseUrl(); 16 | 17 | window.onhashchange = function() { 18 | location.reload(); 19 | }; 20 | // window.onhashchange = function() { 21 | // storedData_ = parseUrl(); 22 | // parent.main.reload(); 23 | // }; 24 | 25 | var permalinkBtn = ".btn-permalink"; 26 | 27 | $(permalinkBtn).popover({ 28 | placement: 'bottom', 29 | trigger: 'manual', 30 | title: 'Press Ctrl-C to copy Shorten', 31 | html: true 32 | }).click(function(event) { 33 | event.preventDefault(); 34 | $(this).data('popover').options.content = '