Giter VIP home page Giter VIP logo

tysug's People

Contributors

dynom avatar yazgazan avatar

Stargazers

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

Watchers

 avatar  avatar

tysug's Issues

Change the configuration

I'm not liking YAML for configuring TySug, I'm currently considering the following formats instead:

  • HCL -- JSON with comments
  • TOML -- A more sensible YAML
  • SAN -- HCL "improved?"

TOML

Looks a bit like INI and offers a good specification. However I find it a bit too complex for TySug's use-case.

Things I don't like:

  • Certain notations aren't super obvious

Things I like:

  • Clear documentation and specification
  • Distinction between arrays and tables (hashmaps)
  • Typed arrays (types can't be mixed)
  • Native support for dates (With TZ's)
  • Freedom of indentation (usage and tabs or spaces)
  • Unique keys (keys can't be repeated)
  • Large community adoption and seems battle-tested

HCL

Things I don't like:

  • Poor documentation of specification
  • Mixed type arrays

Things I like:

  • Seems nice and simple
  • Fair community adoption
  • I like the syntax

SAN

Things I don't like:

  • Not mature and limited test coverage
  • Opinionated indentation (spaces only)

Thinks I like:

  • Simple

Dynamically update the reference lists from a storage backend

Currently the lists are configured rather statically. One use-case could be that the lists are more dynamically, backed with a centralised storage layer (e.g. Postgres / Redis, etc.).

For SQL like systems it might be desirable to write a custom query, to produce a sorted reference list. Something along the lines of:

-- MSSQL
WITH domains (domain) as (
SELECT
  LOWER(SUBSTRING([email], CHARINDEX('@', [email])+1, 999)) as domain
  FROM [users]
  WHERE email LIKE '%@%'
)
SELECT
  domain
  FROM domains
  GROUP BY domain
  HAVING COUNT(domain) > 2
  ORDER BY COUNT(domain) DESC

However, in this particular example, the output probably doesn't change that much in a running system. So the results can be cached and refreshed once per day/week or so.

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.