Git Product home page Git Product logo

shield's Introduction

Shield

https://retailmenot.github.io/shield/

A deployable API Gateway for your service oriented architecture.

Running From Source

  • Set up an application.conf in src/main/resources/application.conf. This file is in the .gitignore, so make sure it doesn't get checked in.

      logger.root = DEBUG
      shield {
        domain-watcher: StaticDomainWatcher
        domains: [
          {
            domain-name: "api.example.org"
            middleware-chain: []
            middleware: {}
            listeners: []
            listener-config: {}
            kvstores: {}
            ignoreExtensions: []
            log: {
              request-headers: []
              response-headers: []
            }
            upstream-weighting: {
              step-count: 10
              step-duration: 3 seconds
            }
    
            upstream-watcher: StaticUpstreamWatcher
            upstreams: [
              {"serviceType": "swagger2", "serviceLocation": "https://example.com"}
            ]
          }
        ]
      }
    
  • Run Shield

    • Execute sbt run from the command line
    • Create a new run configuration in your IDE with shield.Boot as the main class

Versioning

To set the version number of the project at build/packaging/run time, do the following:

sbt "set version := \"0.3.0\"" <task>

Building A Release

Shield relies on the SBT Native Packager plugin to create a release package. To create the release, run:

sbt clean test universal:packageBin

Documentation

All documentation should be in either this readme.md or in the /docs folder. For instructions on how to view the docs site locally, visit this GitHub article.

License

This project is licensed under the terms of the MIT license. See LICENSE.txt for the full terms.

shield's People

Contributors

sacharya1980 avatar talton-rmn 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

Watchers

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

shield's Issues

How do I use a non swagger upstream?

I've tried using "RawUpstreamService" I found in the code, which gets rid of the Exceptions from no swagger endpoints on the upstream. However the upstream never becomes healthy.

Is it necessary to setup swagger (on the upstream) endpoints for an upstream to work?

All my non Shield endpoint requests respond with a 404.

Looking at the spec, it seems only swagger(1|2) are supported as service types?
https://github.com/RetailMeNot/shield/blob/fa8e0af212bd90efea4ab26ab1f896a67c15330f/src/test/scala/shield/actors/config/upstream/S3UpstreamUpdaterSpec.scala

Did you guys have a recommended swagger plugin for ES? I was looking at this so far : https://github.com/timschlechter/swagger-for-elasticsearch Just noticed this wont work with 5.x.x so wont be using it

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.