| 3922 | } |
| 3923 | |
| 3924 | void HandleClientRecoverSnapshot(const std::vector<std::string> parts, |
| 3925 | ::fedb::client::TabletClient* client) { |
| 3926 | if (parts.size() < 3) { |
| 3927 | std::cout << "Bad RecoverSnapshot format" << std::endl; |
| 3928 | return; |
| 3929 | } |
| 3930 | try { |
| 3931 | bool ok = |
| 3932 | client->RecoverSnapshot(boost::lexical_cast<uint32_t>(parts[1]), |
| 3933 | boost::lexical_cast<uint32_t>(parts[2])); |
| 3934 | if (ok) { |
| 3935 | std::cout << "RecoverSnapshot ok" << std::endl; |
| 3936 | } else { |
| 3937 | std::cout << "Fail to RecoverSnapshot" << std::endl; |
| 3938 | } |
| 3939 | } catch (boost::bad_lexical_cast& e) { |
| 3940 | std::cout << "Bad RecoverSnapshot format" << std::endl; |
| 3941 | } |
| 3942 | } |
| 3943 | |
| 3944 | void HandleClientSendSnapshot(const std::vector<std::string> parts, |
| 3945 | ::fedb::client::TabletClient* client) { |
no test coverage detected