Skip to content

Commit

Permalink
Rename SENTRY_REMOTE_URL to SENTRY_SERVERS
Browse files Browse the repository at this point in the history
  • Loading branch information
dcramer committed Oct 8, 2011
1 parent 746df9f commit 51a8b2e
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion docs/config/django.rst
Expand Up @@ -13,7 +13,7 @@ Using the Django integration is as simple as adding Raven to your installed apps
Additional settings for the client are configured using ``SENTRY_<setting name>``::

SENTRY_KEY = 'my secret key'
SENTRY_REMOTE_URLS = ['http://sentry.local/store/']
SENTRY_SERVERS = ['http://sentry.local/store/']

Integration with ``logging``
----------------------------
Expand Down
2 changes: 1 addition & 1 deletion docs/config/flask.rst
Expand Up @@ -14,4 +14,4 @@ The first thing you'll need to do is to initialize Raven under your application:
Additional settings for the client are configured using ``SENTRY_<setting name>`` in your application's configuration::

SENTRY_KEY = 'my secret key'
SENTRY_REMOTE_URLS = ['http://sentry.local/store/']
SENTRY_SERVERS = ['http://sentry.local/store/']
2 changes: 1 addition & 1 deletion docs/config/index.rst
Expand Up @@ -23,7 +23,7 @@ Settings are specified as part of the intialization of the client. For example::

from raven import Client

client = Client(remote_urls=['http://sentry.local/store/'])
client = Client(servers=['http://sentry.local/store/'])

name
~~~~
Expand Down
2 changes: 1 addition & 1 deletion docs/config/logging.rst
Expand Up @@ -9,7 +9,7 @@ Sentry supports the ability to directly tie into the ``logging`` module. To use
from raven import Client
from raven.handlers.logging import SentryHandler

client = Client(remote_urls=['http://sentry.local/store/'], key='MY SECRET KEY')
client = Client(servers=['http://sentry.local/store/'], key='MY SECRET KEY')
logger = logging.getLogger()

# ensure we havent already registered the handler
Expand Down
2 changes: 1 addition & 1 deletion docs/usage.rst
Expand Up @@ -7,7 +7,7 @@ TODO :)

from raven import Client

client = Client(remote_urls=['http://sentry.local/store/'])
client = Client(servers=['http://sentry.local/store/'])

try:
...
Expand Down
6 changes: 3 additions & 3 deletions raven/base.py
Expand Up @@ -32,7 +32,7 @@ def __init__(self, *args, **kwargs):
self.include_paths = kwargs.get('include_paths') or settings.INCLUDE_PATHS
self.exclude_paths = kwargs.get('exclude_paths') or settings.EXCLUDE_PATHS
self.remote_timeout = kwargs.get('remote_timeout') or settings.REMOTE_TIMEOUT
self.remote_urls = kwargs.get('remote_urls') or settings.REMOTE_URL
self.servers = kwargs.get('servers') or settings.SERVERS
self.name = kwargs.get('name') or settings.NAME
self.auto_log_stacks = kwargs.get('auto_log_stacks') or settings.AUTO_LOG_STACKS
self.key = kwargs.get('key') or settings.KEY
Expand Down Expand Up @@ -122,9 +122,9 @@ def send_remote(self, url, data, headers={}):

def send(self, **kwargs):
"Sends the message to the server."
if self.remote_urls:
if self.servers:
message = base64.b64encode(json.dumps(kwargs).encode('zlib'))
for url in self.remote_urls:
for url in self.servers:
timestamp = time.time()
signature = get_signature(self.key, message, timestamp)
headers = {
Expand Down
2 changes: 1 addition & 1 deletion raven/conf/defaults.py
Expand Up @@ -21,7 +21,7 @@
KEY = socket.gethostname() + '1304u13oafjadf0913j4'

# This should be the full URL to sentries store view
REMOTE_URL = None
SERVERS = None

REMOTE_TIMEOUT = 5

Expand Down
2 changes: 1 addition & 1 deletion raven/contrib/django/models.py
Expand Up @@ -55,7 +55,7 @@ def configure_settings():
if 'REMOTE_URL' in values:
v = values['REMOTE_URL']
if isinstance(v, basestring):
values['REMOTE_URL'] = [v]
values['REMOTES'] = [v]
elif not isinstance(v, (list, tuple)):
raise ValueError("Sentry setting 'REMOTE_URL' must be of type list.")

Expand Down
2 changes: 1 addition & 1 deletion raven/contrib/flask/__init__.py
Expand Up @@ -40,7 +40,7 @@ def init_app(self, app):
client = self.client_cls(
include_paths=app.config.get('SENTRY_INCLUDE_PATHS'),
exclude_paths=app.config.get('SENTRY_EXCLUDE_PATHS'),
remote_urls=app.config.get('SENTRY_REMOTE_URLS'),
servers=app.config.get('SENTRY_SERVERS'),
name=app.config.get('SENTRY_NAME'),
key=app.config.get('SENTRY_KEY'),
)
Expand Down

0 comments on commit 51a8b2e

Please sign in to comment.