Giter Site home page Giter Site logo

bullsoft / mysql-binlog-events Goto Github PK

View Code? Open in Web Editor NEW
13.0 9.0 7.0 264 KB

download from http://labs.mysql.com/

License: GNU General Public License v2.0

CMake 7.64% C++ 60.84% Objective-C 29.57% C 1.95%
mysql binlog mysql-binlog libmysqlclient mysql-binlog-events

mysql-binlog-events's Introduction

BullSoft Openshift

Port from openshift, but not like that, Only for ubuntu server - 'cause we use sudo apt-get install in build script for instance.

To make it faster, I have made a mirror in Baidu BCS for packages here.

##INSTALL

###Firstly, add these to your ~/.bashrc

export OPENSHIFT_DIY_DIR=$HOME
export OPENSHIFT_DIY_LOG_DIR=$HOME/log
export OPENSHIFT_DIY_IP=0.0.0.0
export OPENSHIFT_DIY_PORT=8080

export OPENSHIFT_REDIS_PORT=6379
export OPENSHIFT_HAPROXY_PORT=80

export OPENSHIFT_REPO_DIR=$HOME
export OPENSHIFT_DATA_DIR=$HOME/.openshift/data
export OPENSHIFT_TMP_DIR=$HOME/.openshift/tmp

if [ -f ${OPENSHIFT_DATA_DIR}/.bash_profile ]; then
    . ${OPENSHIFT_DATA_DIR}/.bash_profile
fi

To make these effective, you should source it.

soure ~/.bashrc

###Then, type these on terminal:

cd ~
git clone https://github.com/BullSoft/openshift.git
cd ~/openshift/action_hooks/
./build
  Maybe you have to type ```password``` to let it continue.

###Finally, type:

cp -r ~/openshift/wwwroot ~/

... and the file structure would be like this

.
├── log
│   ├── access.log
│   ├── error.log
│   ├── php-fpm.log
│   └── redis_6379.log
├── openshift
│   ├── action_hooks
│   ├── README.md
│   ├── tmpl
│   └── wwwroot
├── run
│   ├── mysql.pid
│   ├── mysql.sock
│   ├── nginx.pid
│   ├── php-fpm.pid
│   ├── php-fpm.socket
│   └── redis_6379.pid
├── runtime
│   ├── etc
│   ├── haproxy
│   ├── libs
│   ├── mysql
│   ├── nginx
│   ├── php5
│   └── redis
└── wwwroot
    └── index.php
    

mysql-binlog-events's People

Contributors

guweigang avatar ideal avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mysql-binlog-events's Issues

Compiling issues

Hi
I'm having issues compiling this library, did most what was told ,

root@redis06:~/jayme/mysql-binlog-events# cmake . -DMYSQLCLIENT_STATIC_LINKING:BOOL=TRUE
-- You will link statically to the MySQL client library (set with -DMYSQLCLIENT_STATIC_LINKING=<bool>)
-- Searching for static libraries with the base name(s) "libmysqlclient_r.a libmysqlclient.a"
-- mysql_config was found /usr/bin/mysql_config
-- MySQL client environment/cmake variables set that the user can override
--   MYSQL_DIR                   : /usr/lib/x86_64-linux-gnu
--   MYSQL_INCLUDE_DIR           : /usr/include/mysql
--   MYSQL_LIB_DIR               : /usr/lib/x86_64-linux-gnu
--   MYSQL_CONFIG_EXECUTABLE     : /usr/bin/mysql_config
--   MYSQL_CXX_LINKAGE           : 1
--   MYSQL_CFLAGS                : -I/usr/include/mysql
--   MYSQL_CXXFLAGS              : -I/usr/include/mysql
--   MYSQLCLIENT_STATIC_LINKING  : TRUE
--   MYSQLCLIENT_NO_THREADS      :
-- MySQL client optional environment/cmake variables set by the user
--   MYSQL_EXTRA_LIBRARIES       :
--   MYSQL_LINK_FLAGS            :
-- MySQL client settings that the user can't override
--   MYSQL_VERSION               : 5.7.19
--   MYSQL_NUM_VERSION           : 50719
--   MYSQL_LIB                   : /usr/lib/x86_64-linux-gnu/libmysqlclient.a
--   MYSQL_LIBRARIES             : /usr/lib/x86_64-linux-gnu/libmysqlclient.a;pthread;z;m;rt;dl;rt
-- Configuring done
-- Generating done
-- Build files have been written to: /root/jayme/mysql-binlog-events
root@redis06:~/jayme/mysql-binlog-events# echo $MYSQL_SOURCE_INCLUDE_DIR
/root/jayme/mysql-5.7.19/include
root@redis06:~/jayme/mysql-binlog-events# make
[ 20%] Built target binlogevents_static
[ 40%] Built target binlogevents_shared
[ 42%] Building CXX object bindings/src/CMakeFiles/replication_static.dir/access_method_factory.cpp.o
In file included from /root/jayme/mysql-binlog-events/bindings/include/field_iterator.h:20:0,
                 from /root/jayme/mysql-binlog-events/bindings/include/binlog.h:35,
                 from /root/jayme/mysql-binlog-events/bindings/include/tcp_driver.h:24,
                 from /root/jayme/mysql-binlog-events/bindings/src/access_method_factory.cpp:21:
/root/jayme/mysql-binlog-events/bindings/include/value.h:21:21: fatal error: my_time.h: No such file or directory
compilation terminated.
bindings/src/CMakeFiles/replication_static.dir/build.make:62: recipe for target 'bindings/src/CMakeFiles/replication_static.dir/access_method_factory.cpp.o' failed
make[2]: *** [bindings/src/CMakeFiles/replication_static.dir/access_method_factory.cpp.o] Error 1
CMakeFiles/Makefile2:217: recipe for target 'bindings/src/CMakeFiles/replication_static.dir/all' failed
make[1]: *** [bindings/src/CMakeFiles/replication_static.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2

when trying to make I get an error that a certain mysql header file can't be found..
but it's in the MYSQL_SOURCE_INCLUDE_DIR folder,/root/jayme/mysql-5.7.19/include.. /root/jayme/mysql-5.7.19/include/my_time.h file exists

What should I adjust?
(As a fix I also tried doing export MYSQL_INCLUDE_DIR=/root/jayme/mysql-5.7.19/include" but that gave other compiler issues, as that expects the compiled version of mysql_version.h etc.

Thx!

Row_event_iterator unusable in for loop

EXAMPLE:

Row_event_set::iterator rows_itr = rowset.begin();
for (; rows_itr != rowset.end(); ++rows_itr) {
    // never reach here
    Row_of_fields rof(*rows_itr);
    std::cout << "\ncurrent row change:";
    //...
}

CAUSE:
Row_event_set::begin() & Row_event_set::end() returns nontrivially constructed and trivially constructed Row_event_iterator respectively.
However nontrivially constructed Row_event_iterator compares the same as trivially constructed one, making the first for loop exit directly as inequality test fails.
WORKAROUND:
Row_event_iterator is usable in do..while loop, as the first star operator call modifies its internal state and make it compare different from trivially constructed one.

Row_event_set::iterator rows_itr = rowset.begin();
do {
    Row_of_fields rof(*rows_itr);
    std::cout << "\ncurrent row change:";
    //...
} while (++rows_itr != rowset.end());

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.