Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Content Layout Macro

UI Text Box
sizemedium
typeinfo

Last Log for Confluence comes with a

REST API with the following functions:

View Log Files

dedicated REST API.

A REST API is an API (Application Programming Interface) that conforms to the Representational State Transfer architecture. With a REST API programmers can easily and quickly use the functionality of the app through external scripts or programs. The API serves as an intermediate connector, allowing external programs to interface with the app and to pull data from it.

There are no limits to your creativity as a programmer! Write whichever scripts you need and let them interact directly with Last Log for Confluence to streamline your operations as a Confluence administrator.

The following features can be used through the API:

  • View all log files: Find the log files you want to view faster than in the graphical interface - specify various parameters and get exactly the output you need.
  • View thread dump: If you are a Confluence system administrator, you can quickly access the current thread dump by invoking the API.
  • Kill a thread: With great power comes great responsibility - Confluence system administrators can even kill a thread through the API.
UI Expand
titleView log files

The REST API enables you to quickly view specific log files by inserting parameters in the URL. The output is similar to executing an advanced search in the graphical interface.

For example, you can include or exclude a certain search query string, search for regex expressions, reverse the output, limit the output to a certain amount of maximum entries or make your query case insensitive.

UI Text Box
typenote

This feature is only available for Confluence administrators and system administrators!

List all available log files:

Code Block
NoteOnly for admins
<base>/rest/lastlog/1.0/log
List all available log filesmaxEntries:

View a specific log file

Code Block
<base>/rest/lastlog/1.0/log/{filename}
  • View log file {filename}
  • Parameter:

    Parameters

    Parameter  nameInput
    maxEntries
    Number of lines (
    Integer
    integer)
    reverse
    :
    Invert order of output (boolean)
    query
    :
    Search string (
    String
    string)
    regex
    :
    Search by regex (boolean)
    exclude
    :
    Exclude search string (
    String
    string)
    casesensitive
    :
    Search case
    sensitiv
    sensitive (boolean)

    An example link can be found on the log page. After executing any custom search a link next to the search button will be displayed (Show only log). 

    Thread Dump

    UI Text Box
    typetip

    Use this example to configure your API call.

    Code Block
    titleExample
    <base>/rest/lastlog/1.0/log/atlassian-confluence.log?query=&maxEntries=500&exclude=&reverse=false&regex=false&casesensitive=false
    UI Expand
    titleShow thread dump

    With the REST API you can easily view the current thread dump without having to use the graphical interface of your Confluence instance.

    UI Text Box
    typenote

    This feature is only available for Confluence system administrators!

    Code Block
    Note Only for sysadmins
    <base>/rest/lastlog/1.0/threads
  • Show Thread Dump
  • Kill a thread

    UI Expand
    titleKill a thread

    By using the REST API, you can directly kill a specific thread that is currently running in your Confluence instance.

    This feature can be useful if you're seeking to finish a process which is taking up too many resources in order to improve performance. Sometimes it is also necessary to kill a thread that is stuck or causes problems in your instance.

    UI Text Box
    typenote

    This feature is only available for Confluence administrators!

    UI Text Box
    typewarning

    Be careful when killing threads. Killing the wrong thread can seriously harm your Confluence instance!

    Code Block
    WarningOnly for sysadmins. To be used with ultimate care! Killing a thread might result in a broken instance!
    <base>/rest/lastlog/1.0/threads/kill/{id}
  • Kill Thread with ID {id}
  • CSS Stylesheet
    #tocContainer {
    margin-right: 15px; 
    position: fixed;
    right: 0;
    top: 160px;
    width: 23%;
    z-index: 1;
    }
    
    
    Div
    styleline-height: 150%;
    idtocContainer
    Panel
    borderColor#333f48
    bgColor#FFFFFF
    titleColor#eeeeee
    borderWidth1
    titleBGColor#333f48
    borderStylesolid
    titleOn this page

    Table of Contents
    maxLevel2
    indent20px
    classp


    Excerpt Include
    DECADIS:Contact support
    DECADIS:Contact support
    nopaneltrue

    Related Topics

  • Get started
  • Support
  • Version History