@ScannerSide @ServerSide @ComputeEngineSide public abstract class Server extends Object
Constructor and Description |
---|
Server() |
Modifier and Type | Method and Description |
---|---|
abstract String |
getContextPath()
Context path of web server.
|
abstract File |
getDeployDir()
Deprecated.
always
null since version 6.0. No alternatives, as plugins do not have to touch this directory. |
abstract String |
getId()
UUID identifying the installation.
|
abstract String |
getPermanentServerId()
UUID generated on demand by system administrators.
|
abstract String |
getPublicRootUrl()
Return the public root url, for instance : https://nemo.sonarqube.org.
|
abstract File |
getRootDir()
Deprecated.
in 6.0. Replaced by
ServerFileSystem.getHomeDir() |
abstract Date |
getStartedAt()
Date when server started.
|
abstract String |
getURL()
Deprecated.
since 6.5, please use
getPublicRootUrl() instead |
abstract String |
getVersion()
Non-null version of SonarQube at runtime
|
abstract boolean |
isDev()
Deprecated.
in 6.6
|
abstract boolean |
isSecured()
Deprecated.
since 5.6, use instead
HttpServletRequest.getHeader(String) and check that X-Forwarded-Proto header is set to "https". |
public Server()
public abstract String getId()
@CheckForNull public abstract String getPermanentServerId()
null
by default on fresh installations. When defined,
value does not change when server is restarted.
In the context of cluster, value is the same on all nodes.public abstract String getVersion()
public abstract Date getStartedAt()
@Deprecated public abstract File getRootDir()
ServerFileSystem.getHomeDir()
null
in scanner.@Deprecated @CheckForNull public abstract File getDeployDir()
null
since version 6.0. No alternatives, as plugins do not have to touch this directory.public abstract String getContextPath()
""
by default. When defined by
the property sonar.web.context
of conf/sonar.properties, then value starts but does
not end with slash '/'
, for instance "/sonarqube"
.public abstract String getPublicRootUrl()
CoreProperties.SERVER_BASE_URL_DEFAULT_VALUE
@Deprecated public abstract boolean isDev()
sonar.web.dev
is true
.
Since 6.6, false
is always returned.@Deprecated public abstract boolean isSecured()
HttpServletRequest.getHeader(String)
and check that X-Forwarded-Proto header is set to "https".@Deprecated public abstract String getURL()
getPublicRootUrl()
insteadCopyright © 2009–2017 SonarSource. All rights reserved.