krn.GetChannelGUID

This job returns the GUID of the currently open server communication channel. The channel GUID is used for unique identification of the connection in server-side logs and session tables.

This job is not listed in the official enaio® kernel engine overview. This description was reconstructed from the call code of the enaio-jobs-custom template.

1. Input Parameters

Name Type Required Description

Flags

INT

Yes

Reserved; always pass 0.

2. Output Parameters

Name Type Dependency Description

ChannelGUID

STRING

GUID of the current communication channel.

3. Return Value

(INT): 0 = job successful, otherwise error code.

4. Callback Channel (server push)

The server can push messages to a client over a callback channel — a second TCP connection with reversed roles. The client:

  1. obtains its session’s channel GUID with this job;

  2. opens a dedicated connection and registers it by sending a method response whose only parameter is ActiveChannelGUID = <channel GUID> (protocol version 40 = no digest, version 50 = with a trailing SHA-1 digest; the server mirrors the registered version);

  3. thereafter receives job calls pushed by the server and answers each with a method response (return code plus optional errors).

Two kinds of pushed job calls have been observed:

Pushed callback job Triggered by

adm.On<Message>

krn.SendMessageToClients<Message> is the Message parameter; carries Info, Text and internal origprovenience.

krn.OnRegisteredJobCall

krn.RegisterJobCall — the live job-call monitor stream.

krn.AppsEventsSubscribe (subscription to krn.SessionLogin etc.) returned 0 but delivered no events on the test server — even when the subscription was made on the same session as the callback. The working server-event stream is krn.RegisterJobCall.

5. See Also