This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| fhines@ubuntu:~/swift (review/darrell_bishop/bug/1025433)$ python test/unit/common/middleware/test_proxy_logging.py | |
| Unable to find unit_test config section in /etc/swift/func_test.conf | |
| Unable to read test config /etc/swift/func_test.conf - section unit_test not found | |
| .............test/unit/common/middleware/test_proxy_logging.py:340: DeprecationWarning: BaseException.message has been deprecated as of Python 2.6 | |
| "header sent and there is content! 'l'", e.message) | |
| ...... | |
| ---------------------------------------------------------------------- | |
| Ran 19 tests in 0.006s | |
| OK |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| fhines@ubuntu:~/swift (review/david_goetz/detar)$ curl -v -X PUT -T /tmp/etc.tar.gz -H 'X-Auth-Token: AUTH_tk70b9b52ffc804ede85057bc3df0675e1' -H 'X-Extract-Archive: monkey.zip' http://127.0.0.1:8080/v1/AUTH_test/testit; echo | |
| * About to connect() to 127.0.0.1 port 8080 (#0) | |
| * Trying 127.0.0.1... connected | |
| * Connected to 127.0.0.1 (127.0.0.1) port 8080 (#0) | |
| > PUT /v1/AUTH_test/testit HTTP/1.1 | |
| > User-Agent: curl/7.19.7 (x86_64-pc-linux-gnu) libcurl/7.19.7 OpenSSL/0.9.8k zlib/1.2.3.3 libidn/1.15 | |
| > Host: 127.0.0.1:8080 | |
| > Accept: */* | |
| > X-Auth-Token: AUTH_tk70b9b52ffc804ede85057bc3df0675e1 | |
| > X-Extract-Archive: monkey.zip |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| =============================================================================== | |
| Checking on account ring... | |
| =============================================================================== | |
| [account] -> No ring change required | |
| =============================================================================== | |
| Checking on object ring... | |
| =============================================================================== | |
| --> [127.0.0.1/sdb4] weight 0.0 | target 1.0 | |
| -> ring requires change to meet target weight! | |
| --> partitions last moved 138 hours ago [2012-12-06 00:19:04] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import json | |
| from diamond import * | |
| import diamond.collector | |
| class SwiftReconCollector(diamond.collector.Collector): | |
| """ | |
| Reads swift recon cache files to collect swift recon data | |
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "io" | |
| "net/http" | |
| "os" | |
| "unsafe" | |
| "code.google.com/p/vitess/go/cache" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import os.path | |
| import sys | |
| from graphite.render.hashing import ConsistentHashRing | |
| instances = [] | |
| unwelcome_instances = [] | |
| for arg in sys.argv[1:]: | |
| unwelcome = False |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| in a file called ~/.reverseit.py: | |
| #!/usr/bin/python | |
| # -*- coding: UTF-8 -*- | |
| from sys import stdin, stdout | |
| pchars = u"abcdefghijklmnopqrstuvwxyz,.?!'()[]{}" | |
| fchars = u"ɐqɔpǝɟƃɥıɾʞlɯuodbɹsʇnʌʍxʎz'˙¿¡,)(][}{" | |
| flipper = dict(zip(pchars, fchars)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import math | |
| min_drives = 10 | |
| max_drives = 60000 | |
| replicas = 3 | |
| part_power = math.ceil(math.log(math.ceil(max_drives * 100.0 / replicas), 2)) | |
| print "part_power: %d\npartition_count: %d\napproximate per drive with %d drives: %.02f\napproximate per drive with %d drives: %.02f" % (part_power, 2**part_power, min_drives, 2**part_power * replicas / min_drives, max_drives, 2**part_power * replicas / max_drives)' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import sys | |
| import json | |
| import subprocess | |
| import salt.client | |
| error = False | |
| keycmd = "sudo salt-key -L --out json --no-color --out-indent=-1" | |
| out = subprocess.Popen(keycmd.split(), stdout=subprocess.PIPE).communicate()[0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var wg sync.WaitGroup | |
| for i := 0; i < 200; i++ { | |
| wg.Add(1) | |
| go blastSwift("images", token, url, &wg) | |
| } | |
| fmt.Println("Waiting on survivors") | |
| wg.Wait() |