Preparation for implementation with Golang

Create the directories used for implementation with Golang.

 

  1. Create the module directory

    Create the "sample" directory directly under $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent.

    • $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent/sample

     

  2. Create the "plugin" directory

    Create the "plugin" directory in $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent/sample.

    • $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent/sample/plugin

     

  3. Create the "external" directory

    Create the "external" directory in $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent/sample.

    • $SDK_HOME/dev/go/src/github.com/saison-sherpa/es-agent/sample/external

     

  4. Create the source files

    Create source files with the following names in the module directory ("sample" directory):

    • source.go

    • sink.go

    • udsf.go

    = Remarks =

    It is not required to use these file names.

    These file names are used in this manual for the sake of convenience.

     

  5. Settings when using an IDE

    If you use an IDE for implementation with Golang, configure the following settings:

    1. Start the IDE and select %SDK_HOME%/dev/go to open it.

    2. Set %SDK_HOME%/dev/go for the Gopath in the IDE.

      <Example> In the case of VSCode:

      File > Preferences > Settings > Extensions > Go configuration > Gopath