Administration

JMX Interfaces

All Sophora components support JMX. The JMX interface provides information about each component's state and allows for administrative actions.

Sophora Server

Configuration

Monitoring has to be enabled in the sophora.properties file before you can access the information as described here. The following snippet from the sophora.properties file shows how to activate JMX monitoring with access control:

sophora.rmi.servicePort=1198
sophora.rmi.registryPort=1199
 
sophora.jmx.enabled=true
sophora.jmx.username=admin
sophora.jmx.password=admin

With this configuration, the Sophora Server can be accessed using the following JMX connection string:

service:jmx:rmi://<HOST>:1198/jndi/rmi://<HOST>:1199/server

The following image shows the connection settings dialog from VisualVM:

+++
+++ (Image: subshell/CC BY)

Available MBeans

JMX-BeanJMX-Attribute or JMX-MethodDescription
com.subshell.sophora:name=
AccessManager
CheckForIncorrectLoginsControls, if incorrect login requests are counted. To many incorrect login requests lead to the locking of accounts.
 EnableUserLoginWhen set to false, normal users (users without the admin flag in any role) can not login to the server. Users who are already logged in remain on the server.
com.subshell.sophora:name=
ArchiveWorker
AddingToQueueDocuments are added to the archive worker queue, when set to true.
 ArchivingThe worker is enabled, when set to true.
CheckAllDocumentsForOldVersionsIf true will actively search for documents that need to be processed
 CurrentDocumentUuidThe uuid of the current document
DelayDelay in ms between the archiving of versions
 DeleteOldVersionsAfterDaysVersions in the archive repository which are older than this value are deleted
DocumentsWithManyVersionsInArchiveA CSV formatted list of documents that have a very large number of versions in the archive repository.
DocumentsWithManyVersionsInMainRepositoryA CSV formatted list of documents that have a very large number of versions in the main repository.
 MaxVersionsToRetainnumber of versions remaining in the main repository
PreserveNumberOfVersionsInArchiveRepositoryThe number of versions that should not be removed from the archive.
 QueueUUID of documents waiting to be processed by the archive worker
 QueueSizeNumber of documents in the queue
 RemainingVersionsInBatchOfCurrentDocumentRemaining number of versions of the current document
 TotalVersionsInBatchOfCurrentDocumentNumber of versions of the current document
 VersionsBatchSizemaximum number of versions processed in one operation
createNewDocumentForVersions(UUID)Distributes the versions in the archive across another document to reduce the number of versions per node in the archive.
addToQueue(UUID, int)Adds the document with the UUID to the ArchiveWorker queue with the specified number of versions to keep in the repository.
addToQueue(UUID)Adds the document with the UUID to the ArchiveWorker queue.
startArchival()Starts the archival of documents.
stopArchival()Stops the archival of documents.
getVersionHistorySizeInMainRepositry(UUID)Returns the number of versions the document with the given UUID has in the main repository.
getVersionHistorySizeInArchiveRepository(UUID)Returns the number of versions the document with the given UUID has in the archive repository.
clearQueue()Clears the ArchiveWorker's queue.
startAddingToQueue()Starts adding documents to the queue.
stopAddingToQueue()Stops adding documents to the queue.
com.subshell.sophora:name=
ContentManager
ApiVersionVersion of the Sophora api in the server
 DocumentTypeStatisticsNumber of documents in the repository per type (document which are marked as deleted are included)
 LockedDocumentCountNumber of currently locked documents
 LoggedInUsersList of currently logged in users
 ProfilerSummaryStatistic for every api call.
 ReplicationModeMode in which the server was started (NONE, MASTER, SLAVE STAGINGSLAVE)
 ServerVersionVersion of the server software
com.subshell.sophora:name=
DeletedDocumentsWorker
BlockSizeNumber of documents that are collected for removal in each run
 DeletingDocumentsThe deleted worker is enabled when set to true.
Note: The DeletedDocumentsWorker will only be actually active on Sophora Primary Servers.
 MinimumAgeDaysNumber of days before a document in the trash is removed completely
com.subshell.sophora:name=
LifeCycle
stop()shut down the server
 stopStaging()Only applicable on Staging Servers: disconnects the Staging Server from the Sophora Primary Server. The Staging Servers do not receive documents from the Sophora Primary Server.
 startStaging()Only applicable on Staging Servers: reconnects the Staging Server with the Sophora Primary Server. A sync request is send to the Sophora Primary Server.
 startArchival() / stopArchival()Start and stop the archive worker.
com.subshell.sophora:name=
Scripting
DocumentChangeListenerScriptsInformation about all server scripts of type DocumentChangeListener
 EventScriptsInformation about all server scripts of type EventScript
 RegisteredScriptsCountNumber of server scripts
 TimingActionScriptsInformation about all server scripts of type TimingAction
 ValidationScriptsInformation about all server scripts of type ValidationScript
com.subshell.sophora:moduleName=
cron,name=CronManager
AutoOfflineJobRepeatIntervalRepeat interval in milliseconds for the job which put documents automatically offline
 AutoPublishJobRepeatIntervalRepeat interval in milliseconds for the job which publish documents automatically
 DeletedDocumentsWorkerJobCronExpressionCron expression which controls the execution of the deleted document worker
 DocumentTimingActionsJobCronExpressionCron expression which controls the execution of timing action scripts
net.sf.ehcache:type=
CacheConfiguration,
CacheManager=Cachemaster,name=*
 Configuration of the EHCache
org.apache.activemq:BrokerName=
embedded,Type=Broker
 JMS-Broker (only applicable in Sophora Primary Server)
 MemoryPercentUsageAmount of used memory
org.apache.activemq:BrokerName=
embedded,Type=Subscription,
persistentMode=Non-Durable,
destinationType=Topic,
destinationName=
com.subshell.sophora.staging,
clientId=*
 Information about all currently connected staging Staging Servers
org.apache.activemq:BrokerName=
embedded,Type=Subscription,
persistentMode=Non-Durable,
destinationType=Queue,
destinationName=*
 Information about all configured replication queues

Scripting

The Scripting bean shows information about registered Server scripts. This is an MXBean, i.e., information about scripts is returned as open data types from the javax.management.openmbean package.

Attributes of the Scripting bean
NameTypeDescription
DocumentChangeListenerScriptsCompositeData arrayInformation about IScriptDocumentChangeListener scripts.
EventScriptsCompositeData arrayInformation about IEventScript scripts.
RegisteredScriptsCountintNumber of registered scripts.
TimingActionScriptsCompositeData arrayInformation about ITimingActionScript scripts.
ValidationScriptsCompositeData arrayInformation about IValidationScript scripts.

The node of each script contains the following attributes:

NameTypeDescriptionScript type
nameStringName of the scriptAll
scriptDocumentUuidStringUUID of the document with the script source.All
scriptDocumentIdStringSophora-ID of the document with the script source.All
typeStringType of the script.All
executionsCompositeData arrayList of script executions.All except IValidationScript.
lastExecutionCompositeData arrayThe most recent execution of the script.All except IValidationScript.

The node about a script execution contains the following attributes:

NameTypeDescriptionScript type
startDateStringThe time and date when the script execution started.All
durationMslongThe duration of the script execution in milliseconds.All
exceptionTraceStringThe stack trace of any exception that occurred during the script execution.All
processedEventStringA string representation of the processed event.IEventScript
changedDocumentUuidStringThe UUID of the changed documentIScriptDocumentChangeListener
stateChangeStringThe state change of the document.IScriptDocumentChangeListener
processedDocumentUuidStringThe UUID of the processed document.ITimingActionScript

Delivery-Tomcat

JMX-BeanJMX-Attribute or JMX-MethodDescription
com.subshell.sophora:name=
AsyncCacheRegistry
SizeCurrent queue size. Cache entries are stored in the asynchronous cache registry before they are stored in the derby cache database.
com.subshell.sophora:name=
CacheRegistry
getCacheFileEntriesByContentKey()Get all registered files related to a document uuid, a structure node uuid or cache key
 getCacheFileEntryCountByContentKey()Get number of files related to a document uuid, a structure node uuid or cache key
 getCacheFileEntriesByResource()Get all registered files related to a resource, e.g. jsp file.
 getCacheFileEntriyCountByResource()Get number of files related to a resource, e.g. jsp file.
 getContentKeysWithMostDependencies()Get the content keys (document uuid, structure node uuid or cache key) which are related to the largest numbers of cached files
 getResourceWithMostDependencies()Get the resources which are related to the largest numbers of cached files
com.subshell.sophora:name=
CronManagerCacheCleanup
DbCleanupEnabledControls the job which removes entries from the cache database which no longer exist
 FilesystemCleanupEnabledControls the job which removes files from the htdocs cache which are not registered in the cache database
com.subshell.sophora:name=
DeliveryProfiler
AvgDurationPerMinuteAverage duration in milliseconds of all generations in the last 60 seconds
 GenerationsPerMinuteNumber of generations in the last 60 seconds
 MaxDurationInMinuteMaximum duration in milliseconds of all generations in the last 60 seconds
 MinDurationInMinuteMinimum duration in milliseconds of all generations in the last 60 seconds
com.subshell.sophora:name=
PregenerationQueue
SizeNumber of entries in the pre-generation queue
 SizePriorityMapNumber of entries in the pre-generation queue by priority
com.subshell.sophora:name=
RemovalQueue
SizeNumber of entries in the removal queue
 SizePriorityMapNumber of entries in the removal queue by priority
com.subshell.sophora:name=
RemovalInterceptor
LimitLimits which controls the priority of removal jobs
com.subshell.sophora:name=
SophoraIdIgnoreList
AllIgnoredSophoraIdsList of sophora ids which are currently ignored. Requesting an url which a Sophora id from this list results in a 404 error
com.subshell.sophora:name=
Timer
 Controls different periodic jobs in the delivery

Importer

JMX-BeanJMX-Attribute or JMX-MethodDescription
com.subshell.sophora.
importer:name=
importerinstance1
AverageImportDuration*Average duration in milliseconds for different time
ranges (5 minutes, 1 hour, 6 hours) and different types
of imports (all, failed, successful). The following Attributes/Operations are available:
double getAverageImportDurationByTimeAnd
Success(int calendarField, int amount, boolean successfulImports, boolean failedImports);
double getAverageImportDurationByCountAnd
Success(int count, boolean successfulImports,
boolean failedImports);
double getAverageImportDurationByTime
(int calendarField, int amount);
double getAverageImportDurationByCount
(int count);
double getAverageImportDurationOfLastTenImports();
double getAverageImportDurationInLastFiveMinutes();
double getAverageImportDurationInLastHour();
double getAverageImportDurationInLast6Hours();
double getAverageImportDurationOfSuccesfulImports
ByTime (int calendarField, int amount);
double getAverageImportDurationOfSuccesfulImports
ByCount(int count);
double getAverageImportDurationOfSuccesfulImports
OfLastTenImports();
double getAverageImportDurationOfSuccesfulImports
InLastFiveMinutes();
double getAverageImportDurationOfSuccesfulImports
InLastHour();
double getAverageImportDurationOfSuccesfulImports
InLast6Hours();
double getAverageImportDurationOfFailedImports
ByTime(int calendarField, int amount);
double getAverageImportDurationOfFailedImports
ByCount(int count);
double getAverageImportDurationOfFailedImports
OfLastTenImports();
double getAverageImportDurationOfFailedImports
InLastFiveMinutes();
double getAverageImportDurationOfFailedImports
InLastHour();
double getAverageImportDurationOfFailedImports
InLast6Hours();

int calendarField is the int value of the related
calendar unit in the java class java.util.Calendar
(Calendar.HOUR_OF_DAY for example).
 FailedImportsInLastHourList of failed imports in the last 60 minutes
 ImportsInLastHourList of imports in the last 60 minutes
 SuccesfulImportsInLastHourList of successful import in the last 60 minutes
 LastTenFailedImportsList of 10 last failed imports
 LastTenImportsList of 10 last imports
 NumberOfFailedImportsIn*Number of failed imports in 5 minutes and 1 hour
 NumberOfImportsIn*Number of imports in 5 minutes and 1 hour
 NumberOfSuccesfulImportsInLast*Number of successful imports in 5 minutes
and 1 hour
 ImporterInstanceDisplayNameDisplay name for this importer instance
 ImporterNameName of the importer

Last modified on 9/9/20

The content of this page is licensed under the CC BY 4.0 License. Code samples are licensed under the MIT License.

Icon