devhawala / dodo

Xerox Network Services (XNS) implemented in Java
Other
13 stars 1 forks source link

Stand-Alone Print Server - Service Start Query #23

Closed ahm50menzies closed 10 months ago

ahm50menzies commented 10 months ago

Hi,

When setting up a 'stand-alone' Dodo machine dedicated to providing a print service, the service start requirements seem to differ from those described in printsvc-configuration.md

The documentation states

One single Dodo machine can provide at most one XNS print service. This can be the same "central" machine where other XNS services (Clearinghouse, Time, ... services) are provided or a separate "stand-alone" Dodo machine dedicated for the printing service.

In case of a "stand-alone" machine, the Dodo configuration should disable (not start) all other services except for the print service.

If the Dodo print service is defined as follows:

#
# configuration for PS2 server
#

# machine id
machineId = dodo-ps2

# print service
printService.name = neptune:dev:hawala
printService.outputDirectory = /mnt/XNS/prt-neptune
printService.paperSizes = a4
printService.disassembleIp = false
#
# if IPPROC.PS is available:
printService.ip2PsProcFilename = /mnt/XNS/prt-neptune/res/IPPROC.PS

# postprocessing of generated PostScript files:
printService.psPostprocessor = /mnt/XNS/prt-neptune/res/postprocess-ps.sh

# Services
startEchoService = false
startTimeService = false
startRipService = false
startChsAndAuthServices = false
startBootService = false

then the following error is generated:

user@eddie:~$ /mnt/XNS/run-ps2server.sh
#----#     clientBindToSocket( sockNo = 16383, listener = dev.hawala.xns.network.NetMachine$PexRequestHandler@30dae81 ): socket bound
#----#     clientBindToSocket( sockNo = 16383, listener = dev.hawala.xns.network.NetMachine$PexRequestHandler@30dae81 ): listener started
#----# opening connection to hub
####### Printing3, supported paperSizes: a4
####### Printing3, using ip-to-ps proc: /mnt/XNS/prt-neptune/res/IPPROC.PS
####### Printing3, patched ip-to-ps proc for Xerox PS font usage
####### Printing3, using ps post-processor: /mnt/XNS/prt-neptune/res/postprocess-ps.sh
Exception in thread "main" java.lang.NullPointerException
    at dev.hawala.xns.level4.gap.Gap3Impl.init(Gap3Impl.java:94)
    at dev.hawala.xns.DodoServer.main(DodoServer.java:433)
[   1] received XNS packet from hub, source: [1050-10.00.BB.10.11.01:1]
[   1] remote2localPipeline -> new packet
[   1] local2machine -> theMachine.handlePacket(idp)
[   1]     handlePacket( IDP[ chksum: 0x180B len: 38 transportControl: 0 packetType: 1 [Rip] dst: 041A.FFFFFFFFFFFF.0001 src: 041A.1000BB101101.0001  ] )
[   1]     ** handlePacket(): no listener registered for target socket
[   2] received XNS packet from hub, source: [1050-10.00.BB.10.11.01:1]
[   2] remote2localPipeline -> new packet
[   2] local2machine -> theMachine.handlePacket(idp)
[   2]     handlePacket( IDP[ chksum: 0x180B len: 38 transportControl: 0 packetType: 1 [Rip] dst: 041A.FFFFFFFFFFFF.0001 src: 041A.1000BB101101.0001  ] )
[   2]     ** handlePacket(): no listener registered for target socket
[   3] received XNS packet from hub, source: [1050-10.00.BB.10.11.01:1]
[   3] remote2localPipeline -> new packet
[   3] local2machine -> theMachine.handlePacket(idp)
[   3]     handlePacket( IDP[ chksum: 0x180B len: 38 transportControl: 0 packetType: 1 [Rip] dst: 041A.FFFFFFFFFFFF.0001 src: 041A.1000BB101101.0001  ] )
[   3]     ** handlePacket(): no listener registered for target socket

Changing the Dodo configuration so startChsAndAuthServices = true runs the print service correctly, but of course Clearinghouse & Auth services are also running.

Is it possible to start just the print service without Clearinghouse & Auth services as I have not been able to identify a parameter to specify this?

Thank you.

Regards,

Adrian

devhawala commented 10 months ago

Hello Adrian,

there was a bug that the External Communication Service is always started, but as it depends on the Clearinghouse service for registering the foreign communication data, this gave us a nice NullPointerException for a print service only Dodo instance...

The new version just uploaded should resolve this and add a new configuration parameter startExternalCommunicationService: the ECS is only started if this parameter is true (default) and the clearinghouse also runs on this instance.

(as for the boot service fix: not tested, but obvious changes)

Greetings, Hans

ahm50menzies commented 10 months ago

Hi Hans,

Thank you for taking the time to resolve this.

I have tested this and my print services now start quite happily without the ChsAndAuth service.

Boot service has also been tested and is working correctly.

Many thanks for spending the time to fix these issues.

Dodo is Awesome!

Cheers,

Adrian