Skip to content
/ esl Public

Yet another implementation ESL of FreeSwitch in Golang

License

Notifications You must be signed in to change notification settings

g302ge/esl

Repository files navigation

esl

Yet another Go ESL for FreeSwitch, to build lightweight FS event socket application :)

Inbound Client Example

// TODO...

Outbound Server Example

func main() {
  server := NewServer(context.TODO(),"0.0.0.0:8080")
  server.Callback = func(channel *OutboundChannel) {
    channel.Connect()
    channel.Answer()
    // TODO: create your own state machine model
		for event := range channel.Events {
			switch event.Name {
        case EslEventCustom: 
        {// custom event logic
            channel.Hangup()
        }
        case EslEventChannelHangupComplete: // create a new cdr send to channel
      }
    }
    channel.Shutdown()
	}
}

Event Socket concurrency pattern

What is SC?

TODO:

How to build your FS control logic

TODO:

Clearfy FS Manual and Concepts

Here is a simple clearfy FS manual and introduce some confused concepts in FS not only Channel lifecycle and more.

TODO:

TODO List

  1. When Inbound disconnected and how to recover the inbound connection state?
  2. If sendmsg could recover the session
  3. Wrap the fsctl commands in this package
  4. Total callcenter example single node no cluster

About

Yet another implementation ESL of FreeSwitch in Golang

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages