Is there a function I can use to identify which Appian instance a process is run

Is there a function I can use to identify which Appian instance a process is running in - so that we can have different behaviour in test environments from the production environment?

OriginalPostID-204408

OriginalPostID-204408

  Discussion posts and replies are publicly visible

Parents
  • We have a rule named along the lines of isDevelopmentEnvironment, which looks something like this:

    = with(
    local!siteURL: lower(
    rule!APN_getSiteUrl()
    ),
    or(
    find(
    "dev",
    local!siteURL
    ),
    find(
    "test",
    local!siteURL
    )
    )
    )

    In case you don't have the Appian common objects installed, the rule APN_getSiteUrl just does extract(linktodocument(0, "doc"), """", "doc/")

    Obviously this relies on your environments having some element of the URL that allows you to identify the environment...
Reply
  • We have a rule named along the lines of isDevelopmentEnvironment, which looks something like this:

    = with(
    local!siteURL: lower(
    rule!APN_getSiteUrl()
    ),
    or(
    find(
    "dev",
    local!siteURL
    ),
    find(
    "test",
    local!siteURL
    )
    )
    )

    In case you don't have the Appian common objects installed, the rule APN_getSiteUrl just does extract(linktodocument(0, "doc"), """", "doc/")

    Obviously this relies on your environments having some element of the URL that allows you to identify the environment...
Children
No Data