This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import "sync" | |
var webhooks = make(chan Webhook) | |
type Webhook struct{ | |
//build the webhook struct | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func CreateBmak(site string, apipublickey string) bmak { | |
b := bmak{ | |
Ver: 1.68, | |
KeCntLmt: 150, | |
MmeCntLmt: 100, | |
MduceCntLmt: 75, | |
PmeCntLmt: 25, | |
PduceCntLmt: 25, | |
TmeCntLmt: 25, | |
TduceCntLmt: 25, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type bmak struct { | |
Browser Browser | |
start_ts int64 | |
ke_vel int | |
me_vel int | |
te_vel int | |
doe_vel int | |
dme_vel int | |
pe_vel int | |
init_time int |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func CreateBmak(site string, apipublickey string) bmak { | |
b := bmak{ | |
Ver: 1.68, | |
KeCntLmt: 150, | |
MmeCntLmt: 100, | |
MduceCntLmt: 75, | |
PmeCntLmt: 25, | |
PduceCntLmt: 25, | |
TmeCntLmt: 25, | |
TduceCntLmt: 25, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Browser struct { | |
gorm.Model | |
Navigator struct { | |
Appcodename string `json:"appCodeName"` | |
Appname string `json:"appName"` | |
Appversion string `json:"appVersion"` | |
Language string `json:"language"` | |
Languages pq.StringArray `json:"languages" gorm:"type:text[]"` | |
Useragent string `json:"userAgent"` | |
Vendor string `json:"vendor"` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"github.com/gofiber/fiber/v2" | |
"github.com/gofiber/fiber/v2/middleware/proxy" | |
"time" | |
) | |
type Proxy struct { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Broadcaster struct { | |
cond *sync.Cond | |
subscribers map[interface{}]func(interface{}) | |
message interface{} | |
running bool | |
} | |
// SetupBroadcaster gives the broadcaster object to be used further in messaging | |
func SetupBroadcaster() *Broadcaster { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Scheduler: | |
def __init__(self, max_workers: int, queue_maxsize: int = None): | |
self.max_workers = max_workers | |
self._queue_maxsize = queue_maxsize | |
self.queue = None | |
async def _execute(self, func, args, kwds): | |
try: | |
return await func(*args, **kwds) | |
finally: |