implemented basics to use Spock as middleware