Skip to content

Commit

Permalink
access log delivery feature
Browse files Browse the repository at this point in the history
  • Loading branch information
notmyname committed Aug 2, 2011
1 parent c9e43e0 commit 96288d7
Show file tree
Hide file tree
Showing 10 changed files with 961 additions and 207 deletions.
25 changes: 25 additions & 0 deletions bin/swift-access-log-delivery
@@ -0,0 +1,25 @@
#!/usr/bin/python
# Copyright (c) 2010-2011 OpenStack, LLC.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.

from slogging.access_log_delivery import AccessLogDeliveryDaemon
from swift.common.utils import parse_options
from swift.common.daemon import run_daemon

if __name__ == '__main__':
conf_file, options = parse_options(once=True)
run_daemon(AccessLogDeliveryDaemon, conf_file,
section_name='access-log-delivery',
log_name='access-log-delivery', **options)
19 changes: 19 additions & 0 deletions etc/access-log-delivery.conf-sample
@@ -0,0 +1,19 @@
[access-log-delivery]
swift_account = AUTH_7abbc116-8a07-4b63-819d-02715d3e0f31
# container_name = access_log_delivery_data
# proxy_server_conf = /etc/swift/proxy-server.conf
# log_facility = LOG_LOCAL0
# log_level = INFO
# lookback_hours = 120
# lookback_window = 120
# user = swift
# processed_files_object_name = processed_files.pickle.gz
# frequency = 3600
# target_container = .ACCESS_LOGS
log_source_account = AUTH_7abbc116-8a07-4b63-819d-02715d3e0f31
# log_source_container_name = log_data
# metadata_key = x-container-meta-access-log-delivery
# memcache_servers =
# worker_count = 1
# server_name = proxy-server
# working_dir = /tmp/swift
3 changes: 2 additions & 1 deletion setup.py
Expand Up @@ -42,6 +42,7 @@
install_requires=[], # removed for better compat
scripts=['bin/swift-account-stats-logger',
'bin/swift-container-stats-logger',
'bin/swift-log-stats-collector', 'bin/swift-log-uploader'
'bin/swift-log-stats-collector', 'bin/swift-log-uploader',
'bin/swift-access-log-delivery'
],
)

0 comments on commit 96288d7

Please sign in to comment.