Skip to content

Commit

Permalink
Merge pull request #150 from muflihun/develop
Browse files Browse the repository at this point in the history
updated simple zuhd and ver
  • Loading branch information
abumq authored Nov 24, 2018
2 parents 45a531a + 81a9b38 commit d2f3284
Show file tree
Hide file tree
Showing 130 changed files with 329 additions and 192 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Change Log

## [2.3.6] - 24-11-2018
- Updated license
- Updated easylogging++ to 9.96.7

## [2.3.5] - 07-09-2018
- Updated easylogging++ 9.96.5 to fix enabled bug

Expand Down Expand Up @@ -134,7 +138,7 @@

### Fixes
- Crash detected when writing to session #79
- Fixed undefined behaviour with destroyed sessions
- Fixed undefined behaviour with destroyed sessions

## [1.4.2] - 14-02-2018
### Fixes
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ option (old_toolchain "Is old toolchain" OFF)

set (RESIDUE_MAJOR "2")
set (RESIDUE_MINOR "3")
set (RESIDUE_PATCH "5")
set (RESIDUE_PATCH "6")
set (RESIDUE_VERSION "${RESIDUE_MAJOR}.${RESIDUE_MINOR}.${RESIDUE_PATCH}")
set (RESIDUE_NAME "Residue")

Expand Down
9 changes: 4 additions & 5 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Copyright 2017-present Muflihun Labs
Copyright 2017-present Zuhd Web Services
Copyright 2017-present @abumusamq

https://github.com/muflihun/residue/
https://muflihun.com/
https://muflihun.github.io/residue/
https://github.com/zuhd-org/residue
https://muflihun.com
https://zuhd.org

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -16,4 +16,3 @@ distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

41 changes: 21 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@

![banner]

[![Build Status](https://img.shields.io/travis/muflihun/residue/master.svg)](#build-matrix)
[![Build Status](https://img.shields.io/travis/muflihun/residue/develop.svg)](#build-matrix)
[![Version](https://img.shields.io/github/release/muflihun/residue.svg)](https://github.com/muflihun/residue/releases/latest)
[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.me/MuflihunDotCom/25)
[![Build Status](https://img.shields.io/travis/zuhd-org/residue/master.svg)](#build-matrix)
[![Build Status](https://img.shields.io/travis/zuhd-org/residue/develop.svg)](#build-matrix)
[![Version](https://img.shields.io/github/release/zuhd-org/residue.svg)](https://github.com/zuhd-org/residue/releases/latest)

# Overview
[![Donate](https://muflihun.github.io/donate.png?v2)](https://www.paypal.me/zuhd/25)

# Overview
Residue is an effort to standardize application logging by implementing simple logging API, making it easily configurable, build-in configurable log rotators, simple way to format your log messages according to need of your application and most of all language-independent.

[![overview]](/docs/OVERVIEW.md)
Expand All @@ -21,14 +22,14 @@ Currently, there are two ways to do this:

1. Collect log messages locally and have a scheduled task to synchronize all the log files to a remote system.
2. Using real-time message forwarding protocols.

First one has many drawbacks especially when you need to debug a remote application in real-time. Also, transferring files in bulk can be heavy on network and possibly slow.

Second one is what residue client does. It delievers log messages in real-time to the (residue) server.
Second one is what residue client does. It delievers log messages in real-time to the (residue) server.

Residue is fully configurable and supports high-level security, compression and asyncronous operations. It uses [Easylogging++](https://github.com/muflihun/easyloggingpp) under the hood, that itself is a feature-rich library.

You can choose to integrate similar solutions like [`rsyslog`](https://github.com/rsyslog/rsyslog) however residue has a lot of other built-in features that other solutions may lack, like built-in log rotation, bulk message forwarding etc. See [Features](#features) section for details.
You can choose to integrate similar solutions like [`rsyslog`](https://github.com/rsyslog/rsyslog) however residue has a lot of other built-in features that other solutions may lack, like built-in log rotation, bulk message forwarding etc. See [Features](#features) section for details.

# Features
Some of the notable features are listed below
Expand Down Expand Up @@ -58,19 +59,19 @@ We're also actively working on client libraries for residue in other languages.

| Branch | Platform | Build Status |
| -------- |:------------:|:------------:|
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/develop/1)](https://travis-ci.org/muflihun/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/develop/2)](https://travis-ci.org/muflihun/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/develop/3)](https://travis-ci.org/muflihun/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/develop/4)](https://travis-ci.org/muflihun/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/develop/5)](https://travis-ci.org/muflihun/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/master/1)](https://travis-ci.org/muflihun/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/master/2)](https://travis-ci.org/muflihun/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/master/3)](https://travis-ci.org/muflihun/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/master/4)](https://travis-ci.org/muflihun/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/muflihun/residue/branches/master/5)](https://travis-ci.org/muflihun/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/develop/1)](https://travis-ci.org/zuhd-org/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/develop/2)](https://travis-ci.org/zuhd-org/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/develop/3)](https://travis-ci.org/zuhd-org/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/develop/4)](https://travis-ci.org/zuhd-org/residue) |
| `develop` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/develop/5)](https://travis-ci.org/zuhd-org/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `clang++` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/master/1)](https://travis-ci.org/zuhd-org/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-4.9` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/master/2)](https://travis-ci.org/zuhd-org/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-5` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/master/3)](https://travis-ci.org/zuhd-org/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-6` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/master/4)](https://travis-ci.org/zuhd-org/residue) |
| `master` | GNU/Linux 4.4 / Ubuntu 4.8.4 64-bit / `g++-7` | [![Build Status](https://travis-matrix-badges.herokuapp.com/repos/zuhd-org/residue/branches/master/5)](https://travis-ci.org/zuhd-org/residue) |

# License
Please see [LICENSE](/LICENSE) for licensing information.

[banner]: https://raw.githubusercontent.com/muflihun/residue/master/docs/Residue.png
[overview]: https://raw.githubusercontent.com/muflihun/residue/develop/docs/residue-overview.png?v2
[banner]: https://raw.githubusercontent.com/zuhd-org/residue/master/docs/Residue.png
[overview]: https://raw.githubusercontent.com/zuhd-org/residue/develop/docs/residue-overview.png?v2
7 changes: 4 additions & 3 deletions deps/easyloggingpp/LICENSE
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
The MIT License (MIT)

Copyright (c) 2012-2018 Muflihun Labs
Copyright (c) 2012-2018 Zuhd Web Services
Copyright (c) 2012-2018 @abumusamq

https://github.com/muflihun/
https://github.com/zuhd-org/
https://zuhd.org
https://muflihun.com
https://muflihun.github.io

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
23 changes: 14 additions & 9 deletions deps/easyloggingpp/easylogging++.cc
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
//
// Bismillah ar-Rahmaan ar-Raheem
//
// Easylogging++ v9.96.5
// Easylogging++ v9.96.7
// Cross-platform logging library for C++ applications
//
// Copyright (c) 2012-2018 Muflihun Labs
// Copyright (c) 2012-2018 Zuhd Web Services
// Copyright (c) 2012-2018 @abumusamq
//
// This library is released under the MIT Licence.
// https://github.com/muflihun/easyloggingpp/blob/master/LICENSE
// https://github.com/zuhd-org/easyloggingpp/blob/master/LICENSE
//
// https://github.com/muflihun/easyloggingpp
// https://muflihun.github.io/easyloggingpp
// https://zuhd.org
// http://muflihun.com
//

Expand Down Expand Up @@ -931,7 +930,7 @@ void Str::replaceFirstWithEscape(base::type::string_t& str, const base::type::st
std::size_t foundAt = base::type::string_t::npos;
while ((foundAt = str.find(replaceWhat, foundAt + 1)) != base::type::string_t::npos) {
if (foundAt > 0 && str[foundAt - 1] == base::consts::kFormatSpecifierChar) {
str.erase(foundAt > 0 ? foundAt - 1 : 0, 1);
str.erase(foundAt - 1, 1);
++foundAt;
} else {
str.replace(foundAt, replaceWhat.length(), replaceWith);
Expand Down Expand Up @@ -1500,7 +1499,7 @@ void LogFormat::parseFromFormat(const base::type::string_t& userFormat) {
if (hasFlag(flag)) {
// If we already have flag we remove the escape chars so that '%%' is turned to '%'
// even after specifier resolution - this is because we only replaceFirst specifier
formatCopy.erase(foundAt > 0 ? foundAt - 1 : 0, 1);
formatCopy.erase(foundAt - 1, 1);
++foundAt;
}
} else {
Expand Down Expand Up @@ -2068,20 +2067,26 @@ Storage::Storage(const LogBuilderPtr& defaultLogBuilder) :
m_registeredLoggers(new base::RegisteredLoggers(defaultLogBuilder)),
m_flags(ELPP_DEFAULT_LOGGING_FLAGS),
m_vRegistry(new base::VRegistry(0, &m_flags)),

#if ELPP_ASYNC_LOGGING
m_asyncLogQueue(new base::AsyncLogQueue()),
m_asyncDispatchWorker(asyncDispatchWorker),
#endif // ELPP_ASYNC_LOGGING

m_preRollOutCallback(base::defaultPreRollOutCallback) {
// Register default logger
m_registeredLoggers->get(std::string(base::consts::kDefaultLoggerId));
// We register default logger anyway (worse case it's not going to register) just in case
m_registeredLoggers->get("default");

#if defined(ELPP_FEATURE_ALL) || defined(ELPP_FEATURE_PERFORMANCE_TRACKING)
// Register performance logger and reconfigure format
Logger* performanceLogger = m_registeredLoggers->get(std::string(base::consts::kPerformanceLoggerId));
m_registeredLoggers->get("performance");
performanceLogger->configurations()->setGlobally(ConfigurationType::Format, std::string("%datetime %level %msg"));
performanceLogger->reconfigure();
#endif // defined(ELPP_FEATURE_ALL) || defined(ELPP_FEATURE_PERFORMANCE_TRACKING)

#if defined(ELPP_SYSLOG)
// Register syslog logger and reconfigure format
Logger* sysLogLogger = m_registeredLoggers->get(std::string(base::consts::kSysLogLoggerId));
Expand Down Expand Up @@ -3097,11 +3102,11 @@ void Loggers::clearVModules(void) {
// VersionInfo

const std::string VersionInfo::version(void) {
return std::string("9.96.5");
return std::string("9.96.7");
}
/// @brief Release date of current version
const std::string VersionInfo::releaseDate(void) {
return std::string("07-09-2018 0950hrs");
return std::string("24-11-2018 0728hrs");
}

} // namespace el
22 changes: 14 additions & 8 deletions deps/easyloggingpp/easylogging++.h
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
//
// Bismillah ar-Rahmaan ar-Raheem
//
// Easylogging++ v9.96.5
// Easylogging++ v9.96.7
// Single-header only, cross-platform logging library for C++ applications
//
// Copyright (c) 2012-2018 Muflihun Labs
// Copyright (c) 2012-2018 Zuhd Web Services
// Copyright (c) 2012-2018 @abumusamq
//
// This library is released under the MIT Licence.
// https://github.com/muflihun/easyloggingpp/blob/master/LICENSE
// https://github.com/zuhd-org/easyloggingpp/blob/master/LICENSE
//
// https://github.com/muflihun/easyloggingpp
// https://muflihun.github.io/easyloggingpp
// https://zuhd.org
// http://muflihun.com
//

Expand Down Expand Up @@ -115,8 +114,13 @@
#else
# define ELPP_OS_NETBSD 0
#endif
#if defined(__EMSCRIPTEN__)
# define ELPP_OS_EMSCRIPTEN 1
#else
# define ELPP_OS_EMSCRIPTEN 0
#endif
// Unix
#if ((ELPP_OS_LINUX || ELPP_OS_MAC || ELPP_OS_FREEBSD || ELPP_OS_NETBSD || ELPP_OS_SOLARIS || ELPP_OS_AIX) && (!ELPP_OS_WINDOWS))
#if ((ELPP_OS_LINUX || ELPP_OS_MAC || ELPP_OS_FREEBSD || ELPP_OS_NETBSD || ELPP_OS_SOLARIS || ELPP_OS_AIX || ELPP_OS_EMSCRIPTEN) && (!ELPP_OS_WINDOWS))
# define ELPP_OS_UNIX 1
#else
# define ELPP_OS_UNIX 0
Expand Down Expand Up @@ -201,7 +205,7 @@ ELPP_INTERNAL_DEBUGGING_OUT_INFO << ELPP_INTERNAL_DEBUGGING_MSG(internalInfoStre
# define ELPP_INTERNAL_INFO(lvl, msg)
#endif // (defined(ELPP_DEBUG_INFO))
#if (defined(ELPP_FEATURE_ALL)) || (defined(ELPP_FEATURE_CRASH_LOG))
# if (ELPP_COMPILER_GCC && !ELPP_MINGW && !ELPP_OS_ANDROID)
# if (ELPP_COMPILER_GCC && !ELPP_MINGW && !ELPP_OS_ANDROID && !ELPP_OS_EMSCRIPTEN)
# define ELPP_STACKTRACE 1
# else
# if ELPP_COMPILER_MSVC
Expand Down Expand Up @@ -736,10 +740,12 @@ static const char* kDefaultLoggerId = ELPP_DEFAULT_L
static const char* kDefaultLoggerId = "default";
#endif

#if defined(ELPP_FEATURE_ALL) || defined(ELPP_FEATURE_PERFORMANCE_TRACKING)
#ifdef ELPP_DEFAULT_PERFORMANCE_LOGGER
static const char* kPerformanceLoggerId = ELPP_DEFAULT_PERFORMANCE_LOGGER;
#else
static const char* kPerformanceLoggerId = "performance";
#endif // ELPP_DEFAULT_PERFORMANCE_LOGGER
#endif

#if defined(ELPP_SYSLOG)
Expand Down Expand Up @@ -3766,7 +3772,7 @@ class Helpers : base::StaticClass {
return ELPP->hasCustomFormatSpecifier(formatSpecifier);
}
static inline void validateFileRolling(Logger* logger, Level level) {
if (logger == nullptr) return;
if (ELPP == nullptr || logger == nullptr) return;
logger->m_typedConfigurations->validateFileRolling(level, ELPP->preRollOutCallback());
}
};
Expand Down
6 changes: 3 additions & 3 deletions dist/npm/darwin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
"name": "residue-darwin",
"version": "2.3.5",
"description": "Residue server daemon (Darwin)",
"homepage": "https://github.com/muflihun/residue",
"author": "Muflihun Labs <[email protected]>",
"homepage": "https://github.com/zuhd-org/residue",
"author": "Zuhd Web Services <[email protected]>",
"license": "Apache-2.0",
"bin": "./residued",
"repository": {
"type": "git",
"url": "http://github.com/muflihun/residue.git"
"url": "http://github.com/zuhd-org/residue.git"
},
"files": [
"residued",
Expand Down
6 changes: 3 additions & 3 deletions dist/npm/linux/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
"name": "residue-linux",
"version": "2.3.5",
"description": "Residue server daemon (Linux)",
"homepage": "https://github.com/muflihun/residue",
"author": "Muflihun Labs <[email protected]>",
"homepage": "https://github.com/zuhd-org/residue",
"author": "Zuhd Web Services <[email protected]>",
"license": "Apache-2.0",
"bin": "./residued",
"repository": {
"type": "git",
"url": "http://github.com/muflihun/residue.git"
"url": "http://github.com/zuhd-org/residue.git"
},
"files": [
"residued",
Expand Down
3 changes: 2 additions & 1 deletion include/extensions.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// extensions.h
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/admin/admin-request-handler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// admin-request-handler.cc
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/admin/admin-request-handler.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// admin-request-handler.h
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/admin/admin-request.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// admin-request.cc
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/admin/admin-request.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// Adminrequest.h
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/cli/clients.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// clients.cc
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/cli/clients.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// clients.h
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
3 changes: 2 additions & 1 deletion src/cli/command-handler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
// command-handler.cc
// Residue
//
// Copyright 2017-present Muflihun Labs
// Copyright 2017-present Zuhd Web Services
// https://zuhd.org
//
// Author: @abumusamq
//
Expand Down
Loading

0 comments on commit d2f3284

Please sign in to comment.