text
stringlengths
3.08k
10.4k
// Code generated by protoc-gen-go. DO NOT EDIT. // source: remove_action_from_role.proto package identityd2 import ( fmt "fmt" _ "github.com/envoyproxy/protoc-gen-validate/validate" proto "github.com/golang/protobuf/proto" math "math" ) // Reference imports to suppress errors if they are not otherwise used. var...
package models import ( "fmt" "github.com/astaxie/beego/orm" "github.com/pkg/errors" "github.com/Qihoo360/doraemon/cmd/alert-gateway/logs" ) type Rules struct { Id int64 `orm:"column(id);auto" json:"id,omitempty"` Expr string `orm:"column(expr);size(1023)" json:"expr"` Op string `or...
// Package conf provides configuration handler for dlp package conf import ( "fmt" "io/ioutil" "strings" "github.com/bytedance/godlp/errlist" "gopkg.in/yaml.v2" ) type MaskRuleItem struct { RuleName string `yaml:"RuleName"` MaskType string `yaml:"MaskType"` // one of [CHAR, TAG, REPLACE, EMPTY, ...
package messages import ( "bytes" "encoding/binary" "encoding/json" "errors" "fmt" "github.com/buguang01/util" ) //这个还没有完成 type GateJsonMessageHandle struct { msgHead uint32 //消息头 msgMaxLen uint16 //消息最大长度 routelist map[uint32]interface{} //消息路由列表 defType interface{} ...
/* Copyright 2021 The CI/CD Operator Authors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in ...
package metascrubber import ( "bytes" "encoding/binary" "errors" "io" "io/ioutil" ) var headerBytes []byte = []byte{0xff, 0xd8} // scanReader reads until the scan terminating bytes are encountered type scanReader struct { reader *io.Reader } func firstMarker(p []byte) int { markerIndex := -1 // Look for an ...
package runner import ( "fmt" v1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/rest" "k8s.io/client-go/tools/cache" common "github.com/luqmanMohammed/eventsrunner/common/pkg" erAPI "github.com/luqmanMohammed/eventsrunner/crd/pkg/apis/eventsrunner.io/v1alpha1" "github.co...
package main import ( "bufio" "log" "os/exec" "regexp" "strconv" "strings" ) // Hpa struct type Hpa struct { Namespace string Name string ReferenceKind string ReferenceName string UsageCPU int Target int MinPods int MaxPods int Replicas int Age strin...
package dispatcher import ( "log" URL "net/url" "os" "quickscrape/extractor" "strings" "sync" "time" ) const SCRAPE_MAX_RETRY = 5 const MAX_PARALLEL_SCRAPE = 15 const PROCESS_MAX_RETRY = 5 // flags var EXTERNAL = true var RELATED = true var DEPTH int8 = -1 var queue []string = make([]string, 0) var qchan cha...
// // Author:: <NAME> (<<EMAIL>>) // Copyright:: Copyright 2021, Lacework Inc. // License:: Apache License, Version 2.0 // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://ww...
package function_run_record import ( "fmt" "net/url" "strconv" "strings" "time" "github.com/fBloc/bloc-server/interfaces/web" "github.com/fBloc/bloc-server/internal/util" "github.com/fBloc/bloc-server/value_object" "github.com/pkg/errors" ) type FunctionRunRecordFilter struct { FunctionID string `map...
// Package schema provides useful custom types and functions to format database objects into these types package schema import ( "errors" "github.com/soumitradev/Dwitter/backend/prisma/db" ) // Format as BasicDweet func FormatAsBasicDweetType(dweet *db.DweetModel) BasicDweetType { reply_id, present := ...
package main import ( "crypto/tls" "flag" "net/http" "os" "strings" "time" "cloud.google.com/go/profiler" "github.com/golang/glog" "github.com/moonrhythm/parapet" "github.com/moonrhythm/parapet/pkg/compress" "github.com/moonrhythm/parapet/pkg/logger" "github.com/moonrhythm/parapet/pkg/prom" controller "...
package todoistclient import ( "fmt" "github.com/stretchr/testify/assert" "net/http" "net/http/httptest" "os" "reflect" "testing" "time" ) const ( authToken = "<PASSWORD>" ) var ( testServer *httptest.Server testClient *http.Client todoistClient *Client uriMap = initURIMap() ) func setUp() { te...
// Copyright (c) 2018 Cisco and/or its affiliates. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at: // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicabl...
/* Sniperkit-Bot - Status: analyzed */ package test import ( "io/ioutil" "log" "os" "os/exec" "testing" "time" "github.com/satori/go.uuid" "github.com/sniperkit/snk.fork.lazytree/fuse" "github.com/sniperkit/snk.fork.lazytree/tree/mem" ) var FuseFileSystems []*fuse.FuseFileSystem var MountPoints []string ...
package service import ( "encoding/json" "errors" "github.com/lemon997/lemonMall/internal/mq/producer" "github.com/lemon997/lemonMall/global" "github.com/lemon997/lemonMall/internal/dao" "github.com/lemon997/lemonMall/internal/model" "github.com/lemon997/lemonMall/internal/redisDao" ) func (svc Service) Get...
package fec import ( "errors" "github.com/lucas-clemente/quic-go/internal/protocol" "github.com/lucas-clemente/quic-go/internal/utils" "github.com/lucas-clemente/quic-go/internal/wire" ) //TODO: maybe the RepairSymbol should have its number in the structure type FECBlock struct { FECBlockNumber prot...
package model import ( "bufio" "fmt" "io" "log" "strconv" "strings" ) // Goroutine info from pprof API. See: https://github.com/DataDog/go-profiler-notes/blob/main/goroutine.md // Status Details: // See: https://github.com/golang/go/blob/go1.15.6/src/runtime/runtime2.go#L14-L105 // and https://github.com/golang...
package registry import ( "fmt" "strings" "sync" "github.com/go-chassis/go-chassis/core/config" "github.com/go-chassis/go-chassis/core/lager" "log" ) // constant values for registry parameters const ( DefaultRegistratorPlugin = "servicecenter" DefaultServiceDiscoveryPlugin = "servicecenter" DefaultCo...
/* Copyright 2018 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
package topology import ( "database/sql" "encoding/json" "errors" "os" "os/signal" "strconv" "syscall" "time" "github.com/golang/protobuf/ptypes/any" "github.com/uber-go/tally" "go.uber.org/zap" "golang.org/x/net/context" "google.golang.org/protobuf/encoding/protojson" "google.golang.org/protobuf/types/...
package config import ( "github.com/derailed/k9s/internal/client" ) const ( defaultRefreshRate = 2 defaultMaxConnRetry = 5 ) // K9s tracks K9s configuration options. type K9s struct { RefreshRate int `yaml:"refreshRate"` MaxConnRetry int `yaml:"maxConnRetry"` EnableM...
package main import ( "bufio" "fmt" "math" "math/rand" "os" "strconv" "strings" "time" ) type cell struct { isMine bool display byte // display character for cell } const lMargin = 4 var ( grid [][]cell mineCount int minesMarked int isGameOver bool ...
/* Copyright (c) 2019 the Octant contributors. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 */ package printer import ( "context" "testing" "time" "github.com/golang/mock/gomock" "github.com/stretchr/testify/require" "github.com/vmware/octant/internal/conversion" "github.com/vmware/octant/interna...
package postgres import ( "database/sql" "fmt" "strings" "time" "github.com/BlackBX/service-framework/dependency" "github.com/heptiolabs/healthcheck" "github.com/jmoiron/sqlx" _ "github.com/newrelic/go-agent/v3/integrations/nrpq" // We need the database "go.uber.org/fx" ) // Service defines the configuratio...
// Copyright 2014 The Gogs Authors. All rights reserved. // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. package models import ( "fmt" "sort" "strings" "time" "github.com/go-xorm/xorm" "code.gitea.io/git" "code.gitea.io/gitea/modules/process" ) // Rel...
package eventbus import ( "encoding/json" "fmt" "os" "k8s.io/klog" "github.com/kubeedge/beehive/pkg/core" beehiveContext "github.com/kubeedge/beehive/pkg/core/context" "github.com/kubeedge/kubeedge/edge/pkg/common/modules" "github.com/kubeedge/kubeedge/edge/pkg/eventbus/common/util" eventconfig "github.com/...
// Package mock implements a mock runtime host useful for tests. package mock import ( "bytes" "context" "fmt" "github.com/oasisprotocol/oasis-core/go/common" "github.com/oasisprotocol/oasis-core/go/common/cbor" "github.com/oasisprotocol/oasis-core/go/common/crypto/hash" "github.com/oasisprotocol/oasis-core/go...
/* Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
// Code generated by github.com/fjl/gencodec. DO NOT EDIT. package eth import ( "math/big" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/consensus/istanbul" "github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/eth/d...
package sdk import ( "database/sql/driver" json "encoding/json" "fmt" "regexp" "time" ) // User rings. const ( UserRingAdmin = "ADMIN" UserRingMaintainer = "MAINTAINER" UserRingUser = "USER" ) type Identifiable interface { GetUsername() string GetEmail() string GetFullname() string } var _ Ide...
package pgoutput import ( "context" "fmt" "sync" "sync/atomic" "time" "github.com/jackc/pgx" ) type Subscription struct { Name string Publication string WaitTimeout time.Duration StatusTimeout time.Duration conn *pgx.ReplicationConn maxWal uint64 walRetain uint64 walFlushed uin...
/* Copyright 2020 Docker Compose CLI authors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or a...
package main import ( "errors" "fmt" "os/exec" "regexp" "strconv" "strings" "sync" "testing" "github.com/quilt/quilt/api" "github.com/quilt/quilt/api/client" "github.com/quilt/quilt/connection/credentials" "github.com/quilt/quilt/db" ) // The required bandwidth in Mb/s between two containers on different...
package trafficmanager // Copyright (c) Microsoft and contributors. All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 //...
// Copyright 2018 The Cockroach Authors. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or ag...
// Copyright 2019 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in...
// Copyright (C) 2015 Nippon Telegraph and Telephone Corporation. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required...
//此源码被清华学神尹成大魔王专业翻译分析并修改 //尹成QQ77025077 //尹成微信18510341407 //尹成所在QQ群721929980 //尹成邮箱 <EMAIL> //尹成毕业于清华大学,微软区块链领域全球最有价值专家 //https://mvp.microsoft.com/zh-cn/PublicProfile/4033620 /* 版权所有IBM公司。保留所有权利。 SPDX许可证标识符:Apache-2.0 **/ package comm import ( "context" "crypto/tls" "crypto/x509" "time" "github.com/pkg/erro...
/* Copyright 2018 The CDI Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwar...
/* Copyright 2017, 2019 the Velero contributors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in wr...
// Copyright 2016 tsuru authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package router import ( "net" "sync" "sync/atomic" "time" "github.com/hashicorp/golang-lru" "github.com/prometheus/client_golang/prometheus" "github.com...
package nearbychargestation import ( "fmt" "net/url" "strconv" "strings" "github.com/Telenav/osrm-backend/integration/api" "github.com/Telenav/osrm-backend/integration/api/search/options" "github.com/Telenav/osrm-backend/integration/api/search/searchcoordinate" "github.com/golang/glog" ) // Request for searc...
package realm import ( "archive/zip" "bytes" "encoding/json" "io" "net/http" "github.com/10gen/realm-cli/internal/cli/user" "github.com/10gen/realm-cli/internal/utils/api" ) const ( adminAPI = "/api/admin/v3.0" privateAPI = "/api/private/v1.0" requestOriginHeader = "X-BAAS-Request-Origin" cliHeaderValu...
package csmmapi import ( "encoding/json" "fmt" "net/url" "regexp" "strings" "github.com/go-resty/resty/v2" ) //NewGameServer .... func NewGameServer(ip string, port string, user string, token string, schemeIn ...string) *GameServer { scheme := "http" if len(schemeIn) > 0 { scheme = schemeIn[0] } return &...
package view import ( "fmt" "io/ioutil" "log" "strings" "github.com/awesome-gocui/gocui" "github.com/xenobyter/xbsh/cfg" "github.com/xenobyter/xbsh/term" ) //CD displays a view func CD(path string) string { term.SetStatus("| Esc: Exit | Tab: Exit | F3: Exit | Enter: Do cd") v := newCDView(path) g, err := g...
// Copyright 2019 Istio Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to i...
package thorchain import ( "fmt" "sort" "github.com/blang/semver" sdk "github.com/cosmos/cosmos-sdk/types" "gitlab.com/thorchain/thornode/common" "gitlab.com/thorchain/thornode/constants" "gitlab.com/thorchain/thornode/x/thorchain/keep" ) // SwapQv1 is going to manage the swaps queue type SwapQv1 struct { k...
package common func NewSuccessResDto(isSuccess bool, code int, message, itemId string) *SuccessResDto { dto := new(SuccessResDto) dto.Response = new(successRes) if isSuccess { dto.Response.Flag = "success" } else { dto.Response.Flag = "failure" } dto.Response.Code = code dto.Response.Message = me...
package vcs import ( "bytes" "context" "errors" "fmt" "io/ioutil" "os" "path" "getsturdy.com/api/pkg/codebases" "getsturdy.com/api/pkg/unidiff" "getsturdy.com/api/vcs" "getsturdy.com/api/vcs/executor" "go.uber.org/zap" git "github.com/libgit2/git2go/v33" ) func CreateChangeFromPatchesOnRepo(ctx contex...
package resourcehealth // Copyright (c) Microsoft and contributors. All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 //...
// Copyright (c) 2018 IoTeX // This is an alpha (internal) release and is not suitable for production. This source code is provided 'as is' and no // warranties are given as to title or non-infringement, merchantability or fitness for purpose and, to the extent // permitted by law, all liability for your use of the cod...
/* Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 */ package endorsertx import ( "regexp" "github.com/Elegenthus/fabric-protos-go/peer" "github.com/hyperledger/fabric/pkg/tx" "github.com/hyperledger/fabric/protoutil" "github.com/pkg/errors" ) var ( // ChannelAllowedChars tracks...
// This file is subject to a 1-clause BSD license. // Its contents can be found in the enclosed LICENSE file. package spirv import "fmt" // TODO: Context-aware validation. Most instructions here require context // (i.e., module) to properly validate. // OpPhi is the SSA phi function. type OpPhi struct { ResultType...
// Copyright 2020 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // https://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in ...
/* Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
package csm import ( "encoding/json" "net" "time" "github.com/pendo-io/aws-sdk-go/aws" "github.com/pendo-io/aws-sdk-go/aws/awserr" "github.com/pendo-io/aws-sdk-go/aws/request" ) // Reporter will gather metrics of API requests made and // send those metrics to the CSM endpoint. type Reporter struct { clientID ...
// _ _ // __ _____ __ ___ ___ __ _| |_ ___ // \ \ /\ / / _ \/ _` \ \ / / |/ _` | __/ _ \ // \ V V / __/ (_| |\ V /| | (_| | || __/ // \_/\_/ \___|\__,_| \_/ |_|\__,_|\__\___| // // Copyright © 2016 - 2022 SeMI Technologies B.V. All rights reserved. // // CONTACT: <EMAIL>...
/* * Tencent is pleased to support the open source community by making Blueking Container Service available. * Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved. * Licensed under the MIT License (the "License"); you may not use this file except * in compliance with the License. You may obta...
// Package db handles new connections and transactions with timeouts. // // Timeouts that can be defined: // Connect timeout - sets the maximum wait for creating a new connection // Statement timeout - sets the maximum wait for queries completion // New transaction timeout - sets the maximum wait...
package raftmeta import ( "bytes" "context" "encoding/json" "fmt" "github.com/influxdb-cluster/raftmeta/internal" "github.com/influxdb-cluster/x" "github.com/coreos/etcd/raft" "github.com/coreos/etcd/raft/raftpb" "go.uber.org/zap" "io/ioutil" "net" "net/http" "strconv" "sync" "time" ) type Transport st...
package main import ( "context" "fmt" "log" "time" "github.com/MindsightCo/collector/apiclient" "github.com/MindsightCo/collector/cache" auth0grant "github.com/ereyes01/go-auth0-grant" "github.com/pkg/errors" "github.com/spf13/viper" ) const ( defaultAPIServer = "https://sre-api.mindsight.io/"...
/* Copyright 2022 TriggerMesh Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwar...
package workflow import ( "context" "fmt" "strconv" "github.com/go-gorp/gorp" "github.com/ovh/cds/engine/api/cache" "github.com/ovh/cds/engine/api/observability" "github.com/ovh/cds/sdk" "github.com/ovh/cds/sdk/tracingutils" ) type nodeRunContext struct { Application sdk.Application Pipeline ...
// Copyright 2019 Yunion // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writi...
// Code generated by protoc-gen-gogo. DO NOT EDIT. // source: github.com/gimalay/octogo/todoapp/core/aggregate/events.proto package aggregate import ( fmt "fmt" proto "github.com/golang/protobuf/proto" math "math" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var ...
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved. // See LICENSE.txt for license information. package retrylayer import ( "testing" "github.com/go-sql-driver/mysql" "github.com/lib/pq" "github.com/zgordan-vv/zacmm-server/model" "github.com/zgordan-vv/zacmm-server/store/storetest/mocks" "githu...
/* Copyright 2017 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
package sectorstorage import ( "context" "math/rand" "sync" "time" xerrors "golang.org/x/xerrors" "github.com/filecoin-project/go-state-types/abi" sealtasks "github.com/filecoin-project/lotus/extern/sector-storage/sealtasks" "github.com/filecoin-project/lotus/extern/sector-storage/stores" "github.com/filec...
/* Copyright 2018 The Skaffold Authors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, sof...
// Copyright 2020 VMware, Inc. // SPDX-License-Identifier: Apache-2.0 package git import ( "bytes" "fmt" "os/exec" "strings" ctlconf "github.com/vmware-tanzu/carvel-vendir/pkg/vendir/config" ctlfetch "github.com/vmware-tanzu/carvel-vendir/pkg/vendir/fetch" oarmor "github.com/vmware-tanzu/carvel-vendir/pkg/ven...
package gotgbot import ( "encoding/json" "fmt" "io/ioutil" "net/http" "net/url" "strconv" "time" "github.com/pkg/errors" "github.com/sirupsen/logrus" "github.com/PaulSonOfLars/gotgbot/ext" ) // Updater The main updater process. Receives incoming updates, then sends them to the dispatcher goroutine // via ...
// Code generated by gotdgen, DO NOT EDIT. package tg import ( "context" "errors" "fmt" "sort" "strings" "go.uber.org/multierr" "github.com/gotd/td/bin" "github.com/gotd/td/tdjson" "github.com/gotd/td/tdp" "github.com/gotd/td/tgerr" ) // No-op definition for keeping imports. var ( _ = bin.Buffer{} _ = ...
package view import ( "fmt" "time" "unicode/utf8" "github.com/bunyk/gokeybr/stats" "github.com/gdamore/tcell/v2" ) var doneStyle tcell.Style = tcell.StyleDefault. Foreground(tcell.ColorGreen) var lifeStyle tcell.Style = tcell.StyleDefault. Foreground(tcell.ColorPurple) var redBar = tcell.StyleDefault. Back...
/* Copyright 2018 The OpenEBS Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwa...
package gobusters3 import ( "bufio" "bytes" "context" "encoding/xml" "fmt" "net/http" "regexp" "strings" "text/tabwriter" "github.com/OJ/gobuster/v3/libgobuster" ) // GobusterS3 is the main type to implement the interface type GobusterS3 struct { options *OptionsS3 globalopts *libgobuster.Options h...
package pgkeyvalue import ( "context" "fmt" "time" "github.com/hashicorp/golang-lru/simplelru" "github.com/jackc/pgconn" "github.com/jackc/pgerrcode" "github.com/jackc/pgx/v4" "github.com/jackc/pgx/v4/pgxpool" "github.com/pkg/errors" "github.com/sirupsen/logrus" "github.com/G-Research/armada/internal/comm...
package safelock import ( "bytes" "context" "encoding/binary" "fmt" "io/ioutil" "math/rand" "os" "time" ) // FileLock will create a lock for a specific file // As an example, if the URI is file:///filename.txt then the lock will be // a file named file:///filename.txt.lock and the contents will be the lock's ...
/* Copyright 2019 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwa...
package filer import ( "bytes" "context" "fmt" "github.com/chrislusf/seaweedfs/weed/pb" "github.com/chrislusf/seaweedfs/weed/wdclient" "google.golang.org/grpc" "io" "github.com/chrislusf/seaweedfs/weed/glog" "github.com/chrislusf/seaweedfs/weed/pb/filer_pb" "github.com/chrislusf/seaweedfs/weed/util" "githu...
/* Copyright 2019 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
package params import ( "fmt" "net/url" "reflect" "strconv" "strings" "github.com/Nivl/go-params/formfile" "github.com/Nivl/go-params/perror" ) // Params is a struct used to parse and extract params from an other struct type Params struct { data interface{} } // New creates a new Params object from a struct...
package termination import ( "context" "fmt" "io/ioutil" "net/http" "net/url" "sync" "time" "github.com/go-logr/logr" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/client-go/kubernetes/scheme" "k8s.io/client-go/rest" "sigs.k8s.io/co...
package config import ( "errors" "fmt" "io/ioutil" "strings" "time" "github.com/BurntSushi/toml" "github.com/go-playground/validator/v10" ) const ( denomUSD = "USD" defaultListenAddr = "0.0.0.0:7171" defaultSrvWriteTimeout = 15 * time.Second defaultSrvReadTimeout = 15 * time.Second ProviderKraken...
package common import ( "database/sql" "fmt" "regexp" "strings" "time" "github.com/sirupsen/logrus" "gorm.io/driver/mysql" "gorm.io/gorm" ) // M a short name type M = map[string]interface{} // MS a short name type MS = map[string]string // ModelBase model base for gorm to provide base fields type ModelBase...
package test_test import ( "strings" . "github.com/onsi/ginkgo" . "github.com/onsi/ginkgo/extensions/table" . "github.com/onsi/gomega" loggingv1 "github.com/openshift/cluster-logging-operator/pkg/apis/logging/v1" . "github.com/openshift/cluster-logging-operator/test" . "github.com/openshift/cluster-logging-ope...
/* Copyright 2020 The Flux authors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwar...
package entity import "encoding/json" type IsHs string //是否沪深港通标的 const ( IsHs_N IsHs = "N" //否 IsHs_H IsHs = "H" //沪股通 IsHs_S IsHs = "S" //深股通 ) func AllIsHs() []IsHs { return []IsHs{IsHs_N, IsHs_H, IsHs_S} } type ListStatus string //上市状态 const ( ListStatus_L ListStatus = "L" //上市 ListStatus_D ListStatus =...
// Cloud Driver Interface of CB-Spider. // The CB-Spider is a sub-Framework of the Cloud-Barista Multi-Cloud Project. // The CB-Spider Mission is to connect all the clouds with a single interface. // // * Cloud-Barista: https://github.com/cloud-barista // // This is Resouces interfaces of Cloud Driver. // // by <E...
package auth import ( "fmt" "strings" "time" "github.com/youremine2493/Dalaran/database" "github.com/youremine2493/Dalaran/logging" "github.com/youremine2493/Dalaran/utils" "gopkg.in/guregu/null.v3" ) type LoginHandler struct { password string username string } var ( USER_NOT_FOUND = ut...
// Copyright 2013 The lime Authors. // Use of this source code is governed by a 2-clause // BSD-style license that can be found in the LICENSE file. package keys import ( "bytes" "encoding/json" "fmt" "sort" . "github.com/limetext/util" ) type ( // A single KeyBinding for which after pressing the given // se...
package requests /* This turned out a bit more complex than originally anticipated. - We try to compact the timeseries upon storage as much as possible. For this we use the gorilla algorithm from go-tsz. - However, this requries all timeseries to be pushed in a timely ordered fashion. - We want to push timeseries fr...
// Copyright (c) 2019 The Jaeger Authors. // Copyright (c) 2017 Uber Technologies, Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 //...
package nomad import ( "fmt" "math/rand" "net" "os" "path/filepath" "strconv" version "github.com/hashicorp/go-version" "github.com/hashicorp/nomad/nomad/state" "github.com/hashicorp/nomad/nomad/structs" "github.com/hashicorp/serf/serf" ) // ensurePath is used to make sure a path exists func ensurePath(pat...
/* Copyright 2021. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed un...
// Licensed to Elasticsearch B.V. under one or more contributor // license agreements. See the NOTICE file distributed with // this work for additional information regarding copyright // ownership. Elasticsearch B.V. licenses this file to you under // the Apache License, Version 2.0 (the "License"); you may // not use ...
/******************************************************************************** * Copyright 2019 Dell Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * * http://www.apache.org/lice...
/* Copyright 2018 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
package srp6 import ( "crypto/rand" "crypto/sha1" "github.com/walkline/ToCloud9/shared/slices" "math/big" ) var _N = big.NewInt(0). SetBytes([]byte{137, 75, 100, 94, 137, 225, 83, 91, 189, 173, 91, 139, 41, 6, 80, 83, 8, 1, 177, 142, 191, 191, 94, 143, 171, 60, 130, 135, 42, 62, 155, 183}) var _g = big.NewInt(7)...