Commit Graph

538 Commits

Author SHA1 Message Date
mpilman 46119dce0d Disabled c-bindin tests on Windows 2019-02-15 00:01:42 -08:00
mpilman 4266429dcf Fixed python dependency 2019-02-15 00:01:42 -08:00
mpilman ddddda7328 docker-compose can now build rpm
weirdly it still generates a foundationd-unspecified
rpm. However, it is empty and can be ignored for now
2019-02-15 00:01:42 -08:00
mpilman 6529e2790b several minor bug fixes 2019-02-15 00:01:42 -08:00
mpilman ffaaaf5028 build fat-jar with packages
The packages target will now build the fat jar and
it will place the jar file into the packages directory
2019-02-15 00:01:42 -08:00
mpilman 458c14ffcd Ruby bindings for cmake + gem generation
make packages will now also generate a gem file and
put it into the packages directory within the build directory
2019-02-15 00:01:42 -08:00
mpilman 7ae3cc8ce4 Fix go binding dependency paths
Before this commit, the go bindings would
always be recompiled
2019-02-15 00:01:42 -08:00
mpilman 9b7dcc4ed5 flow, python, and go bindings 2019-02-15 00:01:42 -08:00
mpilman 44cb835ffe build python sdist 2019-02-15 00:01:42 -08:00
mpilman 50a01fb8ce Build flow-binding 2019-02-15 00:01:42 -08:00
mpilman 733ba0a751 Build c_performance_test and rwy_benchmark
addresses #1035
2019-02-15 00:01:42 -08:00
mpilman 75f692b931 simplify actorcompiler and target to compile coveragetool 2019-02-15 00:01:42 -08:00
mpilman 70545e07d8 Added documentation on how to build the jar-files 2019-02-15 00:01:42 -08:00
mpilman 1ed149e624 Add option to build fat jar 2019-02-15 00:01:42 -08:00
mpilman f601aa7407 Make Java an optional dependency 2019-02-15 00:01:42 -08:00
Vishesh Yadav 907446d0ce Merge remote-tracking branch 'apple/master' into task/tls-upgrade 2019-02-14 11:37:38 -08:00
Andrew Noyes 067a445e06 Replace unused _ variables with wait(success(...)) 2019-02-12 17:30:30 -08:00
Colin Adler 1b04f9a71a fixup! fixup! fixup! fixup! Add support for modules 2019-02-12 11:27:43 -08:00
Colin Adler 8be2de8cc2 fixup! fixup! fixup! Add support for modules 2019-02-12 11:27:43 -08:00
Colin Adler 789bc6d4ee fixup! fixup! Add support for modules 2019-02-12 11:27:43 -08:00
Colin Adler 676e1ceb73 fixup! Add support for modules 2019-02-12 11:27:43 -08:00
Colin Adler dc38c68c76 Add support for modules
Because of how fdb-go-install.sh functions, it's necessary to use to use
the folder that the script installs to, located at
$GOPATH/src/github.com/apple/foundationdb/bindings/go. Since modules
will use the version from
$GOPATH/pkg/mod/github.com/apple/foundationdb/bindings/go and has a checksum of it
stored in go.sum, it's not possible to use this package currently with modules enabled.

I believe the solution to this problem is to use replace directives:
https://github.com/golang/go/wiki/Modules#when-should-i-use-the-replace-directive

After using the install script, adding
`replace github.com/apple/foundationdb/bindings/go => $GOPATH/src/github.com/apple/foundationdb/bindings/go`
will allow Go programs to be built normally with modules.

Note: $GOPATH cannot be used directly and must be expanded into an absolute
or relative path.

This go.mod must be added for replace directives to work correctly.
2019-02-12 11:27:43 -08:00
Colin 2f83e595cf Disable modules in Golang binding install script 2019-02-12 11:27:43 -08:00
A.J. Beamon 32b3c2ad69 Add comment for the code where we replace the semaphore in the exception handler 2019-02-11 10:35:29 -08:00
A.J. Beamon 5bf7e72fc5 If the semaphore acquire is interrupted (e.g. by a signal), then replace it with a new one so that subsequent futures will still work. 2019-02-11 10:22:19 -08:00
A.J. Beamon 8960670694 Python now blocks on a future in Python rather than in native code to preserve Python's signal handling functionality. In particular, this means that ctrl-c will work in the REPL. 2019-02-08 13:51:01 -08:00
A.J. Beamon 4c0481da40 Fix comment in go bindings that describes an old implementation. Add a release note for the new Go bindings change and add links to the existing release notes entries. 2019-02-08 12:38:38 -08:00
A.J. Beamon 093f4d9b83
Merge pull request #1091 from ajbeamon/fix-python-onready
Python: _CBFUNC should be defined outside init_c_api
2019-02-08 11:26:51 -08:00
A.J. Beamon 685242fbfc
Merge pull request #1092 from atn34/trace-format-network-option
Add trace_format network option
2019-02-08 10:52:50 -08:00
A.J. Beamon b61722e3ab
Merge pull request #1010 from pjvds/patch-2
fdb.Key implements fmt.Stringer interface
2019-02-08 09:47:15 -08:00
mpilman e45295a1f5 Added support for TLS 2019-02-07 15:37:04 -08:00
mpilman f03cd6aee1 make c bindings work on Windows 2019-02-07 15:37:04 -08:00
mpilman 8a94d80deb fdbservice and fdbrpc now compiling 2019-02-07 15:37:04 -08:00
mpilman 7a858b902d Most of FDB compiling on Windows with cmake 2019-02-07 15:37:04 -08:00
A.J. Beamon 192a48105c
Merge pull request #1124 from apple/release-6.0
Merge Release 6.0 into master
2019-02-07 12:22:40 -08:00
Pieter Joost van de Sande 8f181fde3b replace strings builder with bytes buffer 2019-02-03 20:48:21 +01:00
Balachandar Namasivayam 84a7fd1254 Add missing file fdbimpl_v609.rb to the package 2019-01-31 15:36:14 -08:00
Tim Guggenmos dd4d9b104b
Staying consistent with Pointer syntax
Space after '*' instead of before it
2019-01-29 10:07:49 +01:00
Andrew Noyes 768d7678be Add trace_format network option 2019-01-28 15:14:17 -08:00
A.J. Beamon ec995ebef0 _CBFUNC should be defined outside init_c_api, both because it doesn't depend on the C API and because it is used elsewhere and wasn't available globally as previously written 2019-01-25 11:32:49 -08:00
A.J. Beamon 2173e0acda Remove ClusterOptions from generated sources in Java 2019-01-25 09:30:02 -08:00
Evan Tschannen 1d7fec3074 Merge commit '048bfc5c368063d9e009513078dab88be0cbd5b0' into task/tls-upgrade-2
# Conflicts:
#	.gitignore
2019-01-24 17:43:06 -08:00
Andrew Noyes 1c1e42396c ClusterOptions.java is no longer generated 2019-01-24 16:04:56 -08:00
Andrew Noyes 6b34d62918 Fix GENERATED_JAVA_DIR 2019-01-24 15:59:18 -08:00
Andrew Noyes aa566a755f Account for file mv's/rm's in java bindings cmake 2019-01-24 15:41:27 -08:00
Alec Grieser 04b94e74c7
Merge pull request #942 from ajbeamon/remove-cluster-from-bindings
Remove cluster from bindings
2019-01-24 14:39:09 -08:00
Andrew Noyes 4bca5dad73 Fix _bit_length for 0 and negative numbers 2019-01-22 10:09:58 -08:00
Andrew Noyes 5a6f82a75b bit_length python 2.6 compat 2019-01-22 10:09:03 -08:00
A.J. Beamon e9ffe09b8b Go bindings reported the wrong required version when loading an incompatible version of fdb_c. 2019-01-14 10:55:28 -08:00
A.J. Beamon 401f8a6774 Python and Ruby bindings displayed an unhelpful error if trying to load an old incompatible fdb_c with a new binding. 2019-01-14 10:41:54 -08:00
A.J. Beamon 627b785a24 Fix: null handling for cluster file paths didn't work after merge 2019-01-11 10:04:05 -08:00
A.J. Beamon 8451c0cfc1 Favor nullptr in JNI code. 2019-01-10 13:13:21 -08:00
A.J. Beamon bfa97d7ff2 Address review comments 2019-01-10 12:28:14 -08:00
A.J. Beamon 11cce3731b Merge branch 'master' into remove-cluster-from-bindings
# Conflicts:
#	bindings/c/fdb_c.cpp
2019-01-10 11:58:34 -08:00
Pieter Joost van de Sande ead5bb5bc6 add Printable example to docs 2019-01-10 11:10:52 +01:00
Pieter Joost van de Sande b96c21210a fix padding in key printing 2019-01-10 08:44:30 +01:00
Pieter Joost van de Sande 696a876fd4 fix String duplication for fdb.Key 2019-01-09 00:17:23 +01:00
Pieter Joost van de Sande 4722fa0667 change fdb string representation to common format 2019-01-09 00:03:44 +01:00
Pieter Joost van de Sande 0401d04380
fdb.Key implements fmt.Stringer interface
Add the ability to get a human readable string representation of a fdb.Key by satisfying the fmt.Stringer interface. This allows keys to be used with the fmt package.
2019-01-08 09:44:16 +01:00
Bhaskar Muppana 5a8419e5cf Move Java specific setup into bindings/java/CMakeLists.txt
and s/SET/set
2019-01-02 21:19:08 -08:00
Bhaskar Muppana aa2a76ef4c
Merge pull request #981 from alexmiller-apple/cmake
Add a CMake build system
2019-01-02 18:50:15 -08:00
anoyes 6a4d87802b Replace & operator with variadic function 2018-12-28 11:33:42 -08:00
Markus Pilman df0f491c29 Some more improvements to the build and preparations for packaging 2018-12-13 15:04:13 -08:00
Markus Pilman f8eac70700 Fixed C bindings DLLEXPORT and Java bindings 2018-12-13 14:59:36 -08:00
Markus Pilman 5fafeaf219 added bindings to cmake build 2018-12-13 14:54:38 -08:00
Markus Pilman 4833afea53 CMake compiles fdb c bindings 2018-12-13 14:54:13 -08:00
Bryant Luk 2379552aea
Fix Go bindings possible nested comment warnings
When using the Go bindings in a project, you can get compilation
warnings for the `/*` in the comment blocks. These warnings seem
unnecessary.

Warning is:

\# github.com/apple/foundationdb/bindings/go/src/fdb
In file included from _cgo_export.c:4:
cgo-gcc-export-header-prolog:43:1: warning: '/*' within block comment [-Wcomment]
cgo-gcc-export-header-prolog:44:1: warning: '/*' within block comment [-Wcomment]
2018-12-13 15:41:01 -06:00
Vishesh Yadav e8e01b2406 Remove unused localAddress parameter from newNet2 and Net2 classes 2018-12-13 13:36:52 -08:00
Aaron Greenlee a1a88b2f47
Fixed apparent typo in help response 2018-12-08 17:27:32 -05:00
A.J. Beamon 97847f517b throw platform_error; -> throw platform_error();. Convert some spaces to tabs. 2018-11-28 12:56:57 -08:00
Alec Grieser 3a38288d35
remove whitespace to fix go fmt check 2018-11-28 09:09:35 -08:00
A.J. Beamon 975711c389 Merge branch 'release-6.0' of github.com:apple/foundationdb
# Conflicts:
#	documentation/sphinx/source/release-notes.rst
2018-11-27 09:50:39 -08:00
Alec Grieser d462315809
Merge pull request #908 from pjvds/patch-1
document Begin and End members of KeyRange
2018-11-27 09:02:50 -08:00
Pieter Joost van de Sande 080464ba38
specify type on both begin and end field 2018-11-27 17:11:42 +01:00
Pieter Joost van de Sande 1c2de49bf2
match KeyRange docs with the rest of the docs 2018-11-27 08:19:46 +01:00
A.J. Beamon d1e6c81d99 The binding tester wouldn't align keys that had nan in them. Also, the ruby tester generated a few keys with byte strings instead of unicode. 2018-11-26 15:31:40 -08:00
A.J. Beamon 96b9cbcfcf fdb_c.cpp needs access to the legacy types, the C binding test uses the new API, and a couple javadoc links fixed. 2018-11-26 13:07:36 -08:00
A.J. Beamon 890a0f3e82 Merge branch 'master' into remove-cluster-from-bindings
# Conflicts:
#	bindings/flow/fdb_flow.actor.cpp
2018-11-26 12:01:03 -08:00
A.J. Beamon b19ab6d3dc Don't use null as the cluster pointer if the cluster file path is null because the Java bindings don't work with a null cluster pointer. 2018-11-26 11:52:35 -08:00
Alex Miller d076999f9b Fix the fix of the build of the bindings target.
The bindings build was broken becaue fdb_c_performance_test failed to
link with errors of the form:

    /tmp/ccym9LhK.o: In function `clearAll':
    /opt/foundationdb/bindings/c/test/performance_test.c:130: undefined reference to `fdb_transaction_clear_range'
    /tmp/ccym9LhK.o: In function `insertRange':
    /opt/foundationdb/bindings/c/test/performance_test.c:139: undefined reference to `fdb_transaction_set'
    /tmp/ccym9LhK.o: In function `singleKey':
    /opt/foundationdb/bindings/c/test/performance_test.c:540: undefined reference to `fdb_transaction_set'
    ...

PR #901's e8f20e4 fixed this by adding `-shared` to the invocation line,
and thus doing a dynamic linking of libfdb_c.

As dynamically linking produced a working executable, this suggests that
the correct set of libraries are being linked, as the symbols can be
located eventually, just not in the right order, as the linker will
proactively not include unnecessary object files from static libraries.
And unfortunately, our performance test framework likely expects to be able
to copy the binary, and not have to worry about associated dynamically
linked libraries, so a statically linked binary is preferred.

The underlying cause of this link error is that the static library
preceeded the source code in the command line:

    /usr/bin/gcc -Werror -Wno-error=format -fPIC -DNO_INTELLISENSE -fvisibility=hidden -DNDEBUG=1 -Wreturn-type -fno-omit-frame-pointer -O2 -g -Llib -lfdb_c -lpthread -Ibindings/c -o bin/fdb_c_performance_test bindings/c/test/performance_test.c

This comes from the line in the Makefile:

    @$(CC) $(CFLAGS) $(fdb_c_tests_LIBS) $(fdb_c_tests_HEADERS) -o $@ bindings/c/test/performance_test.c

As we pass `-lfdb_c` before `performance_test.c`, when the linker is
considering libfdb_c.a, it sees that no symbols from any of the object
files are currently needed, and thus doesn't include them.  When we
proceprocess performance_test.c, we suddenly need these symbols, but
it's too late, as the linker only processes files left-to-right.

Thus, we can resolve this problem by passing -lfdb_c after performance_test.c

Also of note is that we only seem to have this problem because the link
line was crafted by hand instead of using link-wrapper.sh, which already
does the right thing.
2018-11-13 16:15:32 -08:00
Evan Tschannen e45952bc53 Merge branch 'release-6.0'
# Conflicts:
#	documentation/sphinx/source/release-notes.rst
#	fdbclient/BackupContainer.actor.cpp
#	fdbclient/BlobStore.actor.cpp
#	fdbclient/HTTP.actor.cpp
#	tests/BlobStore.txt
#	versions.target
2018-11-13 16:06:39 -08:00
Evan Tschannen abb7299e1d
Merge pull request #901 from AlvinMooreSr/bindings-build
Fixed build of bindings target
2018-11-13 12:31:35 -08:00
Alec Grieser 8424fc57ec
add period to comment 2018-11-13 11:55:54 -08:00
Alec Grieser 3c8347e724
add comments for some tricky int-packing code 2018-11-13 11:41:23 -08:00
Alec Grieser 7e4f84c60e
Merge remote-tracking branch 'upstream/release-6.0' into feature-bigint-support-go-ruby-aj 2018-11-13 11:28:10 -08:00
Evan Tschannen 4e54690005 Merge branch 'release-6.0'
# Conflicts:
#	fdbserver/DataDistribution.actor.cpp
#	fdbserver/MoveKeys.actor.cpp
2018-11-12 20:26:58 -08:00
Pieter Joost van de Sande 4f4f3ebb2d
document Begin and End members of KeyRange
This allows friendly hints by tools that have go doc integration or alike.
2018-11-12 21:51:06 +01:00
Evan Tschannen 4b5d0b4e2c Merge branch 'release-6.0'
# Conflicts:
#	documentation/sphinx/source/release-notes.rst
#	fdbclient/AsyncFileBlobStore.actor.cpp
#	fdbclient/AsyncFileBlobStore.actor.h
#	fdbclient/BlobStore.actor.cpp
#	fdbclient/BlobStore.h
#	fdbclient/HTTP.actor.cpp
#	fdbclient/ManagementAPI.actor.cpp
#	fdbclient/NativeAPI.actor.cpp
#	fdbrpc/LoadBalance.actor.h
#	fdbrpc/batcher.actor.h
#	fdbrpc/fdbrpc.vcxproj
#	fdbrpc/sim2.actor.cpp
#	fdbserver/DataDistribution.actor.cpp
#	fdbserver/DataDistributionTracker.actor.cpp
#	fdbserver/SimulatedCluster.actor.cpp
#	fdbserver/TLogServer.actor.cpp
#	fdbserver/masterserver.actor.cpp
2018-11-10 13:04:24 -08:00
Evan Tschannen a654183f63
Merge pull request #791 from ajbeamon/remove-cluster-from-iclientapi
Remove cluster from IClientApi (phase 2 of removing DB names)
2018-11-10 10:16:18 -08:00
Alvin Moore e8f20e409f Added shared library option to allow the c project tests to build 2018-11-08 08:40:56 -08:00
A.J. Beamon d38393a82f Key alignment in the binding tester results checking didn't properly determine the minimum available key. Add some comments to results checking code. 2018-11-01 12:38:00 -07:00
A.J. Beamon d02c37965d Merge branch 'release-6.0' into feature-bigint-support-go-ruby 2018-11-01 11:33:48 -07:00
A.J. Beamon 93cfec51c7 Add a test that's intended to test tuple encoding. Currently, it only checks the encoding of integers at and near the boundaries of every extra bit (i.e. 2^1, 2^2, 2^3, ...). Fixed some bugs in the binding tester results checking that made it hard to interpret results. Commit more instructions in a batch. 2018-10-31 14:18:28 -07:00
A.J. Beamon 5035c51d15 Some fixes to the type chosen for decoding integers in Go. Fix to ruby encoding at byte boundaries. Add execute bit to ruby tester. 2018-10-31 14:09:23 -07:00
A.J. Beamon 23d5382cea Add uint64 handling to golang stack tester tuples 2018-10-31 09:19:13 -07:00
A.J. Beamon 377f5e2c48 Add release notes and fix formatting 2018-10-30 15:06:47 -07:00
A.J. Beamon 42d101c517 Merge branch 'tuple-uint64' into feature-bigint-support-go-ruby
# Conflicts:
#	bindings/go/src/fdb/tuple/tuple.go
2018-10-30 14:23:26 -07:00
Justin Lowery bee8d12b24 remove multiple binary.Read calls and use a single type conversion instead 2018-10-30 14:06:03 -07:00
Justin Lowery f112ba4f07 restore NewBuffer calls, as buffer was emptied on Read calls when the value was a uint64 2018-10-30 14:06:03 -07:00
Justin Lowery 36b3818aef remove redundant calls to NewBuffer that use the bp slice. remove redundant declaration of retInt 2018-10-30 14:06:03 -07:00