Documentation ¶
Overview ¶
Copyright 2021 IBM 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, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 IBM 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, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 IBM 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, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021 IBM 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, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
Constants ¶
const ( ModelRegistryPrefix = "registry" VModelRegistryPrefix = "vmodels" )
const KUBE_SCHEME = "kube"
Variables ¶
This section is empty.
Functions ¶
func CreateEtcdClient ¶
Types ¶
type EtcdConfig ¶
type EtcdConfig struct { Endpoints string `json:"endpoints"` Username string `json:"userid"` Password string `json:"password"` RootPrefix string `json:"root_prefix"` Certificate string `json:"certificate"` CertificateFile string `json:"certificate_file"` ClientKey string `json:"client_key"` ClientKeyFile string `json:"client_key_file"` ClientCertificate string `json:"client_certificate"` ClientCertificateFile string `json:"client_certificate_file"` OverrideAuthority string `json:"override_authority"` }
type EtcdRangeWatcher ¶
type EtcdRangeWatcher struct { WatchPrefix string // contains filtered or unexported fields }
EtcdRangeWatcher A wrapper for Etcd Watch with common refresh Watch Channel logic
func NewEtcdRangeWatcher ¶
func (*EtcdRangeWatcher) Start ¶
func (r *EtcdRangeWatcher) Start(ctx context.Context, keysOnly bool, listener KvListener)
type KeyEvent ¶
type KeyEvent struct { Type KeyEventType Key string Value []byte }
type KeyEventChan ¶
type KeyEventChan chan KeyEvent
type KeyEventType ¶
type KeyEventType uint8
const ( UPDATE KeyEventType = iota DELETE INITIALIZED )
func (KeyEventType) String ¶
func (t KeyEventType) String() string
type KubeResolver ¶
KubeResolver is a ResolverBuilder and a Reconciler
func InitGrpcResolver ¶
func InitGrpcResolver(namespace string, mgr ctrl.Manager) (*KubeResolver, error)
InitGrpcResolver should only be called once
func (*KubeResolver) Build ¶
func (kr *KubeResolver) Build(target resolver.Target, cc resolver.ClientConn, _ resolver.BuildOptions) (resolver.Resolver, error)
func (*KubeResolver) Scheme ¶
func (*KubeResolver) Scheme() string
type KvListener ¶
type KvListener func(eventType KeyEventType, key string, value []byte)
type MMService ¶
type MMService struct { Log logr.Logger Name string Port uint16 ManagementEndpoint string Headless bool TLSConfig *tls.Config MetricsPort uint16 // contains filtered or unexported fields }
Encapsulates ModelMesh gRPC service
func NewMMService ¶
func NewMMService() *MMService
func (*MMService) Disconnect ¶
func (mms *MMService) Disconnect()
func (*MMService) InferenceEndpoint ¶
func (*MMService) MMClient ¶
func (mms *MMService) MMClient() mmeshapi.ModelMeshClient
type ModelMeshEventStream ¶
type ModelMeshEventStream struct { MMEvents chan event.GenericEvent // contains filtered or unexported fields }
ModelMeshEventStream generates events for Predictors based on changes to models/vmodels within model-mesh's etcd-based registries. This is unfortunately tightly coupled to certain model-mesh internal details (i.e. etcd layout), and in future we would like to expose streaming gRPC APIs from model-mesh for an "official" way to watch for model events.
func NewModelEventStream ¶
func (*ModelMeshEventStream) IsWatching ¶
func (mes *ModelMeshEventStream) IsWatching() bool