Skip to content

Commit

Permalink
Rename rocksdb references backupable_db -> backup_engine
Browse files Browse the repository at this point in the history
Summary:
Exact codemod:
```
perl -pi -e 's/backupable_db.h/backup_engine.h/g' `fbgs -l backupable_db.h`
perl -pi -e 's/BackupableDBOptions/BackupEngineOptions/g' `fbgs -l
BackupableDBOptions`
perl -pi -e 's/backupable_db_options/backup_engine_options/g' `fbgs -l
backupable_db_options`
hg revert fbcode/rocksdb/ fbcode/internal_repo_rocksdb/
```

Manually add extra #include for these (because of reduced transitive includes):
```
rocks/nfs_volume/nfs_volume_backup_test.cc
stargate/StargateDb.h
```

In preparation for removing old header and names. See
facebook/rocksdb#9438

Reviewed By: ajkr

Differential Revision: D33780423

fbshipit-source-id: ed3078818c7964ffb50693b34b93b67ef8a2aae6
  • Loading branch information
pdillinger authored and facebook-github-bot committed Jan 27, 2022
1 parent 624adee commit 7273b23
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions glean/rocksdb/rocksdb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include <rocksdb/filter_policy.h>
#include <rocksdb/slice_transform.h>
#include <rocksdb/table.h>
#include <rocksdb/utilities/backupable_db.h>
#include <rocksdb/utilities/backup_engine.h>

#include "glean/rocksdb/rocksdb.h"
#include "glean/rocksdb/stats.h"
Expand Down Expand Up @@ -380,7 +380,7 @@ struct ContainerImpl final : Container {
rocksdb::BackupEngine *p;
check(rocksdb::BackupEngine::Open(
rocksdb::Env::Default(),
rocksdb::BackupableDBOptions(path),
rocksdb::BackupEngineOptions(path),
&p));
return std::unique_ptr<rocksdb::BackupEngine>(p);
}
Expand Down

1 comment on commit 7273b23

@donsbot
Copy link
Contributor

@donsbot donsbot commented on 7273b23 Jan 28, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This breaks OSS builds which use the packaged rocksdb 6.11.

librocksdb-dev/stable,now 6.11.4-3 amd64 [installed]

which don't have the new headers.

dons@linode1:/usr/include/rocksdb/utilities$ ls -1
backupable_db.h
checkpoint.h
convenience.h
db_ttl.h

This is made slightly more OSS-painful as the getdepys.py rocksdb manifest is way out of date and uses a .tar.gz from ancient times, which also dosen't have the header. https://github.com/facebook/folly/blob/main/build/fbcode_builder/manifests/rocksdb

Please sign in to comment.