0.3.1 • Published 9 years ago

sparc-commons v0.3.1

Weekly downloads
1
License
MIT
Repository
-
Last release
9 years ago

COMMON PACKAGE

This is the common package for all SPARC servers and products. Right now it contains the following things:

  • logger - based on log4js
  • resources - based on needle
  • utils - all the rest of the crap, including a function to load handlebar templates

The library expects to find a configuration file in the config/ folder of the root project. Following is an example of such configuration file

{
    "version": "0.2.4",
    "logging": {
        "appenders": [
            {
                "type": "console",
                "layout": {
                    "type": "pattern",
                    "pattern": "[%d %p %c] %m"
                }
            }
        ],
        "levels": {
            "[all]": "DEBUG"
        },
        "replaceConsole": "true"
    },

    //TODO: hook this up in a http making library
    "resource": {
        "test_resource": {
            "method": "get",
            "url": "http://bogus.com",
            "uri": {
                "boguservice": "bellobell",
                "boguservice2": "gallogall"
            },
            "api-params": {
                "apikey": "asdfg"
            }
        }
    }
}

For the logger configuration please refer to log4js documentation. Resources is pretty straightforward

0.3.1

9 years ago

0.3.0

9 years ago

0.2.28

9 years ago

0.2.27

9 years ago

0.2.26

9 years ago

0.2.25

9 years ago

0.2.24

9 years ago

0.2.23

9 years ago

0.2.22

9 years ago

0.2.21

9 years ago

0.2.20

9 years ago

0.2.19

9 years ago

0.2.18

9 years ago

0.2.17

9 years ago

0.2.16

9 years ago

0.2.15

9 years ago

0.2.14

9 years ago

0.2.13

9 years ago

0.2.12

9 years ago

0.2.11

9 years ago

0.2.10

9 years ago

0.2.9

9 years ago

0.2.8

9 years ago

0.2.7

9 years ago

0.2.6

9 years ago

0.2.5

9 years ago

0.2.4

9 years ago

0.2.3

9 years ago

0.2.2

9 years ago

0.2.1

9 years ago

0.2.0

9 years ago

0.1.16

9 years ago

0.1.15

9 years ago

0.1.14

10 years ago

0.1.13

10 years ago

0.1.12

10 years ago

0.1.11

10 years ago

0.1.10

10 years ago

0.1.9

10 years ago

0.1.8

10 years ago

0.1.7

10 years ago

0.1.6

10 years ago

0.1.5

10 years ago

0.1.4

10 years ago

0.1.3

10 years ago

0.1.2

10 years ago

1.0.1

10 years ago

1.0.0

10 years ago