Sample adapter configuration file for the Socket JSON Input adapter.
<?xml version="1.0" encoding="utf-8"?> <Adapter> <Name>socket_json_input</Name> <Description>An adapter which receives JSON message from socket server,transforms to ESP data format, and publishes to ESP stream.</Description> <Log4jProperty>./log4j.properties</Log4jProperty> <Modules> <Module type="transporter"> <InstanceName>MyExampleSocketInTransporter</InstanceName> <Name>SocketInputTransporter</Name> <Next>MyJsonStreamToJsonStringFormatter</Next> <Parameters> <SocketInputTransporterParameters> <Host>localhost</Host> <Port>9998</Port> <EpFile></EpFile> <Retryperiod>60</Retryperiod> <Blocksize>512</Blocksize> <KeepAlive>true</KeepAlive> </SocketInputTransporterParameters> </Parameters> </Module> <Module type="formatter"> <InstanceName>MyJsonStreamToJsonStringFormatter</InstanceName> <Name>JsonStreamToJsonStringFormatter</Name> <Next>MyJsonInFormatter</Next> <Parameters /> </Module> <Module type="formatter"> <InstanceName>MyJsonInFormatter</InstanceName> <Name>JsonStringToEspFormatter</Name> <Next>MyInStream_Publisher</Next> <Parameters> <JsonStringToEspFormatterParameters> <DateFormat>yyyy-MM-dd HH:mm:ss.SSS</DateFormat> <TimestampFormat>yyyy/MM/dd HH:mm:ss</TimestampFormat> <ColumnMappings> <ColsMapping streamname="EntityStream" rootpath="entities"> <Column>display_text</Column> <Column>domain_role</Column> <Column>offset</Column> <Column>length</Column> </ColsMapping> </ColumnMappings> </JsonStringToEspFormatterParameters> </Parameters> </Module> <Module type="espconnector"> <InstanceName>MyInStream_Publisher</InstanceName> <Name>EspPublisher</Name> <Parameters> <EspPublisherParameters> <ProjectName>EspProject1</ProjectName> <StreamName>EntityStream</StreamName> <MaxPubPoolSize>1</MaxPubPoolSize> <UseTransactions>false</UseTransactions> <SafeOps>true</SafeOps> <SkipDels>true</SkipDels> </EspPublisherParameters> </Parameters> </Module> </Modules> <EspProjects> <EspProject> <Name>EspProject1</Name> <Uri>esp://localhost:19011/sample_workspace/socket_json_input</Uri> <Security> <User></User> <Password encrypted="false"></Password> <AuthType>user_password</AuthType> <!-- <RSAKeyStore>/keystore/keystore.jks</RSAKeyStore> <RSAKeyStorePassword>Sybase123</RSAKeyStorePassword> --> <!-- <KerberosKDC>KDC</KerberosKDC> <KerberosRealm>REALM</KerberosRealm> <KerberosService>service/instance</KerberosService> <KerberosTicketCache>/tmp/krb5cc_user</KerberosTicketCache> --> <EncryptionAlgorithm>RSA</EncryptionAlgorithm> </Security> </EspProject> </EspProjects> <GlobalParameters></GlobalParameters> </Adapter>