So looking more in to how defaults are handled in CA vs PVA code, I needed to change
CONFIG_ENV to set most of the EPICS_PVAS_* defaults to empty or empty string.
The empty setting allows code such as this from rsrv/caservertask.c to use
EPICS_CA_SERVER_PORT as the default for EPICS_CAS_SERVER_PORT, even if neither are
actually defined as process environment variables.
My point from this is that the envGet*ConfigParam*() routines don't
provide any insight to client code such as in iocStats() re this defaulting
of EPICS_CAS_SERVER_PORT to EPICS_CA_SERVER_PORT, which I think refutes
part of Michael's objection.
As I see it, the make variables defined in CONFIG_ENV allow user overrides
via CONFIG_SITE_ENV to set site defaults for CA environment parameters.
The only change needed to make pvAccess compatible is to use those make
variables to override the default values in pvAccess/src/pva/pv/pvaConstants.h
pvAccess wouldn't need to use the envGet*ConfigParam*() calls as it's current
code in src/server/serverContext.cpp that calls getPropertyAs*() routines
can stay as is.
So looking more in to how defaults are handled in CA vs PVA code, I needed to change SERVER_ PORT as the default for EPICS_CAS_ SERVER_ PORT, even if neither are
CONFIG_ENV to set most of the EPICS_PVAS_* defaults to empty or empty string.
The empty setting allows code such as this from rsrv/caservertask.c to use
EPICS_CA_
actually defined as process environment variables.
if ( envGetConfigPar amPtr ( &EPICS_ CAS_SERVER_ PORT ) ) { onfigParam ( &EPICS_ CAS_SERVER_ PORT,
(unsigned short) CA_SERVER_PORT ); onfigParam ( &EPICS_ CA_SERVER_ PORT,
(unsigned short) CA_SERVER_PORT );
ca_server_port = envGetInetPortC
}
else {
ca_server_port = envGetInetPortC
}
My point from this is that the envGet* ConfigParam* () routines don't SERVER_ PORT to EPICS_CA_ SERVER_ PORT, which I think refutes
provide any insight to client code such as in iocStats() re this defaulting
of EPICS_CAS_
part of Michael's objection.
As I see it, the make variables defined in CONFIG_ENV allow user overrides
via CONFIG_SITE_ENV to set site defaults for CA environment parameters.
The only change needed to make pvAccess compatible is to use those make src/pva/ pv/pvaConstants .h
variables to override the default values in pvAccess/
pvAccess wouldn't need to use the envGet* ConfigParam* () calls as it's current serverContext. cpp that calls getPropertyAs*() routines
code in src/server/
can stay as is.