summaryrefslogtreecommitdiff
path: root/httpd
Commit message (Collapse)AuthorAgeFilesLines
* Add V3 JSON Home support to GET /Brant Knudson2014-09-101-3/+2
| | | | | | | | | | | The server wasn't returning a JSON Home response for GET / when the Accept header is `application/json-home`. By returning the V3 JSON Home response for GET / a V3 client that supports JSON Home can GET either /v3 or / and use the response. The identity API should be able to be set to /. Closes-Bug: #1366589 Change-Id: I3191a85acf9d2f582f6b48a164cf5ac2bf84a8cf
* Use oslo.i18nBrant Knudson2014-07-131-5/+7
| | | | | | | | | | Keystone was using the I18N functions from oslo-incubator. With this change, Keystone uses the new oslo.i18n library. The tests were adapted to not use internal symbols because these are subject to change. Change-Id: I1b13fcc630952695424fccd91bcd157d702851f1
* Isolate backend loadingJamie Lennox2014-04-161-2/+2
| | | | | | | | | | | | | | | | Pecan uses thread local storage and so if we combine pecan and eventlet we need to make sure that eventlet is monkey patched before pecan is first loaded. To keep the paste.ini file untouched we need to keep the app creation in service.py but we can't load that from keystone-all because it has pecan in it. So we create a new file that can be safely imported before pecan is loaded. Change-Id: If7abf1db9859d66c06f7f223056c106292f256fa blueprint: keystone-pecan
* Enable lazy translations in httpd/keystone.pyDavid Stanek2014-03-261-0/+7
| | | | | | | | This allows strings being returned in an HTTP response to be translated into the language specified in the HTTP requests headers. Closes-bug: #1297922 Change-Id: I8a671277f861075deddd1ee4cf5daca62a43fff7
* Uses explicit imports for _Ilya Pekelny2014-03-181-7/+0
| | | | | | | | | | | | | Previously `_` was monkeypatched in tests/core.py and bin/keystone-*. This meant that if a developer was not running the tests exactly as the documentation described they would not work. Even importing certain modules in a interactive Python interpreter would fail unless keystone.tests was imported first. Monkeypatching was removed and explicit import for `_` was added. Co-Authored-By: David Stanek <dstanek@dstanek.com> Change-Id: I8b25b5b6d83fb873e25a8fab7686babf1d2261fa Closes-Bug: #1255518
* Merge "Remove vim header"Jenkins2014-02-131-2/+0
|\
| * Remove vim headerEric Guo2014-02-081-2/+0
| | | | | | | | | | | | | | | | We don't need vim modelines in each source file, it can be set in user's vimrc. Change-Id: Ie51ad62946afdf39eadcd59edaf8134ec10265c6 Closes-Bug: #1229324
* | Update the default_log_levels defaultsBrant Knudson2014-01-271-0/+1
|/ | | | | | | | | | | | | | The default for default_log_levels didn't set the log levels for some packages that Keystone uses (for example, dogpile). This caused the server to output a lot of extra logs when debug=True is used. You can get the debug output for dogpile and routes by setting default_log_levels explicitly in your keystone.conf file. Change-Id: Ib797fa7b98f0e501047b72b094d07ad204385cc6 Related-bug: #1245629 Closes-Bug: #1269987
* Don't configure on importBrant Knudson2014-01-241-0/+1
| | | | | | | | | | | | | | The keystone.config package called config.configure() at import- time. This will make it obvious that developers can't use config options at import-time because packages that do that will fail on import. Change-Id: I9306f67609d782e3f49fd43908448daf1287d51c Related-Bug: #1265108 Related-Bug: #1265670 Closes-Bug: #1269785
* Enable lazy translationBrant Knudson2014-01-141-1/+1
| | | | | | | | | | | | This change makes it so that if the user makes a request with an Accept-Language header and the response is an error where the message is translatable, then the message will be translated to the requested language (or the most appropriate language available). completes bp user-locale-api Change-Id: I5b0b02e0459a6a444baa12f8722adb829b7e152b
* Resolve oauth dependency after paste pipeline is loadedSteve Martinelli2014-01-081-0/+3
| | | | | | | | | | | | When trying to authenticate with the oauth plugin, it is possible that the dependency is not yet loaded, and as a result the user will receive an error message: "Oauth is disabled" This patch will ensure the dependency is loaded after the pipeline Fixes: bug #1264803 Change-Id: I37484bf844896b1a1b560923a8afaf99e91635e4
* Use oslo.db sessionsBrant Knudson2013-12-181-0/+4
| | | | | | | | | | | | | | | | | Keystone was using its own keystone.common.sql module for database access. oslo-incubator's db.sqlalchemy module provides the same or better functionality, so use that instead. DocImpact - The options that were in the [sql] section are deprecated and replaced by options in the [database] section. There are also several new options in this section. If database configuration is described for another project that uses oslo-incubator's db.sqlalchemy module the docs can be shared. Part of bp use-common-oslo-db-code Change-Id: I25b717d9616e9d31316441ae3671d2f86229c2bf
* Merge "Cleanup backend loading"Jenkins2013-12-151-0/+4
|\
| * Cleanup backend loadingBrant Knudson2013-12-141-0/+4
| | | | | | | | | | | | | | | | | | | | | | Backend creation was happening at import time. This changes the code so that backend creation time is controlled by calling a function. This also allows sharing the backend creation code between the server and the tests. Change-Id: Ib817aa341de510a46faa8ed0bc24ef9268fa944b
* | Refactor setup_loggingBrant Knudson2013-12-131-1/+1
|/ | | | | | | | | | | This change just cleans up the setup_logging function. It was defined in keystone.common.config and then also exported from keystone.config. Also, it had extra parameters that were unused. This takes care of a NOTE (which probably should have been a TODO) in the code. Change-Id: I1a46c8974cbd68a5bf708d253adfadc1fdb76dcd
* Disable lazy gettextMatt Odden2013-10-031-5/+1
| | | | | | | | | | | | This change disables lazy gettext functionality in Keystone, due to problems with character encoding and logging detailed in bug 1225099. It is part of a series of commits across all projects with lazy gettext enabled. Change-Id: Ia934a7df9386baf6ae8eb9ff48c24386c47ecd23 Partial-bug: 1225099
* Update keystone wsgi httpd script for oslo loggingMorgan Fainberg2013-09-021-3/+3
| | | | | | | | | | | | | | When updating to the oslo logging module, it appears that this script was missed, and erroneously still references .DEBUG, which is not available in the oslo logging module. This commit corrects the issue and updates the reference to oslo log module to not be aliased to "logging". The extra logic to set the debug on the instantiated logger is still needed to ensure all logging is seen (startup config logging, etc). fixes-bug: 1220012 Change-Id: If5b4f9f28cb9d05f914848cbdb54b10c2c5f3b2d
* Bump hacking to 0.7Zhongyue Luo2013-08-291-0/+16
| | | | | | | | | | | Fixed H102 errors Hacking 0.6 already pins down pep8, pyflakes and flake8 so they can be removed from test-requirements as they are indirect dependencies. Co-author: Joe Gordon <joe.gordon0@gmail.com> Change-Id: If7e79c70fe44d7e42a14cd6c710fd9986f995446
* Fix translate static messages in responseBrant Knudson2013-08-221-4/+10
| | | | | | | | | | | Messages created statically (during import) were not being translated in responses when the Accept-Language header was used to set the expected language in the response. The static messages were being created before the _ built-in had been installed by gettextutils.install(). Change-Id: Ie56b1d3a836bc5f2262d7af68f803a08ebdf016f Resolves-Bug: #1215192
* remove refs to keystone.common.loggingDolph Mathews2013-08-191-1/+1
| | | | | | | | | | A couple references to this module were missed, and a few new ones were created while it was in the process of being deprecated. This change removes outstanding references to the module. blueprint unified-logging-in-keystone Change-Id: I4cc7614b3f74caaec9dfa100202d9d6db4ebfc36
* Add support for API message localizationBrant Knudson2013-08-141-1/+4
| | | | | | | | | | | | | | | | Add support for doing language resolution for a request, based on the Accept-Language HTTP header. Using the lazy gettext functionality from oslo gettextutils, it is possible to use the resolved language to translate an exception message to the user requested language and return that translation from the API. Co-authored-by: Luis A. Garcia <luis@linux.vnet.ibm.com> Co-authored-by: Mathew Odden <mrodden@us.ibm.com> Implements bp user-locale-api Change-Id: Id8e92a42039d2f0b01d5c2dada733d068b2bdfeb
* Install locales for httpd.Haneef Ali2013-07-011-0/+3
| | | | Change-Id: Ia5886b98070f3e3b2df4e94bf2a3db7c57bf870e
* Add 'application' to keystone.py for WSGILance Bragstad2013-06-291-1/+5
| | | | | | | This adds WSGI application to keystone/httpd/keystone.py, fixing bug 1194494. Change-Id: I921fe1332dc9dd25e917f02f583b5b597cf35c26
* Merge "Initialize logging from HTTPD."Jenkins2013-06-231-0/+1
|\
| * Initialize logging from HTTPD.Jamie Lennox2013-06-121-0/+1
| | | | | | | | | | | | Fixes bug 1190324 Change-Id: I6031c26c4917bd526c5918d815bff3bd060301c8
* | Isolate eventlet code into environment.Jamie Lennox2013-06-181-0/+2
|/ | | | | | | | | | | | | | | | | | The environment module will be configured once, during code initialization. Subsequently all other possibly-evented modules will retrieve from environment and transparently obtain either the eventlet or standard library modules. If eventlet, httplib, subprocess or other environment dependant module is referenced outside of the environment module it should be considered a bug. The changes to tests are required to ensure that test is imported first to setup the environment. Hopefully these can all be replaced with an __init__.py in a post-nose keystone. Implements: blueprint extract-eventlet Change-Id: Icacd6f2ee0906ac5d303777c1f87a184f38283bf
* separate paste-deploy configuration from parametersAlan Pevec2013-05-262-6/+2
| | | | | | | | | | | | PasteDeploy configuration contains class names which might change between releases. Keeping it separate from user-configurable parameters allows deployers to move paste-deploy ini file out of configuration directory to a place where it can be safely overwritten on updates e.g. under /usr/share/ DocImpact Change-Id: I9292ca6226c8430b93565dedd45cc842742a23e2
* imports not in alphabetical order (flake8 H306)Dolph Mathews2013-05-241-1/+1
| | | | Change-Id: I0f6c5fc27b0bb2da553e9345a8ac4949ce46e685
* Various pep8 fixes for keystone.Dan Prince2012-11-091-1/+1
| | | | Change-Id: Id94b76d30658e75a805301b1c30b1aa28138b823
* Fix wsgi config file access for HTTPDAdam Young2012-09-141-2/+2
| | | | | | Bug 1051081 Change-Id: Ie1690c9b1b98ed3f5a78d935878369b7520b35c9
* pep8 1.3.3 cleanupJoe Heck2012-08-241-2/+0
| | | | | | removing unused imports Change-Id: I0472fd074bbe0b2ec07f1548f3930df339523465
* Files for Apache-HTTPDAdam Young2012-07-163-0/+33
files required for running Keystone in Apache-HTTPD and instructions to set it up Change-Id: Ib3fdf873ea3816186e6bb63307028ba3aa2edaa9