-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(reports): sidecar container report generation (#779)
* feat(reports): implement/config sidecar container report generator * Add remote report status to health * extract some env var names that are referenced in multiple places * apply report generation locking only in subprocess mode * default to subprocess generation if env var unset * apply limits to report generator * error handling cleanup * test(health): include reports status in expected output * fixup! default to subprocess generation if env var unset * apply spotless formatting * fix(reports): throw expected exception type when recording not found in target * fix(reports): attempt to open local file stream before remote recording stream * suppress spurious warning * change cryostat-reports namespace after repo transfer * extract SslConfiguration variables extract subprocess report generation variable extract platform configuration variables extract max WS connections variable extract CORS origin variable extract DISABLE_SSL variable extract webserver configuration variables use Variables extract JMX connection config variables finish extracting variables fix missed import fix extracted variables in tests * remove unnecessary comment * use xpath host var * fixup! change cryostat-reports namespace after repo transfer * remove unused class * fix(reports): apply timeout when generating reports to avoid hanging requests * fix(reports): reports handlers should be unordered request ordering is handled deeper in the stack by the SubprocessReportGenerator synchronizing lock, or is handled by the configured sidecar report generator setup and its potential load balancer * fix unit tests * use latest cryostat-reports and configure for small footprint * enable JDP and JMX on cryostat-reports sidecar allows Cryostat too inspect the report generator for profiling and analysis
- Loading branch information
1 parent
175dd3c
commit 8347e65
Showing
39 changed files
with
854 additions
and
392 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
/* | ||
* Copyright The Cryostat Authors | ||
* | ||
* The Universal Permissive License (UPL), Version 1.0 | ||
* | ||
* Subject to the condition set forth below, permission is hereby granted to any | ||
* person obtaining a copy of this software, associated documentation and/or data | ||
* (collectively the "Software"), free of charge and under any and all copyright | ||
* rights in the Software, and any and all patent rights owned or freely | ||
* licensable by each licensor hereunder covering either (i) the unmodified | ||
* Software as contributed to or provided by such licensor, or (ii) the Larger | ||
* Works (as defined below), to deal in both | ||
* | ||
* (a) the Software, and | ||
* (b) any piece of software and/or hardware listed in the lrgrwrks.txt file if | ||
* one is included with the Software (each a "Larger Work" to which the Software | ||
* is contributed by such licensors), | ||
* | ||
* without restriction, including without limitation the rights to copy, create | ||
* derivative works of, display, perform, and distribute the Software and make, | ||
* use, sell, offer for sale, import, export, have made, and have sold the | ||
* Software and the Larger Work(s), and to sublicense the foregoing rights on | ||
* either these or other terms. | ||
* | ||
* This license is subject to the following condition: | ||
* The above copyright notice and either this complete permission notice or at | ||
* a minimum a reference to the UPL must be included in all copies or | ||
* substantial portions of the Software. | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
* SOFTWARE. | ||
*/ | ||
package io.cryostat.configuration; | ||
|
||
public final class Variables { | ||
private Variables() {} | ||
|
||
// jfr-datasource, cryostat-grafana-dashboard | ||
public static final String GRAFANA_DATASOURCE_ENV = "GRAFANA_DATASOURCE_URL"; | ||
public static final String GRAFANA_DASHBOARD_ENV = "GRAFANA_DASHBOARD_URL"; | ||
|
||
// report generation | ||
public static final String REPORT_GENERATOR_ENV = "CRYOSTAT_REPORT_GENERATOR"; | ||
public static final String SUBPROCESS_MAX_HEAP_ENV = "CRYOSTAT_REPORT_GENERATION_MAX_HEAP"; | ||
|
||
// SSL configuration | ||
public static final String DISABLE_SSL = "CRYOSTAT_DISABLE_SSL"; | ||
public static final String KEYSTORE_PATH_ENV = "KEYSTORE_PATH"; | ||
public static final String KEYSTORE_PASS_ENV = "KEYSTORE_PASS"; | ||
public static final String KEY_PATH_ENV = "KEY_PATH"; | ||
public static final String CERT_PATH_ENV = "CERT_PATH"; | ||
|
||
// platform configuration | ||
public static final String PLATFORM_STRATEGY_ENV_VAR = "CRYOSTAT_PLATFORM"; | ||
public static final String AUTH_MANAGER_ENV_VAR = "CRYOSTAT_AUTH_MANAGER"; | ||
|
||
// webserver configuration | ||
public static final String WEBSERVER_HOST = "CRYOSTAT_WEB_HOST"; | ||
public static final String WEBSERVER_PORT = "CRYOSTAT_WEB_PORT"; | ||
public static final String WEBSERVER_PORT_EXT = "CRYOSTAT_EXT_WEB_PORT"; | ||
public static final String WEBSERVER_SSL_PROXIED = "CRYOSTAT_SSL_PROXIED"; | ||
public static final String WEBSERVER_ALLOW_UNTRUSTED_SSL = "CRYOSTAT_ALLOW_UNTRUSTED_SSL"; | ||
public static final String MAX_CONNECTIONS_ENV_VAR = "CRYOSTAT_MAX_WS_CONNECTIONS"; | ||
public static final String ENABLE_CORS_ENV = "CRYOSTAT_CORS_ORIGIN"; | ||
|
||
// JMX connections configuration | ||
public static final String TARGET_CACHE_SIZE = "CRYOSTAT_TARGET_CACHE_SIZE"; | ||
public static final String TARGET_CACHE_TTL = "CRYOSTAT_TARGET_CACHE_TTL"; | ||
|
||
// paths configuration | ||
public static final String ARCHIVE_PATH = "CRYOSTAT_ARCHIVE_PATH"; | ||
public static final String CONFIG_PATH = "CRYOSTAT_CONFIG_PATH"; | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.