mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Remove obsolete classes, disable unused code, and tidy up:
* Removed MultiSocket. Code that previously used the MultiSocket now uses a combination of boost::asio coroutines and CRTP. * Sitefiles headers rolled up and directory flattened. * Disabled Sitefiles use of deprecated HTTPClient. * Validators headers tidied up. * Disabled Validators use of deprecated HTTPClient.
This commit is contained in:
@@ -17,7 +17,6 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <beast/module/asio/asio.h>
|
||||
#include <memory>
|
||||
|
||||
namespace ripple {
|
||||
@@ -27,10 +26,22 @@ class SourceURLImp
|
||||
: public SourceURL
|
||||
, public beast::LeakChecked <SourceURLImp>
|
||||
{
|
||||
private:
|
||||
beast::URL m_url;
|
||||
|
||||
// VFALCO This is turned off because the HTTPClient
|
||||
// implementation is now obsolete. A new HTTP client
|
||||
// that uses the latest best practices (asio coroutines,
|
||||
// beast::http::message and beast::http::parser) should
|
||||
// be used.
|
||||
#if 0
|
||||
std::unique_ptr <beast::asio::HTTPClientBase> m_client;
|
||||
#endif
|
||||
|
||||
public:
|
||||
explicit SourceURLImp (beast::URL const& url)
|
||||
: m_url (url)
|
||||
, m_client (beast::asio::HTTPClientBase::New ())
|
||||
//, m_client (beast::asio::HTTPClientBase::New ())
|
||||
{
|
||||
}
|
||||
|
||||
@@ -58,11 +69,12 @@ public:
|
||||
|
||||
void cancel ()
|
||||
{
|
||||
m_client->cancel ();
|
||||
//m_client->cancel ();
|
||||
}
|
||||
|
||||
void fetch (Results& results, beast::Journal journal)
|
||||
{
|
||||
#if 0
|
||||
auto httpResult (m_client->get (m_url));
|
||||
|
||||
if (httpResult.first == 0)
|
||||
@@ -77,11 +89,8 @@ public:
|
||||
"HTTP GET to " << m_url <<
|
||||
" failed: '" << httpResult.first.message () << "'";
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
private:
|
||||
beast::URL m_url;
|
||||
std::unique_ptr <beast::asio::HTTPClientBase> m_client;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <beast/module/core/text/LexicalCast.h>
|
||||
#include <beast/utility/Debug.h>
|
||||
#include <boost/regex.hpp>
|
||||
|
||||
namespace ripple {
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <beast/module/core/maths/Random.h>
|
||||
#include <beast/unit_test/suite.h>
|
||||
|
||||
namespace ripple {
|
||||
|
||||
Reference in New Issue
Block a user