phax / phoss-smp

phoss SMP - a Peppol and OASIS BDXR SMP Server, CEF eDelivery compliant
129 stars 37 forks source link

Status sharing from SMP to Galaxy Uptime monitor #73

Closed clancger closed 6 years ago

clancger commented 6 years ago

According to the Galaxy team, "Typically a AP page looks like this: https://atworklogin.com:8443/oxalis/status and we parse the line, "certificate.expired: false", if it is anything else than “false” an alert is created

Is it possible to implment such a status output message in a future release?

phax commented 6 years ago

@clancger Thanks for the input, even though I think presenting this information as text/plain is not ideal. Instead I suggest to use a simple JSON format, so that it can be parsed with higher certainty. Does that sound okay?

clancger commented 6 years ago

@phax Thanks, Let me check back with Galaxy

clancger commented 6 years ago

so, here's the feedback from Hans.. We do a keyword match when checking the status of an AP, so there’s nothing that prevents you from using JSON I suppose

phax commented 6 years ago

Example output from Oxalis:

version.oxalis: 3.2.0
version.java: 1.8.0_101
oxalis.operation.mode: PRODUCTION
oxalis.pki.version: V2
oxalis.sml.hostname: 
certificate.subject: O=At Work Systems AS,CN=APP_1000000392,C=NO
certificate.issuer: CN=PEPPOL ACCESS POINT CA,O=NATIONAL IT AND TELECOM AGENCY,C=DK
certificate.expired: false
build.id: ${git.commit.id}
build.tstamp: ${git.commit.time}
phax commented 6 years ago

Here's some initial output - I think it is sufficient and does not contain sensitive information:

{
    "status.datetime": "2018-06-01T18:28:38.259Z",
    "version.smp": "5.0.6-SNAPSHOT",
    "version.java": "1.8.0_152",
    "global.debug": true,
    "global.production": false,
    "smp.backend": "sql",
    "smp.mode": "test",
    "smp.resttype": "bdxr",
    "smp.identifiertype": "bdxr",
    "smp.id": "TEST-SMP-ID1",
    "smp.writable-rest-api.enabled": true,
    "smp.sml.enabled": false,
    "smp.sml.needed": true,
    "smp.sml.url": "https://acc.edelivery.tech.ec.europa.eu/edelivery-sml/manageparticipantidentifier",
    "smp.pd.enabled": true,
    "smp.pd.auto-update": true,
    "smp.pd.hostname": "https://directory.peppol.eu",
    "smp.certificate.configuration-valid": true,
    "smp.certificate.issuer": "CN=PEPPOL SERVICE METADATA PUBLISHER TEST CA,OU=FOR TEST PURPOSES ONLY,O=NATIONAL IT AND TELECOM AGENCY,C=DK",
    "smp.certificate.subject": "CN=SMP_2000000309,O=Bundesrechenzentrum GmbH,C=AT",
    "smp.certificate.expired": false
}
phax commented 6 years ago

And here are the docs: https://github.com/phax/peppol-smp-server/wiki/Status-API