aboutsummaryrefslogtreecommitdiffhomepage
path: root/Firestore/core
Commit message (Collapse)AuthorAge
* Port Query::testNaNFilter() from java (#1549)Gravatar rsgowman2018-07-18
| | | | | | Note that this works even though we haven't ported the NanFilter class yet. (The RelationFilter handles nan's just fine. Though also doesn't restrict nan's in cases where they shouldn't be used, i.e. anything except equality.)
* Port PrimitiveValueTest test for core::Query (#1530)Gravatar rsgowman2018-07-17
| | | | | (From java.) Also fix a bug uncovered by the test. (oops)
* Minimize rereading of batches in FSTLocalDocumentsView ↵Gravatar Konstantin Varlamov2018-07-16
| | | | | | | documentsMatchingCollectionQuery (#1533) Previously in `documentsMatchingCollectionQuery`, write batches were read three times; in fact, all relevant batches will always be contained inside `allMutationBatchesAffectingQuery` (which is also more efficient); the other two calls were redundant.
* Convert grpc and protobuf CMake builds to add_subdirectory (#1537)Gravatar Gil2018-07-16
| | | | | | | | | | | | | | | | * Build zlib with grpc's add_subdirectory * Build grpc and its children with add_subdirectory. * Build c-ares with grpc's add_subdirectory * Convert protobuf to a download-only ExternalProject * Temporarily break protobuf within grpc This works because libgrpc has no actual dependency on protobuf * Update boringssl to master@{2018-07-10}
* Suppress uninitialized read error under VS2017 (#1523)Gravatar Gil2018-07-13
| | | | | | | | * Suppress uninitialized read error under VS2017. * Default-initialize Tag instead of requiring users to remember to do so. * Add constructors to match usage
* Initial (incomplete) implementation of f:f:core::Filter (#1495)Gravatar rsgowman2018-07-13
| | | | | And RelationFilter subclass. Used to implement the next step in core::Query.
* Convert googletest and nanopb CMake builds to add_subdirectory (#1522)Gravatar Gil2018-07-13
| | | | | | | | | | | | | | | | | | | | | | | | | | * Add a download-only boringssl ExternalProject Match boringssl version to grpc submodule version Note: not yet in use * Split grpc into separate download and build tasks This allows other external targets to download into the gRPC source tree before grpc is actually built. * Convert grpc to an http download * Build googletest with add_subdirectory Also: * Revert library-name modifications in the abseil-cpp build * Move abseil-cpp add_subdirectory build into place * Build nanopb with add_subdirectory * Force nanopb first to work around ODR violations This is a temporary work-around for b/111328563.
* Fix Firestore when compiled with Xcode 8.3 (#1519)Gravatar Gil2018-07-11
| | | | | | | | | | | | | * Add a travis stage that tests building Firestore with Xcode 8.3. * Simulate on a device available in Xcode 8 * Fix compile errors under Xcode 8.3.3 * Remove Firestore_SwiftTests_iOS from the Firestore_Tests_iOS Scheme I'll create a new target for this but in another PR. * Add an entry to CHANGELOG.md
* Firestore CMake cleanup (#1510)Gravatar Gil2018-07-11
| | | | | | | | | | | | | | | * Pull out sanitizer options into a separate file * Reorder packages * Remove the extra "external/$target" directory from PREFIX Instead of BINARY_DIR/external/foo/src/foo the contents will be in BINARY_DIR/src/foo. * Make libprotobuf-nanopb targets line up with nanopb's CMakeLists.txt * Fix CMake style
* Fix Firestore source errors under VS2017 (#1515)Gravatar Gil2018-07-11
| | | | | | | | | | | | | | | | * Project file updates from sync_project.rb * Fix misc compile errors under VS2017 * Fix util/hashing under VS2017 std::hash<int> is not just a pass through in Microsoft's STL. * Disable unsafe code warnings in VS2017 ... where comparing against a reference implementation that has no easy safe equivalent. * Handle drive letters in paths on Windows
* C++ migration: add a C++ implementation of `FSTExponentialBackoff` (#1465)Gravatar Konstantin Varlamov2018-07-10
| | | | | | | | | | | This is a pretty close port of `FSTExponentialBackoff`. The changes are pretty minor: * delay is calculated using <chrono> duration types, not plain numbers, which should be a little more type-safe; * split a piece of code into a ClampDelay function, because it's reasonably close to std::clamp; * rephrased the class-level comment to make it clearer that the first attempt always has delay = 0; * added simple tests (other platforms don't have tests for this). Also make sure that canceling a DelayedOperation is always valid.
* Eliminate unnecessary DocumentKey->FSTDocumentKey conversions (#1507)Gravatar Konstantin Varlamov2018-07-10
|
* C++: for immutable data structures, forbid ignoring result of insert/eraseGravatar Konstantin Varlamov2018-07-09
|
* Split GoogleUtilities from FirebaseCore (#1370)Gravatar Paul Beusterien2018-07-06
|
* Add support for NoDocument in the local serializer (#1484)Gravatar rsgowman2018-07-03
|
* Initial (incomplete) implementation of f:f::core::Query (#1471)Gravatar rsgowman2018-06-29
|
* Install googletest (#1461)Gravatar Gil2018-06-26
| | | Also add FindGMock to Find gmock after installation
* Refactor nanopb decoding methods (#1438)Gravatar rsgowman2018-06-25
| | | Rather than decoding the type, and then the contents, decode them both at once.
* Fix a few implicit converstion warnings (#1439)Gravatar rsgowman2018-06-22
| | | Were showing up in xcode build (but not cmake build)
* Refactored a few methods from anon namespace to remote serializer (#1435)Gravatar rsgowman2018-06-22
|
* Initial creation of the local serializer. (#1415)Gravatar rsgowman2018-06-21
| | | Added a single, basic test as a motivator.
* Hookup serializer_test.cc to the xcode based test suite (#1343)Gravatar rsgowman2018-06-18
|\
* | Avoid closing unintialized substreams (#1411)Gravatar Mina Farid2018-06-18
| | | | | | | | | | * A substream should not be closed if pb_make_string_substream() failed to create it and returned false. * Fixed a potential wrong error message.
* | Minor LevelDB cleanups (#1401)Gravatar Gil2018-06-13
| | | | | | | | | | | | * Add leveldb_transaction* to the CMake build * Use std::unique_ptr for leveldb::DB pointers
* | Create Status objects from errno (#1374)Gravatar Gil2018-06-12
| | | | | | | | | | | | | | | | | | | | | | * Add a portable interface to strerror * Add Status::FromErrno * Add strerror_test.cc to the Xcode project * Use glibc feature selection macros instead of return-type overloads * Fix tensorflow references
| * Merge remote-tracking branch 'origin/master' into rsgowman/protobuf_cppGravatar Rich Gowman2018-06-12
| |\ | |/ |/|
| * Merge remote-tracking branch 'origin/master' into rsgowman/protobuf_cppGravatar Rich Gowman2018-06-12
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also "fixed" BadFieldValueTagWithOtherValidTagsPresent test by changing 'false' to 'true'. Details: Depending on the version of nanopb, nanopb would explicitly encode 'false', which shouldn't be done in proto3. When it's explicitly encoded, the test worked properly. But when it was (properly) dropped, the invalid tag is the only field that's actually encoded, thus violating the assumptions of the test, leading to a test failure. s/false/true fixes it, as now the boolean_value field is (properly) encoded regardless of version.
* | | Force refresh token if RPC fails with "Unauthenticated" error (#1373)Gravatar Konstantin Varlamov2018-06-07
| | | | | | | | | "Unauthenticated" is presumed to mean that token is expired (which might happen if local clock is wrong) and retried, subject to the usual backoff logic.
* | | Fix support scripts on Linux (#1385)Gravatar Gil2018-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Make it possible to run style.sh on Linux Needs clang-format in a nonstandard location, but can be made to work. * Fix lint.sh on Linux * Fix multiline comment error
* | | Fix undefined behaviour in test. (#1381)Gravatar rsgowman2018-06-05
| | | | | | | | | | | | | | | PB_LAST_FIELD is required by nanopb, but was missed in the test. Without this, undefined behaviour results. (Either manifesting itself as fine (i.e. if there's zeros following) or segfaults.)
* | | Add pathname manipulation utilities (#1376)Gravatar Gil2018-06-05
| |/ |/|
* | Skip unknown fields while decoding BatchGetDocumentsResponse proto objects ↵Gravatar rsgowman2018-06-05
| | | | | | | | (#1377)
* | Build cleanup (#1375)Gravatar Gil2018-06-04
| | | | | | | | | | | | * Remove extraneous firebase_firestore_util_async_queue target * Remove unimplemented declaration in string_util.h
* | Skip unknown fields while decoding FieldValue proto objects. (#1354)Gravatar rsgowman2018-06-04
| |
* | Rename nanopb generated headers from foo.pb.h to foo.nanopb.h (#1371)Gravatar rsgowman2018-06-04
| | | | | | | | | | This avoids a collision with the libprotobuf generated files. Also removes the "well-known" cpp protos, relying on libprotobuf to supply these instead.
* | Fix Firestore compilation under Xcode < 9.2 (#1367)Gravatar Gil2018-06-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Don't rely on specialization failure to determine when std::hash is unavailable. Instead manually declare the conditions under which std::hash should be defined. * Fix detection of Objective-C classes in Xcode < 9.2 std::is_base_of<NSObject, NSString>{} is false there so the overloads defined for Objective-C types weren't getting enabled. * Add explicit tests for StringFormat using Objective-C objects * Add explicit tests for HasStdHash
* | Remove nearly all usages of WrapNSStringNoCopy (#1351)Gravatar Gil2018-05-30
| |
* | Allow repeated entries in Value proto. (#1346)Gravatar rsgowman2018-05-30
| | | | | | | | | | | | | | Normally, this would be unexpected, as only a single entry in the Value proto *should* be present. However, the proto docs state that parsers should be able to handle repeated fields. (In the case of repeated fields, the last one "wins".)
* | Handle deserializing BatchGetDocumentsResponse error case... (#1344)Gravatar rsgowman2018-05-29
| | | | | | | | ... where neither 'found' nor 'missing' fields set.
* | "Handle" BatchGetDocumentsResponse.transaction (by ignoring it) (#1318)Gravatar rsgowman2018-05-28
| |
* | Firestore project: Import of API interfaces. (#1337)Gravatar zxu2018-05-25
|/ | | | | | | | | | | | | | | | | | | | - 198063502 Address comment upstream. by zxu <zxu> - 197942352 Fix style upstream and fix destination depot in copybara. by zxu <zxu> - 197925542 Fix headers with change from GitHub, see the current diff... by zxu <zxu> - 197922012 Implement ListenerRegistration::Remove(). by zxu <zxu> - 197713382 Implement more on listener class and implement ListenerRe... by zxu <zxu> - 196551381 Implement more on listener class and implement the Docume... by zxu <zxu> - 196276752 Implement the SnapshotMetadata with inline methods and (n... by zxu <zxu> - 195841793 Implement the wrapper class for callback (EventListener). by zxu <zxu> - 194112388 Add Android-Wrapper for DocumentReference's non-callback ... by zxu <zxu> - 192445183 Add Android-Wrapper for Firestore's remaining methods. by zxu <zxu> - 190986604 Manually import the public portion of by mcg <mcg> - 189013767 Add Android-Wrapper for Firestore's method that does not ... by zxu <zxu> - 188809445 Import of firebase-ios-sdk from Github. by mcg <mcg> - 187049498 Import of firebase-ios-sdk from Github. by mcg <mcg> - 184568931 Import of firebase-ios-sdk from Github. by mcg <mcg> ORIGINAL_AUTHOR=Firebase <firebase-noreply> PiperOrigin-RevId: 198063502
* Replace Objective-C assertions with C++ assertions (#1327)Gravatar Gil2018-05-24
| | | | | | | | * Migrate FSTFail to HARD_FAIL * FSTCFail -> HARD_FAIL * FSTCAssert -> HARD_ASSERT * FSTAssert -> HARD_ASSERT * Replace FSTAssert with NSAssert in dead Objective-C code * Remove FSTAssert.h
* Fix Objective-C logging (#1322)Gravatar Gil2018-05-23
|
* Deserialize NoDocument instances (#1311)Gravatar rsgowman2018-05-23
| | | | | | Note that it isn't possible to *serialize* NoDocuments. Still TODO: - Error handling
* Reimplement C++ logging (#1313)Gravatar Gil2018-05-23
| | | | | | | * Add direct support for formatting Objective-C objects * Rewrite log.h * Convert FSTWarn to LOG_WARN * Convert FSTLog to LOG_DEBUG * Remove FSTLogger
* Remove extraneous braces (#1315)Gravatar Gil2018-05-22
|
* Add a HARD_ASSERT C++ assertion macro (#1304)Gravatar Gil2018-05-22
| | | | | | * Add HARD_ASSERT * Use HARD_ASSERT * Remove FIREBASE_ASSERT * Remove StringPrintf
* Add namespace alias for v1beta1 (#1310)Gravatar rsgowman2018-05-22
| | | Roughly s/google::firebase::v1beta1/v1beta1/g
* Firestore project fixes (#1301)Gravatar Gil2018-05-22
| | | | | | * Move GoogleTest.podspec out of the Tests tree * Rename GoogleTests to CoreTests * Move CoreTests to the top-level * Move FSTGoogleTestTests.mm into core/test
* [De]serialize non-empty Document instances (#1284)Gravatar rsgowman2018-05-22
| | | | | | | * [De]serialize non-empty Document instances Still TODO: - NoDocument - ErrorHandling