Giter VIP home page Giter VIP logo

heliumlogger's Introduction

Kitura

A Swift Web Framework and HTTP Server

Docs Build Status - Master macOS Linux Apache 2 codecov codebeat badge Slack Status

Summary

Kitura is a web framework and web server that is created for web services written in Swift. For more information, visit www.kitura.dev.

Table of Contents

Features

  • URL routing (e.g., GET, POST, PUT, DELETE, PATCH)
  • Codable routing
  • URL parameters
  • Static file serving
  • FastCGI support
  • SSL/TLS support
  • Pluggable middleware

Getting Started

Visit https://www.kitura.dev for a Getting Started guide, tutorials, and API reference documentation.

Contributing to Kitura

All improvements to Kitura are very welcome! Here's how to get started with developing Kitura itself.

  1. Clone this repository.

$ git clone https://github.com/Kitura/Kitura

  1. Build and run tests.

$ swift test

You can find more info on contributing to Kitura in our contributing guidelines.

Notes

  • Swift-NIO is now the default network engine via the Kitura-NIO package. If for some reason you require the old Kitura-net package, you can still enable it by setting an environment variable KITURA_NIO=0 during build.
  • Most Kitura packages have been updated to require at least Swift 5.2 in order to maintain backward compatibility.

Community

We love to talk server-side Swift, and Kitura. Join our Slack to meet the team!

heliumlogger's People

Contributors

andrew-lees11 avatar bdhernand avatar carlbrown avatar dannys42 avatar dfirsht avatar djones6 avatar helenmasters avatar ianpartridge avatar kweinmeister avatar kyemaloy97 avatar mamabusi avatar mbarnach avatar na-gupta avatar naithar avatar nikitasullivan avatar quanvo87 avatar rfdickerson avatar rob-deans avatar rolivieri avatar shihabmehboob avatar shmuelk avatar swiftdevops avatar tkhuran avatar vadimeisenbergibm avatar wlisac avatar youming-lin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

heliumlogger's Issues

PackageDescription API v3 deprecation warning

Compilation results in a warning from the compiler:

warning: PackageDescription API v3 is deprecated and will be removed in the future;

Swift Version: 4.1
Platform: macOS 10.14 Mojave
HeliumLogger Version: 1.7.1

feature: log swift queue name

In an app using multiple dispatch queues it may be worth logging current queue with every message.

Would you be willing to accept a PR if I consider adding this support? I am using HeliumLogger in multiple server side swift projects and would be willing to open a PR.

thanks for great and simple component...

Set log file path

How can I add logging settings like setting log file path limiting the size of log file path similar to winston logger for nodejs.

how to use your module in project?

Hello developers. i realy can't found tutorials how to use (import in to project in xcode for example)your module or other modules from IBM Package Manager. i try to use founded here https://swiftpkgs.ng.bluemix.net/package/IBM-Swift/HeliumLogger in IBM Sandbox, but there only errors && crush :(. for example this link taken from IBM sandbox
https://swiftlang.ng.bluemix.net/#/repl?gitPackage=https:%2F%2Fgithub.com%2FIBM-Swift%2FHeliumLogger-Sample&swiftVersion=latest

Thanx for reply

Ability to optionally turn off code coloring

Running the HeliumLogger sample in the Sandbox yields the output below. It would be nice if there is a programmatic way to turn off the code coloring, so that it looks more presentable.

�[0;39m VERBOSE: HeliumLogger_Sample main.swift line 23 - This is a verbose log message. �[0;39m
�[0;39m INFO: HeliumLogger_Sample main.swift line 25 - This is an informational log message. �[0;39m
�[0;33m WARNING: HeliumLogger_Sample main.swift line 27 - This is a warning. �[0;39m
�[0;31m ERROR: HeliumLogger_Sample main.swift line 29 - This is an error. �[0;39m
�[0;39m DEBUG: HeliumLogger_Sample main.swift line 31 - This is a debug message. �[0;39m
�[0;39m INFO: no func main.swift line 34 - This a dynamic message �[0;39m

Dependencies

Quick info, LoggerAPI latest release is 5, I noticed you still force here for .4 version

import LoggerAPI is required too

The usage example:

import HeliumLogger
Log.logger = HeliumLogger()
Log.verbose("This is a log message.")

doesn't actually compile.

import LoggerAPI

is required too. Can we remove the requirement to import LoggerAPI?

Document log output (in readme)

not sure if i missed it, but i had to read through the code to find out where HeliumLogger logs to.

it is very nice that this is just a lightweight logger to stdout. would be great if it could be stated in the readme.

Set log file path

How can I add logging settings like setting log file path limiting the size of log file path similar to winston logger for nodejs?

Error when building on Ubuntu 16.10 with Swift 3.0.2

Hi,
I tried to compile a simple hello world program using HeliumLogger and the swift compiler failed to compile due to an error with HeliumLogger.

Cheers,
Joe

.Package(url: "https://github.com/IBM-Swift/HeliumLogger.git", majorVersion: 1, minor: 6)

Here is the output:

Compile Swift Module 'SSLService' (1 sources)
Compile Swift Module 'HeliumLogger' (2 sources)
/home/user/hello-api/.build/checkouts/HeliumLogger.git-7972212279880105712/Sources/HeliumLogger/HeliumLogger.swift:116:39: error: use of undeclared type 'RegularExpression'
typealias RegularExpressionType = RegularExpression

^~~~~~~~~~~~~~~~~
/home/user/hello-api/.build/checkouts/HeliumLogger.git-7972212279880105712/Sources/HeliumLogger/HeliumLogger.swift:121:24: error: could not infer type for 'tokenRegex'
private static var tokenRegex: RegularExpressionType? = {

^
/home/user/hello-api/.build/checkouts/HeliumLogger.git-7972212279880105712/Sources/HeliumLogger/HeliumLogger.swift:116:39: error: use of undeclared type 'RegularExpression'
typealias RegularExpressionType = RegularExpression

^~~~~~~~~~~~~~~~~

JSON output

It would be great to support JSON formatted output, compatible with e.g. ElasticSearch / Kibana.

fail to staging swift application with latest 1.7.0 version

When running with the swift application https://github.com/IBM-Bluemix/Kitura-Starter, it is fine with HeliumLogger 1.6.x version.

But if I use majorVersion directly,
.Package(url: "https://github.com/IBM-Swift/HeliumLogger.git" , majorVersion: 1), then staging failed.

   Cloning https://github.com/IBM-Swift/HeliumLogger.git
   HEAD is now at 9b310ce IBM-Swift/Kitura#1047 Swift 3.1 changes

swift-build: error: The dependency graph could not be satisfied (https://github.com/IBM-Swift/LoggerAPI.git)
Failed to compile droplet
Exit status 223
Staging failed: Exited with status 223
Destroying container
Resolved version: 1.7.0
Successfully destroyed container

README does not describe how to set LOG_LEVEL when using with Swift-log

I am using the HeliumStreamLogger with Swift-log Logging. I followed the README and used LoggingSystem.bootstrap(myStreamlogger.makeLogHandler).
The LogHandler created from the above has a hard-coded .info level and it took me a long time to work out how to change it. Maybe there are easier ways, but the following code works and I think it should be included in the README.

var handler = myStreamLogger.makeHandler(label: "StreamLogger")
handler.logLevel = .debug
LoggingSystem.bootstrap({ name in {return handler})

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.