Coder Social home page Coder Social logo

rowillia / mongofill-hhvm Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mongofill/mongofill-hhvm

0.0 3.0 0.0 130 KB

A mix of the original Mongofill extension + BSON implementation in C++

License: MIT License

Shell 0.47% CMake 3.27% C++ 91.21% Hack 5.06%

mongofill-hhvm's Introduction

Mongofill for HHVM Build Status

This package provides a drop-in replacement of the official mongodb extension, as a HNI extension to be executed under HHVM runtime

The BSON encode and decode functions are implemented in C++ and the rest of the interface is in pure PHP thanks to Mongofill.

This HNI implementation is 3-5 times faster than the original mongofill extension in pure PHP, too provide a working phpversion("mongo") under HHVM, returning 1.4.5, missed in the original mongofill.

Building and Installation

Installation requires hhvm-dev package to be installed. Alternatively a copy of HHVM can be built from source on the local machine; instructions on how to do this are available on the HHVM Wiki.

The library libbson is required to be installed in the system, you can follow the instructions in the libbson repository.

Once done, the following commands will build the extension.

git clone https://github.com/mongofill/mongofill-hhvm
cd mongofill-hhvm
./build.sh

This will produce a mongo.so file, the dynamically-loadable extension.

To enable the extension, you need to have the following section in your hhvm config file

hhvm.dynamic_extension_path = /path/to/hhvm/extensions
hhvm.dynamic_extensions[mongo] = mongo.so

Supported libraries

You can check the current supported libraries at wiki page Supported-Libraries

Community

You can catch us on IRC on Freenode channel #mongofill

Benchmarking

A small suite of benchmarking is included with the mongofill package, you can run the suite with this command:

php ./vendor/bin/athletic -b tests/bootstrap.php  -p tests/Mongofill/Benchmarks/

Some results can be find at: https://gist.github.com/mcuadros/9551290

License

MIT, see LICENSE

mongofill-hhvm's People

Contributors

mcuadros avatar pomyk avatar leev avatar nantunes avatar digitalkaoz avatar mihail812 avatar

Watchers

Roy Williams avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.