Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion plugins/authproxy/authproxy.cc
Original file line number Diff line number Diff line change
Expand Up @@ -656,7 +656,7 @@ AuthProxyGlobalHook(TSCont /* cont ATS_UNUSED */, TSEvent event, void *edata)
auth->txn = txn;
return AuthRequestContext::dispatch(auth->cont, event, edata);
}
// fallthru
// fallthrough

default:
return TS_EVENT_NONE;
Expand Down
4 changes: 2 additions & 2 deletions plugins/background_fetch/background_fetch.cc
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ struct BgFetchData {
// This needs the txnp temporarily, so it can copy the pristine request
// URL. The txnp is not used once initialize() returns.
//
// Upon succesful completion, the struct should be ready to start a
// Upon successful completion, the struct should be ready to start a
// background fetch.
bool
BgFetchData::initialize(TSMBuffer request, TSMLoc req_hdr, TSHttpTxn txnp)
Expand Down Expand Up @@ -678,7 +678,7 @@ TSRemapDoRemap(void *ih, TSHttpTxn txnp, TSRemapRequestInfo * /* rri */)
if (TS_SUCCESS == TSHttpTxnClientReqGet(txnp, &bufp, &req_hdrs)) {
TSMLoc field_loc = TSMimeHdrFieldFind(bufp, req_hdrs, TS_MIME_FIELD_RANGE, TS_MIME_LEN_RANGE);

if (!field_loc) { // Less common case, but also allow If-Range header to triger, but only if Range not present
if (!field_loc) { // Less common case, but also allow If-Range header to trigger, but only if Range not present
field_loc = TSMimeHdrFieldFind(bufp, req_hdrs, TS_MIME_FIELD_IF_RANGE, TS_MIME_LEN_IF_RANGE);
}

Expand Down
2 changes: 1 addition & 1 deletion plugins/background_fetch/configs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ BgFetchConfig::parseOptions(int argc, const char *argv[])
return true;
}

// Read a config file, populare the linked list (chain the BgFetchRule's)
// Read a config file, populate the linked list (chain the BgFetchRule's)
bool
BgFetchConfig::readConfig(const char *config_file)
{
Expand Down
2 changes: 1 addition & 1 deletion plugins/cachekey/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Description
This plugin allows some common cache key manipulations based on various HTTP request elements. It can

* sort query parameters to prevent query parameters reordereding from being a cache miss
* sort query parameters to prevent query parameters reordering from being a cache miss
* ignore specific query parameters from the cache key by name or regular expression
* ignore all query parameters from the cache key
* only use specific query parameters in the cache key by name or regular expression
Expand Down
2 changes: 1 addition & 1 deletion plugins/cachekey/configs.h
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ class Configs
/**
* @brief provides means for post-processing of the plugin parameters to finalize the configuration or to "cache" some of the
* decisions for later use.
* @return true if succesful, false if failure.
* @return true if successful, false if failure.
*/
bool finalize();

Expand Down
8 changes: 4 additions & 4 deletions plugins/cachekey/pattern.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,18 +47,18 @@ Pattern::Pattern() : _pattern(""), _replacement("") {}
* @return true if successful, false if failure
*/
bool
Pattern::init(const String &pattern, const String &replacenemt, bool replace)
Pattern::init(const String &pattern, const String &replacement, bool replace)
{
pcreFree();

_pattern.assign(pattern);
_replacement.assign(replacenemt);
_replacement.assign(replacement);
_replace = replace;

_tokenCount = 0;

if (!compile()) {
CacheKeyDebug("failed to initialize pattern:'%s', replacement:'%s'", pattern.c_str(), replacenemt.c_str());
CacheKeyDebug("failed to initialize pattern:'%s', replacement:'%s'", pattern.c_str(), replacement.c_str());
pcreFree();
return false;
}
Expand Down Expand Up @@ -151,7 +151,7 @@ Pattern::pcreFree()
}

/**
* @bried Destructor, frees PCRE related resources.
* @brief Destructor, frees PCRE related resources.
*/
Pattern::~Pattern()
{
Expand Down
2 changes: 1 addition & 1 deletion plugins/cachekey/pattern.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class Pattern
Pattern();
virtual ~Pattern();

bool init(const String &pattern, const String &replacenemt, bool replace);
bool init(const String &pattern, const String &replacement, bool replace);
bool init(const String &config);
bool empty() const;
bool match(const String &subject);
Expand Down
6 changes: 3 additions & 3 deletions plugins/compress/compress.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ using namespace std;
using namespace Gzip;

// FIXME: custom dictionaries would be nice. configurable/content-type?
// a gprs device might benefit from a higher compression ratio, whereas a desktop w. high bandwith
// a GPRS device might benefit from a higher compression ratio, whereas a desktop w. high bandwith
// might be served better with little or no compression at all
// FIXME: look into compressing from the task thread pool
// FIXME: make normalizing accept encoding configurable
Expand Down Expand Up @@ -136,7 +136,7 @@ data_destroy(Data *data)
{
TSReleaseAssert(data);

// deflateEnd returnvalue ignore is intentional
// deflateEnd return value ignore is intentional
// it would spew log on every client abort
deflateEnd(&data->zstrm);

Expand Down Expand Up @@ -429,7 +429,7 @@ compress_transform_one(Data *data, TSIOBufferReader upstream_reader, int amount)
(data->compression_algorithms & (ALGORITHM_GZIP | ALGORITHM_DEFLATE))) {
gzip_transform_one(data, upstream_buffer, upstream_length);
} else {
warning("No compression supported. Shoudn't come here.");
warning("No compression supported. Shouldn't come here.");
}

TSIOBufferReaderConsume(upstream_reader, upstream_length);
Expand Down
2 changes: 1 addition & 1 deletion plugins/conf_remap/conf_remap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ struct RemapConfigs {
int _current = 0;
};

// Helper functionfor the parser
// Helper function for the parser
inline TSRecordDataType
str_to_datatype(const char *str)
{
Expand Down
2 changes: 1 addition & 1 deletion plugins/esi/README.combo
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The arguments in the plugin.config line in order represent
2) The name of the key used for signature verification (disabled
by default) [verification not implemented yet]

3) A colon separated list of headers which, if present on atleast one
3) A colon separated list of headers which, if present on at least one
response, will be added to the combo response.

A "-" can be supplied as a value for any of these arguments to request
Expand Down
2 changes: 1 addition & 1 deletion plugins/esi/esi.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1537,7 +1537,7 @@ globalHookHandler(TSCont contp, TSEvent event, void *edata)
TSDebug(DEBUG_TAG, "[%s] handling cache lookup complete event", __FUNCTION__);
if (isCacheObjTransformable(txnp, &intercept_header, &head_only)) {
// we make the assumption above that a transformable cache
// object would already have a tranformation. We should revisit
// object would already have a transformation. We should revisit
// that assumption in case we change the statement below
addTransform(txnp, false, intercept_header, head_only, pOptionInfo);
Stats::increment(Stats::N_CACHE_DOCS);
Expand Down
2 changes: 1 addition & 1 deletion plugins/esi/fetcher/FetchedDataProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class FetchedDataProcessor
public:
FetchedDataProcessor(){};

virtual void processData(const char *reqeust_url, int request_url_len, const char *response_data, int response_data_len) = 0;
virtual void processData(const char *requeset_url, int request_url_len, const char *response_data, int response_data_len) = 0;

virtual ~FetchedDataProcessor(){};
};
2 changes: 1 addition & 1 deletion plugins/esi/lib/EsiGunzip.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ EsiGunzip::EsiGunzip(const char *debug_tag, ComponentBase::Debug debug_func, Com
{
_init = false;
_success = true;
// zlib _zstrm varibles are initialzied when they are required in stream_decode
// zlib _zstrm variables are initialized when they are required in stream_decode
// coverity[uninit_member]
// coverity[uninit_ctor]
}
Expand Down
2 changes: 1 addition & 1 deletion plugins/esi/lib/EsiGzip.cc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ using namespace EsiLib;
EsiGzip::EsiGzip(const char *debug_tag, ComponentBase::Debug debug_func, ComponentBase::Error error_func)
: ComponentBase(debug_tag, debug_func, error_func), _downstream_length(0), _total_data_length(0)
{
// Zlib _zstrm varibles are initialized when they are required in runDeflateLoop
// Zlib _zstrm variables are initialized when they are required in runDeflateLoop
// coverity[uninit_member]
// coverity[uninit_ctor]
}
Expand Down
8 changes: 4 additions & 4 deletions plugins/esi/lib/EsiProcessor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using std::string;
using namespace EsiLib;
extern pthread_key_t threadKey;
// this needs to be a fixed address as only the address is used for comparision
// this needs to be a fixed address as only the address is used for comparison
const char *EsiProcessor::INCLUDE_DATA_ID_ATTR = reinterpret_cast<const char *>(0xbeadface);

#define FAILURE_INFO_TAG "plugin_esi_failureInfo"
Expand Down Expand Up @@ -699,7 +699,7 @@ EsiProcessor::_handleHtmlComment(const DocNodeList::iterator &curr_node)
_debugLog(_debug_tag, "[%s] parsed %d inner nodes from html comment node", __FUNCTION__, inner_nodes.size());
DocNodeList::iterator next_node = curr_node;
++next_node;
_node_list.splice(next_node, inner_nodes); // insert after curr node for preprocessing
_node_list.splice(next_node, inner_nodes); // insert after curr node for pre-processing
return true;
}

Expand Down Expand Up @@ -733,9 +733,9 @@ EsiProcessor::_preprocess(DocNodeList &node_list, int &n_prescanned_nodes)
break;
case DocNode::TYPE_HTML_COMMENT:
/**
* the html comment <!--esi innertext--> is a container.
* the html comment <!--esi inner text--> is a container.
* the esi processor will remove the starting tag "<!--esi" and the
* closure tag "-->", then keep the innertext (the content within it).
* closure tag "-->", then keep the inner text (the content within it).
*
* we should call _handleHtmlComment when the node list is parsed
* from the content,
Expand Down
6 changes: 3 additions & 3 deletions plugins/esi/lib/FailureInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,12 +101,12 @@ class FailureInfo : private EsiLib::ComponentBase
/* Keep track of the number of windows filled prev*/
size_t _windowsPassed;

/*Used as a deciding factor between attempt/except
* incase prob is complete truth
/* Used as a deciding factor between attempt/except
* in case prob is complete truth
*/
double _avgOverWindow;

public:
/*Was a reqeust made*/
/*Was a request made*/
bool _requestMade;
};
4 changes: 2 additions & 2 deletions plugins/esi/lib/Stats.cc
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ namespace Stats
g_system = system;
if (g_system) {
for (int i = 0; i < Stats::MAX_STAT_ENUM; ++i) {
// FIXME doesn't return avalue.
// FIXME doesn't return a value.
g_system->create(i);
/* if (!g_system->create(i)) {
Utils::ERROR_LOG("[%s] Unable to create stat [%s]", __FUNCTION__, Stats::STAT_NAMES[i]);
Expand All @@ -56,7 +56,7 @@ namespace Stats
increment(Stats::STAT st, int step /* = 1 */)
{
if (g_system) {
// FIXME doesn't return avalue.
// FIXME doesn't return a value.
g_system->increment(st, step);
/*
if (!g_system->increment(st, step)) {
Expand Down
2 changes: 1 addition & 1 deletion plugins/esi/test/sampleProb.cc
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ isAttemptReq(string URL, FailureData &data)
// cout<<"Failure:"<<passFail[i].first<< "Total"<< (passFail[i].first+passFail[i].second )<<endl;
if (passFail[i].first > 0) {
avg += passFail[i].first / (passFail[i].first + passFail[i].second);
// cout<<"Prob of faillure:"<<passFail[i].first/(passFail[i].first+passFail[i].second)<<endl;
// cout<<"Prob of failure:"<<passFail[i].first/(passFail[i].first+passFail[i].second)<<endl;
}
}

Expand Down
8 changes: 4 additions & 4 deletions plugins/experimental/access_control/access_control.cc
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ KvpAccessToken::parse(const StringView token)
/* Look for the next KVP */
pos = _token.find(_tokenConfig.pairDelimiter, prev);
StringView kvp = _token.substr(prev, pos - prev);
size_t equalsign = kvp.find(_tokenConfig.kvDeliiter);
size_t equalsign = kvp.find(_tokenConfig.kvDelimiter);
if (kvp.npos == equalsign) {
ERROR_OUT("invalid key-value-pair, missing key-value delimiter");
return _state = INVALID_SYNTAX;
Expand Down Expand Up @@ -231,11 +231,11 @@ KvpAccessToken::parse(const StringView token)
return _state = INVALID_FIELD;
}

prev = pos + _tokenConfig.kvDeliiter.size();
prev = pos + _tokenConfig.kvDelimiter.size();
} while (pos != token.npos);

/* Now identify the pay-load which was signed */
payloadSize += _tokenConfig.messageDigestName.size() + _tokenConfig.kvDeliiter.size();
payloadSize += _tokenConfig.messageDigestName.size() + _tokenConfig.kvDelimiter.size();
_payload = _token.substr(0, payloadSize);

DEBUG_OUT("payload:'" << _payload << "'");
Expand All @@ -256,7 +256,7 @@ void
KvpAccessTokenBuilder::appendKeyValuePair(const StringView &key, const StringView value)
{
_buffer.append(_buffer.empty() ? "" : _config.pairDelimiter);
_buffer.append(key).append(_config.kvDeliiter).append(value);
_buffer.append(key).append(_config.kvDelimiter).append(value);
}

void
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/access_control/access_control.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ struct KvpAccessTokenConfig {
StringView messageDigestName = "md";

String pairDelimiter = "&";
String kvDeliiter = "=";
String kvDelimiter = "=";
};

/**
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/access_control/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,5 +66,5 @@ class AccessControlConfig
String _extrTokenIdHdrName; /** @brief header name to extract the token id, if empty => no extraction */
String _extrValidationHdrName; /** @brief header name to extract the token validation status, if empty => no extraction */
bool _useRedirects = false; /** @brief true - use redirect to set the access token cookie, @todo not used yet */
Classifier _uriPathScope; /**< @brief blacklist (exclude) and white-list (include) whcih path should have the access control */
Classifier _uriPathScope; /**< @brief blacklist (exclude) and white-list (include) which path should have the access control */
};
8 changes: 4 additions & 4 deletions plugins/experimental/access_control/pattern.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,18 +47,18 @@ Pattern::Pattern() : _pattern(""), _replacement("") {}
* @return true if successful, false if failure
*/
bool
Pattern::init(const String &pattern, const String &replacenemt, bool replace)
Pattern::init(const String &pattern, const String &replacement, bool replace)
{
pcreFree();

_pattern.assign(pattern);
_replacement.assign(replacenemt);
_replacement.assign(replacement);
_replace = replace;

_tokenCount = 0;

if (!compile()) {
AccessControlDebug("failed to initialize pattern:'%s', replacement:'%s'", pattern.c_str(), replacenemt.c_str());
AccessControlDebug("failed to initialize pattern:'%s', replacement:'%s'", pattern.c_str(), replacement.c_str());
pcreFree();
return false;
}
Expand Down Expand Up @@ -160,7 +160,7 @@ Pattern::pcreFree()
}

/**
* @bried Destructor, frees PCRE related resources.
* @brief Destructor, frees PCRE related resources.
*/
Pattern::~Pattern()
{
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/access_control/pattern.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class Pattern
Pattern();
virtual ~Pattern();

bool init(const String &pattern, const String &replacenemt, bool replace);
bool init(const String &pattern, const String &replacement, bool replace);
bool init(const String &config);
bool empty() const;
bool match(const String &subject);
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/acme/acme.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ make_absolute_path(char *dest, int dest_len, const char *file, int file_len)
for (i = 0; i < file_len; ++i) {
char c = file[i];

/* Assure that only Base64-URL chracter are in the path */
/* Assure that only Base64-URL character are in the path */
if (!(c == '-' || c == '_' || (c >= '0' && c <= '9') || (c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z'))) {
TSDebug(PLUGIN_NAME, "Invalid Base64 character found, error");
return 0;
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/balancer/hash.cc
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ struct HashBalancer : public BalancerInstance {

// OK, now look up this hash in the hash ring. lower_bound() finds the first element that is not less than the
// target, so the element we find is the first key that is greater than our target. To visualize this in the
// hash ring, that means that each node owns the preceeding keyspace (ie. the node is at the end of each keyspace
// hash ring, that means that each node owns the preceding keyspace (ie. the node is at the end of each keyspace
// range). This means that when we wrap, the first node owns the wrapping portion of the keyspace.
loc = this->hash_ring.lower_bound(key);
if (loc == this->hash_ring.end()) {
Expand Down
6 changes: 3 additions & 3 deletions plugins/experimental/buffer_upload/README
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Upload proxy specs for phase I:

1. Memory buffering (buffer the entire POST data in IOBuffer before connecting to OS)
1.1. Memory buffer size is configured with "mem_buffer_size" in config file. Default and minimum value is 32K
You can increase it in the config file. If a request's size is larger than "mem_buffer_size" specifiied
You can increase it in the config file. If a request's size is larger than "mem_buffer_size" specified
in config file, then the upload proxy feature will be disabled for this particular request

2. Disk buffering (buffer the entire POST data on disk before connecting to OS)
Expand Down Expand Up @@ -43,9 +43,9 @@ Upload proxy specs for phase I:
5.1. for now check if the "host" part in the URL is same as the proxy server name, then will do this conversion
5.2. To turn on URL conversion feature, set "convert_url 1" in config file

6. All request headers inlcuding cookies plus the entire POST data will be buffered (either in memory or on disk)
6. All request headers including cookies plus the entire POST data will be buffered (either in memory or on disk)

7. Config file can be explicitly sepcified as a parameter in command line (in plugin.config file)
7. Config file can be explicitly specified as a parameter in command line (in plugin.config file)


a sample config file:
Expand Down
2 changes: 1 addition & 1 deletion plugins/experimental/cache_range_requests/README
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Configuration:
Or for a global plugin where all range requests are processed,
Add cache_range_requests.so to the plugin.config

Parent Selection Mode (consisent-hash only):
Parent Selection Mode (consistent-hash only):

default: Parent selection is based solely on the hash of a URL Path
In this mode, all partial content of a URL is requested from the same
Expand Down
Loading