vmware / alb-sdk Goto Github PK
View Code? Open in Web Editor NEWAvi SDK and Utilities
License: Apache License 2.0
Avi SDK and Utilities
License: Apache License 2.0
Maybe not the right place, but was wondering how to raise it and where...
We have some "challenges" with AVI + Openshift + WSS
openshift/origin#12222
Converter is not able to convert the F5 config to AVI for VIP with same IP address and port number but different protocol. For example if a VIP with 192.168.1.1 with a port 389 with TCP protocol get successful conversion where if the same ip address 192.168.1.1 with port 389 and different protocol UDP is not getting converted.
"WARNING: VS object not found with name xxxxxxxxxxxxxxxxxx-UDP
...
It should not skip the VIPs as it's creating a list with "Skipped: Duplicate IP-Port for vs"
No response
Below is my playbook of creating a GSLB service
gslbservice:
- name: "{{ gslb_domainname }}"
enabled: true
down_response:
type: GSLB_SERVICE_DOWN_RESPONSE_NONE
domain_names:
- "{{ gslb_domainname }}"
is_federated: true
health_monitor_refs:
- '/api/healthmonitor?name=System-GSLB-Ping'
- '/api/healthmonitor?name=System-GSLB-HTTP'
use_edns_client_subnet: true
pool_algorithm: GSLB_SERVICE_ALGORITHM_PRIORITY
groups:
- priority: 10
members:
- site_name: "gslb"
vip_type: "AVI_VIP"
vs_name: "{{ vs_name }}"
ip:
type: V4
addr: "{{ vs_vip }}"
vs_uuid_ref: '/api/virtualservice?name={{ vs_name }}'
ratio: 1
enabled: true
enabled: true
name: "{{ gslb_domainname }}-pool"
algorithm: GSLB_ALGORITHM_ROUND_ROBIN
site_persistence_enabled: false
min_members: 0
health_monitor_scope: GSLB_SERVICE_HEALTH_MONITOR_ALL_MEMBERS
num_dns_ip: 1
When I run this playbook, the pool member is referred to an IP, not a virtual service
Hi team,
could you help to add a space to the error messages master/go/session/avisession.go line 1353 and line 1355? it would be better to change "is found" to " is found".
if res.Count == 0 {
return errors.New("No object of type " + obj + " with name " + opts.name + "is found")
} else if res.Count > 1 {
return errors.New("More than one object of type " + obj + " with name " + opts.name + "is found")
}
1. Get an object with error name from Avi Controller. The return error message will be like:
"No object of type serviceenginegroup with name test-se-groupis found"
There should be a space between opts.name and "is found", for instance, the error message should be:
"No object of type serviceenginegroup with name test-se-group is found"
No response
hello, reaching out because we are trying to use the netscaler converter script on an exported netscaler conf file but we are running into issues. When we run the tool netsacer_converter.py it fails because no module named netscaler_converter exists. Upon trying to install the tools using pip install avimigrationtools==17.1.1.post1 avisdk==17.1.1.post1 it fails everytime (on multiple pcs) when trying to install pycrypto.. Even when when trying to install pycrypto using pip install same error results. Tried on latest python release and older one 2.7. have PIP and setuptools up to date. Please see attached output when trying to install avisdk / avimigrationtools
pycryptofailure.txt
Code for NSX-LB AVI mapping
Hi all, we're curious about the release strategy for the avisdk. We've had builds fail over the past couple of days because we are pinning versions to beta candidates which are being deleted from PyPI as new betas are released. Is there a safe version we can pin to so that we avoid in the future?
When we try to copy a WAF policy between two AVI clusters, we get the following error:
$ python3 clone_vs.py -c C1 -dc C2 -t Tenant -2t Tenant generic wafpolicy Repo Repo-clonetest
clone_vs.py version 2.0.2
Password for admin@C1:
Password for admin@C2:
Creating source API session to C1...OK!
Creating destination API session to C2...OK!
Detected API version 22.1.2. Reconnecting.
Creating source API session to C1 (22.1.2)...OK!
Creating destination API session to C2 (22.1.2)...OK!
Trying to clone object of type wafpolicy with name Repo [Tenant] to Repo-clonetest [Tenant]...
Unable to clone wafpolicy "Repo" as "Repo-clonetest" (400:{"error": "Invalid configuration: WafPolicy application signature provider not found."})
=> Unable to clone wafpolicy "Repo" as "Repo-clonetest"
Copying the WAF policy within the same AVI cluster works without problems:
$ python3 clone_vs.py -c C1 -dc C1 -t Tenant -2t Tenant generic wafpolicy Repo Repo-clonetest
clone_vs.py version 2.0.2
Password for admin@C1:
Password for admin@C1:
Creating source API session to C1...OK!
Creating destination API session to C1...OK!
Detected API version 22.1.2. Reconnecting.
Creating source API session to C1 (22.1.2)...OK!
Creating destination API session to C1 (22.1.2)...OK!
Trying to clone object of type wafpolicy with name Repo [Tenant] to Repo-clonetest [Tenant]...
OK!
New object of type wafpolicy created as follows:
Name: Repo-clonetest
Tenant: Tenant
Actions taken were:
python3 clone_vs.py -c C1 -dc C2 -t Tenant -2t Tenant generic wafpolicy wafpolicy wafpolicy-clone
I would have expected that you can copy a WAF policy not only in the same cluster, but also to other clusters.
No response
The go client does not query escape parameters provided to it. I've tested this with Avi 30.1.1, which results in a HTTP 400 error.
Error I see:
2024/03/01 22:07:12 Encountered an error on GET request to URL https://<avi-ip>/api/network?name=VM Network: HTTP code: 400; error from Controller: <nil>
Here is a minimal example of the issue. Notably this doesn't work with Avi 30.1.1, but it did work with previous versions, so there was probably a change introduced in 30.1.1.
package main
import (
"log"
"os"
"github.com/vmware/alb-sdk/go/clients"
"github.com/vmware/alb-sdk/go/session"
)
func main() {
aviURL := os.Args[1]
aviUsername := os.Args[2]
aviPassword := os.Args[3]
aviClient, err := clients.NewAviClient(aviURL, aviUsername,
session.SetPassword(aviPassword),
session.SetTenant("admin"),
session.SetInsecure)
if err != nil {
log.Fatalln(err)
}
// Works
_, err = aviClient.Network.GetByName("VM+Network")
if err != nil {
log.Fatalln(err)
}
// Doesn't work
_, err = aviClient.Network.GetByName("VM Network")
if err != nil {
log.Fatalln(err)
}
}
Run by
go run main.go <avi-url> <username> <password>
I expect the client library to query escape the parameters I provide to it, to create a well-formed url that can be used to make REST requests to the Avi API. For example, in my example providing VM Network
to the aviClient.Network.GetByName
function should result in a path param that looks like ?name=VM+Network
instead of ?name=VM Network
.
No response
When I try to clone a Virtual Service to an AVI cluster via clone_vs.py, the script always aborts with the message that the VRF context is different.
However, on both sides the NSX-T cloud is configured completely identically, including the name
Virtual service is cloned 1:1 on new new AVI cluster
`clone_vs.py version 2.0.2
DEBUG:main:Debugging enabled
Password for admin@:
Password for admin@:
Creating source API session to ...OK!
Creating destination API session to ...OK!
Detected API version 22.1.2. Reconnecting.
Creating source API session to (22.1.2)...OK!
Creating destination API session to (22.1.2)...OK!
Trying to clone VS [] to [] in cloud -vdp-nsxmanager...
DEBUG:main:Cloning Virtual Service "" to ""
DEBUG:main:Source Virtual Service is an SNI/EVH child VS
DEBUG:main:Cloning pool "pool/pool-b068130b-7f18-418f-9db0-a0c249f1c08f" to "-pool"
DEBUG:main:Running _processobject_pool
DEBUG:main:Cloning forced refs for -pool
DEBUG:main:Cloning refs for -pool
DEBUG:main:Referenced object not available in target (healthmonitor/healthmonitor-4213eef0-923d-4831-ac06-2de9f1ca7ab7)
DEBUG:main:Using identically-named object "System-HTTPS"
DEBUG:main:Referenced object not available in target (sslprofile/sslprofile-0777a829-4ee3-4cef-b3bd-4e417f402562)
DEBUG:main:Using identically-named object "System-Standard"
DEBUG:main:Referenced object not available in target (pkiprofile/pkiprofile-a7a4c2a8-ea55-473b-b499-c47da9f86ab2)
DEBUG:main:Using identically-named object "Let's Encrypt"
DEBUG:main:Referenced object not available in target (analyticsprofile/analyticsprofile-3eab3432-1574-444c-bfc6-a0971f321ade)
DEBUG:main:Using identically-named object "System-Analytics-Profile"
DEBUG:main:Creating pool "-pool"...
DEBUG:main:Created pool "https:///api/pool/pool-46f785c2-13f9-4dce-af2e-836f6d123e6b#-pool"
DEBUG:main:Cloning httppolicyset "httppolicyset/httppolicyset-0ed2ba49-9795-46a0-bb4d-8f6bb5671186" to "--vdp-nsxmanager-HTTP-Policy-Set"
DEBUG:main:Forced unique name "--vdp-nsxmanager-HTTP-Policy-Set-1"
DEBUG:main:Running _processobject_httppolicyset
DEBUG:main:Processing http_security_policy
DEBUG:main:Running _process_policy_rules
DEBUG:main:Checking rule "Block health subpage"...
DEBUG:main:Cloning forced refs for --vdp-nsxmanager-HTTP-Policy-Set-1
DEBUG:main:Cloning refs
DEBUG:main:Referenced object not available in target (ipaddrgroup/ipaddrgroup-b056a239-9f91-4e82-a3b5-5bce95c25f19)
DEBUG:main:Using identically-named object "Icinga Backend"
DEBUG:main:Referenced object not available in target (ipaddrgroup/ipaddrgroup-c953c8f3-3e04-4d18-8189-2948034ae995)
DEBUG:main:Using identically-named object "Icinga Frontend"
DEBUG:main:Cloning forced refs for --vdp-nsxmanager-HTTP-Policy-Set-1
DEBUG:main:Cloning refs
DEBUG:main:Creating httppolicyset "--vdp-nsxmanager-HTTP-Policy-Set-1"...
DEBUG:main:Created httppolicyset "https:///api/httppolicyset/httppolicyset-52d05d72-757f-4d66-a1a7-3bf16b39b5d4#--vdp-nsxmanager-HTTP-Policy-Set-1"
DEBUG:main:Cloning networksecuritypolicy "networksecuritypolicy/networksecuritypolicy-7d9ad9de-780f-4107-bf7f-da8e45a55443" to "vs---vdp-nsxmanager-ns"
DEBUG:main:Forced unique name "vs---vdp-nsxmanager-ns-1"
DEBUG:main:Running _processobject_networksecuritypolicy
DEBUG:main:Running _process_policy_rules
DEBUG:main:Creating networksecuritypolicy "vs---vdp-nsxmanager-ns-1"...
DEBUG:main:Created networksecuritypolicy "https:///api/networksecuritypolicy/networksecuritypolicy-68175291-3a80-40d6-813f-7cc432ef803e#vs---vdp-nsxmanager-ns-1"
DEBUG:main:Cloning forced refs for
DEBUG:main:Cloning refs for
DEBUG:main:Referenced object not available in target (applicationprofile/applicationprofile-c45c68b5-c665-4f57-950a-58f1dd76170d)
DEBUG:main:Using identically-named object "System-Secure-HTTP"
DEBUG:main:Referenced object not available in target (networkprofile/networkprofile-b7c526f9-5e5b-41b4-8513-fad0c521958b)
DEBUG:main:Using identically-named object "System-TCP-Proxy"
DEBUG:main:Referenced object not available in target (analyticsprofile/analyticsprofile-3eab3432-1574-444c-bfc6-a0971f321ade)
DEBUG:main:Using identically-named object "System-Analytics-Profile"
DEBUG:main:Referenced object not available in target (errorpageprofile/errorpageprofile-55c31cb0-cdd0-4f00-aa72-6e7292f4ca72)
DEBUG:main:Using identically-named object "Custom-Error-Page-Profile"
DEBUG:main:Referenced object not available in target (sslprofile/sslprofile-22021efe-a736-4858-b790-97c67619009d)
DEBUG:main:Using identically-named object "TLS1.3"
DEBUG:main:Referenced object not available in target (sslkeyandcertificate/sslkeyandcertificate-64d91898-cf02-4fe5-be63-39e7cee61f77)
DEBUG:main:Using identically-named object "*."
DEBUG:main:Referenced object not available in target (wafpolicy/wafpolicy-11ad1fb4-cd76-4963-b8f2-22ed5706b6e6)
DEBUG:main:Cloning wafpolicy "wafpolicy/wafpolicy-11ad1fb4-cd76-4963-b8f2-22ed5706b6e6" to ""
DEBUG:main:Running _process_wafpolicy
DEBUG:main:Cloning forced refs for
DEBUG:main:Cloning refs for
DEBUG:main:Referenced object not available in target (wafprofile/wafprofile-be3455f7-3064-44e5-9a48-45f20abd4bfc)
DEBUG:main:Using identically-named object "System-WAF-Profile"
DEBUG:main:Referenced object not available in target (wafcrs/wafcrs-6502c81b-4222-4e70-bd55-19cadef7b7b7)
DEBUG:main:Using identically-named object "CRS-2021-4"
DEBUG:main:Creating wafpolicy ""...
DEBUG:main:Created wafpolicy "https:///api/wafpolicy/wafpolicy-52a0107f-8107-4dd7-9640-92a381334936#"
DEBUG:main:Referenced object not available in target (stringgroup/stringgroup-9e470782-55bc-4238-a9de-68c1b122c108)
DEBUG:main:Using identically-named object "System-Rewritable-Content-Types"
DEBUG:main:Unable to clone Virtual Service "" as "" (400:{"error": "VRF Context for and pool -pool different"})
DEBUG:main:{'active_standby_se_tag': 'ACTIVE_STANDBY_SE_1', 'advertise_down_vs': False, 'allow_invalid_client_cert': False, 'analytics_policy': {'all_headers': True, 'client_insights': 'PASSIVE', 'full_client_logs': {'duration': 0, 'enabled': True, 'throttle': 10}, 'learning_log_policy': {'enabled': False}, 'metrics_realtime_update': {'duration': 0, 'enabled': True}, 'significant_log_throttle': 10, 'udf_log_throttle': 10}, 'analytics_profile_ref': 'https:///api/analyticsprofile/analyticsprofile-ef0fd444-d4a0-4832-bcdd-5b70152554d2', 'application_profile_ref': 'https:///api/applicationprofile/applicationprofile-c0d47a18-6ad9-4b3e-b9e4-a3512e84dcb3', 'bulk_sync_kvcache': False, 'close_client_conn_on_config_update': False, 'cloud_ref': 'https:///api/cloud/cloud-01d79d5b-6f39-40f0-b96a-6c001718fe94', 'content_rewrite': {'rewritable_content_ref': 'https:///api/stringgroup/stringgroup-80fef96a-cd5c-4a80-b18e-66a95ca04328', 'rsp_rewrite_rules': [{'enable': False}]}, 'delay_fairness': False, 'east_west_placement': False, 'enable_autogw': True, 'enabled': False, 'error_page_profile_ref': 'https:///api/errorpageprofile/errorpageprofile-bd2ccb15-9bd4-46c2-a2d8-3b20fb1f681d', 'flow_dist': 'LOAD_AWARE', 'flow_label_type': 'NO_LABEL', 'http_policies': [{'http_policy_set_ref': 'https:///api/httppolicyset/httppolicyset-52d05d72-757f-4d66-a1a7-3bf16b39b5d4#--vdp-nsxmanager-HTTP-Policy-Set-1', 'index': 11}], 'ign_pool_net_reach': False, 'limit_doser': False, 'marked_for_delete': False, 'max_cps_per_client': 0, 'name': '', 'network_profile_ref': 'https:///api/networkprofile/networkprofile-af5c415b-360c-4586-aa80-809c8f49a677', 'network_security_policy_ref': 'https:///api/networksecuritypolicy/networksecuritypolicy-68175291-3a80-40d6-813f-7cc432ef803e#vs---vdp-nsxmanager-ns-1', 'pool_ref': 'https:///api/pool/pool-46f785c2-13f9-4dce-af2e-836f6d123e6b#-pool', 'redis_db': 14, 'redis_port': 5021, 'remove_listening_port_on_vs_down': False, 'scaleout_ecmp': True, 'se_group_ref': 'https:///api/serviceenginegroup/serviceenginegroup-8a6d0faf-dbff-45e2-a9fb-927e0d848b79', 'self_se_election': False, 'sideband_profile': {'sideband_max_request_body_size': 1024}, 'ssl_key_and_certificate_refs': ['https:///api/sslkeyandcertificate/sslkeyandcertificate-6035edc2-00fd-4291-9885-53e0e66ca5bd'], 'ssl_profile_ref': 'https:///api/sslprofile/sslprofile-8fb3db7e-9a6d-43bf-a7a2-338178717cc4', 'ssl_sess_cache_avg_size': 1024, 'tenant_ref': 'https:///api/tenant/tenant-bfa88839-76f0-4334-a337-493b0d226f80', 'tls_ticket_key': [{'aes_key': 'EY8hedwCpIDNVcIpL7rO1g==', 'hmac_key': 'zEl2T5WlFXX+LGj1u+I3dg==', 'name': '6eada99c-84e1-4bd4-82da-ab0b47549cdc'}, {'aes_key': 'q4ZdS08Vyh0wMFyelFVEoA==', 'hmac_key': 'J/1j01mi4RU0oyqtijSJIA==', 'name': '8850174f-fa01-4534-ba3c-d8676a1b7aef'}, {'aes_key': '68nTDu05HqxE4fQgjPHREQ==', 'hmac_key': '0O7gfkewf0F12zw2NtXWFA==', 'name': '3e8f21b2-5247-4c86-b623-fbb496dc7045'}], 'traffic_enabled': True, 'type': 'VS_TYPE_VH_CHILD', 'use_bridge_ip_as_vip': False, 'use_vip_as_snat': False, 'version': 2625, 'vh_domain_name': [''], 'vh_parent_vs_ref': 'https:///api/virtualservice/virtualservice-478c26db-f755-4667-83b9-3278bb7c4f93', 'vh_type': 'VS_TYPE_VH_SNI', 'waf_policy_ref': 'https:///api/wafpolicy/wafpolicy-52a0107f-8107-4dd7-9640-92a381334936#', 'weight': 1}
DEBUG:main:Deleting created objects...
DEBUG:main:Trying to delete pool/pool-46f785c2-13f9-4dce-af2e-836f6d123e6b#-pool
DEBUG:main:Trying to delete httppolicyset/httppolicyset-52d05d72-757f-4d66-a1a7-3bf16b39b5d4#--vdp-nsxmanager-HTTP-Policy-Set-1
DEBUG:main:Trying to delete networksecuritypolicy/networksecuritypolicy-68175291-3a80-40d6-813f-7cc432ef803e#vs---vdp-nsxmanager-ns-1
DEBUG:main:Trying to delete wafpolicy/wafpolicy-52a0107f-8107-4dd7-9640-92a381334936#
Unable to clone Virtual Service "" as "" (400:{"error": "VRF Context for and pool -pool different"})
=> Unable to clone Virtual Service "" as ""`
I am trying to use Avi Go SDK to fetch a gslb configuration.
First initializing a connection to the controller as below,
aviClient, err := clients.NewAviClient("mycontroller", "USER", session.SetPassword("PASSS"), session.SetTenant("TENANT"), session.SetInsecure) if err != nil { t.Error(err) }
Then trying to grab a gslb details as below,
var gslbmap map[string]interface{} err = aviClient.AviSession.GetObjectByName("gslbservice", "GSLBNAME", &gslbmap) if err != nil { t.Error(err) }
and now gslbmap has below,
map[_last_modified:1650419741251661 controller_health_status_enabled:true created_by:null description:null domain_names:[xxxxxxxxxxxxx] down_response:map[type:GSLB_SERVICE_DOWN_RESPONSE_ALL_RECORDS] enabled:true groups:[map[algorithm:GSLB_ALGORITHM_ROUND_ROBIN members:[map[cluster_uuid:xxxxxxxxxxxxxxxxxxxx enabled:true fqdn:xxxxxxxxxxxxxxxxxxxxxxxxx ip:map[addr:xxxxxxxxxxxxxxx type:V4] location:map[source:GSLB_LOCATION_SRC_INHERIT_FROM_SITE] ratio:1]] name:xxxxxxxxxxxxxxxxxxxxxxx priority:10]] health_monitor_refs:[https://xxxxxxxxxxxxxxxx] health_monitor_scope:GSLB_SERVICE_HEALTH_MONITOR_ALL_MEMBERS name:xxxxxxxxxxxxxxxx num_dns_ip:1 tenant_ref:https://xxxxxxxxxxxxxxxxxxx ttl:30 url:https://xxxxxxxxxxxxxxxxxxxx use_edns_client_subnet:true uuid:xxxxxxxxxxxxxxxxxxx wildcard_match:false]
I am trying to assert against each item on the map as below and they work.
assert.Equal(t, bool(true), gslbmap["enabled"]) assert.Equal(t, bool(true), gslbmap["use_edns_client_subnet"]) assert.Equal(t, gslbmap["domain_names"], []interface {}([]interface {}{"GSLBNAME"}))
But there is map inside map (groups) How can I access algorithm or priority from groups?
Hi, I am very new to python and was trying to use avisdk to fetch some config from AVI vantage controller. After importing the repository on my venv in pycharm, when I am trying to establish a session, I am getting the 401 unauthorized error. I am using the below command,
api = ApiSession.get_session("controller_ip", "username", "password")
Would it be possible for someone to help me out.
Hello,
Reaching out because we are encountering another issue with the avi migration tools sdk for the netscaler converter tool. As previously advised, we are using the docker container on an ubuntu vm. However, when we run the tool to convert the ns.conf file into the json output and auto-upload into the avi appliance after a few minutes the operation seems to timeout and fail. Any further guidance you can provide to assist us with importing this config into the alb? From the ubuntu device we are able to ping the appliance, and browse to it on firefox, below is the error dump (obfuscated IP and password, btw using the admin account for cli access with the correct password)
ErrorOutput.odt
1.Run the following command sudo ./run.sh -c "netscaler_converter.py -f ns.conf -s disable -O auto-upload -c x.x.x.240 -u admin -p $a -t admin"
2.
3.
...
Expected for the JSON file generated to be successfully uploaded into the ALB
No response
the clients.NewAviClient function will raised a nil point panic if the avi-controller host can not be accessed. when I specify a wrong avi-controller host ip, I encounter the below error message:
goroutine 566 [running]:
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Reconcile.func1()
/go/pkg/mod/sigs.k8s.io/[[email protected]](mailto:[email protected])/pkg/internal/controller/controller.go:118 +0x1f4
panic({0x2455b20, 0x440dbc0})
/usr/local/go/src/runtime/panic.go:838 +0x207
github.com/vmware/alb-sdk/go/session.(*AviSession).restRequest(0xc0015fa000, {0x29639f8, 0x4}, {0x2965463, 0x5}, {0x2437800, 0xc0030e5950}, {0x0, 0x0}, {0x0, ...}, ...)
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/session/avisession.go:713 +0x52b
github.com/vmware/alb-sdk/go/session.(*AviSession).restRequestInterfaceResponse(0xc001b88b01?, {0x29639f8, 0x4}, {0x2965463, 0x5}, {0x2437800, 0xc0030e5950}, {0x0, 0x0}, {0x0, ...})
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/session/avisession.go:1108 +0x17b
github.com/vmware/alb-sdk/go/session.(*AviSession).Post(0x8?, {0x2965463?, 0x30?}, {0x2437800?, 0xc0030e5950?}, {0x0?, 0x0?}, {0x0, 0x0, 0x0})
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/session/avisession.go:1131 +0x85
github.com/vmware/alb-sdk/go/session.(*AviSession).initiateSession(0xc0015fa000)
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/session/avisession.go:390 +0x2b8
github.com/vmware/alb-sdk/go/session.NewAviSession({0xc001b9f930, 0xe}, {0xc001b9f948, 0x5}, {0xc001392dc0, 0x4, 0x20?})
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/session/avisession.go:350 +0x3a9
github.com/vmware/alb-sdk/go/clients.NewAviClient({0xc001b9f930, 0xe}, {0xc001b9f948, 0x5}, {0xc001392dc0, 0x4, 0x4})
/go/pkg/mod/github.com/vmware/[[email protected]](mailto:[email protected])/go/clients/avi_client.go:164 +0x85
It's easy to reproduce, such as the demo-code below:
package main
import (
"fmt"
cli "github.com/vmware/alb-sdk/go/clients"
"github.com/vmware/alb-sdk/go/session"
)
const (
AviControllerRetryCount = 1
AviControllerRetryInterval = 1
)
func main() {
options := []func(*session.AviSession) error{
session.SetPassword("your_passwork"),
session.SetControllerStatusCheckLimits(AviControllerRetryCount, AviControllerRetryInterval),
}
options = append(options, session.SetInsecure)
_, err := cli.NewAviClient("avi_controller_ip", "avi_user", options...)
if err != nil {
fmt.Println("error occurred, it's not the panic which can be caught here...")
}
}
The nil point runtime panic should be handled in alb-sdk, although maybe we can catch the panic and handle it in local project.
No response
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.