control.pb.go 338 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966119671196811969119701197111972119731197411975119761197711978119791198011981119821198311984119851198611987119881198911990119911199211993119941199511996119971199811999120001200112002120031200412005120061200712008120091201012011120121201312014120151201612017120181201912020120211202212023120241202512026120271202812029120301203112032120331203412035120361203712038120391204012041120421204312044120451204612047120481204912050120511205212053120541205512056120571205812059120601206112062120631206412065120661206712068120691207012071120721207312074120751207612077120781207912080120811208212083120841208512086120871208812089120901209112092120931209412095120961209712098120991210012101121021210312104121051210612107121081210912110121111211212113121141211512116121171211812119121201212112122121231212412125121261212712128121291213012131121321213312134121351213612137121381213912140121411214212143121441214512146121471214812149121501215112152121531215412155121561215712158121591216012161121621216312164121651216612167121681216912170121711217212173121741217512176121771217812179121801218112182121831218412185121861218712188121891219012191121921219312194121951219612197121981219912200122011220212203122041220512206122071220812209122101221112212122131221412215122161221712218122191222012221122221222312224122251222612227122281222912230122311223212233122341223512236122371223812239122401224112242122431224412245122461224712248122491225012251122521225312254122551225612257122581225912260122611226212263122641226512266122671226812269122701227112272122731227412275122761227712278122791228012281122821228312284122851228612287122881228912290122911229212293122941229512296122971229812299123001230112302123031230412305123061230712308123091231012311123121231312314123151231612317123181231912320123211232212323123241232512326123271232812329123301233112332123331233412335123361233712338123391234012341123421234312344123451234612347123481234912350123511235212353123541235512356123571235812359123601236112362123631236412365123661236712368123691237012371123721237312374123751237612377123781237912380123811238212383123841238512386123871238812389123901239112392123931239412395123961239712398123991240012401124021240312404124051240612407124081240912410124111241212413124141241512416124171241812419124201242112422124231242412425124261242712428124291243012431124321243312434124351243612437124381243912440124411244212443124441244512446124471244812449124501245112452124531245412455124561245712458124591246012461124621246312464124651246612467124681246912470124711247212473124741247512476124771247812479124801248112482124831248412485124861248712488124891249012491124921249312494124951249612497124981249912500125011250212503125041250512506125071250812509125101251112512125131251412515125161251712518125191252012521125221252312524125251252612527125281252912530125311253212533125341253512536125371253812539125401254112542125431254412545125461254712548125491255012551125521255312554125551255612557125581255912560125611256212563125641256512566125671256812569125701257112572125731257412575125761257712578125791258012581125821258312584125851258612587125881258912590125911259212593125941259512596125971259812599126001260112602126031260412605126061260712608126091261012611126121261312614126151261612617126181261912620126211262212623126241262512626126271262812629126301263112632126331263412635126361263712638126391264012641126421264312644126451264612647126481264912650126511265212653126541265512656126571265812659126601266112662126631266412665126661266712668126691267012671126721267312674126751267612677126781267912680126811268212683126841268512686126871268812689126901269112692126931269412695126961269712698126991270012701127021270312704127051270612707127081270912710127111271212713127141271512716127171271812719127201272112722127231272412725127261272712728127291273012731127321273312734127351273612737127381273912740127411274212743127441274512746127471274812749127501275112752127531275412755127561275712758127591276012761127621276312764127651276612767127681276912770127711277212773127741277512776127771277812779127801278112782127831278412785127861278712788127891279012791127921279312794127951279612797127981279912800128011280212803128041280512806128071280812809128101281112812128131281412815128161281712818128191282012821128221282312824128251282612827128281282912830128311283212833128341283512836128371283812839128401284112842128431284412845128461284712848128491285012851128521285312854128551285612857128581285912860128611286212863128641286512866128671286812869128701287112872128731287412875128761287712878128791288012881128821288312884128851288612887128881288912890128911289212893128941289512896128971289812899129001290112902129031290412905129061290712908129091291012911129121291312914129151291612917129181291912920129211292212923129241292512926129271292812929129301293112932129331293412935129361293712938129391294012941129421294312944129451294612947129481294912950129511295212953129541295512956129571295812959129601296112962129631296412965129661296712968129691297012971129721297312974129751297612977129781297912980129811298212983129841298512986129871298812989129901299112992129931299412995129961299712998129991300013001130021300313004130051300613007130081300913010130111301213013130141301513016130171301813019130201302113022130231302413025130261302713028130291303013031130321303313034130351303613037130381303913040130411304213043130441304513046130471304813049130501305113052130531305413055130561305713058130591306013061130621306313064130651306613067130681306913070130711307213073130741307513076130771307813079130801308113082130831308413085130861308713088130891309013091130921309313094130951309613097130981309913100131011310213103131041310513106131071310813109131101311113112131131311413115131161311713118131191312013121131221312313124131251312613127131281312913130131311313213133131341313513136131371313813139131401314113142131431314413145131461314713148131491315013151131521315313154131551315613157131581315913160131611316213163131641316513166131671316813169131701317113172131731317413175131761317713178131791318013181131821318313184131851318613187131881318913190131911319213193131941319513196131971319813199132001320113202132031320413205132061320713208132091321013211132121321313214132151321613217132181321913220132211322213223132241322513226132271322813229132301323113232132331323413235132361323713238132391324013241132421324313244132451324613247132481324913250132511325213253132541325513256132571325813259132601326113262132631326413265132661326713268132691327013271132721327313274132751327613277132781327913280132811328213283132841328513286132871328813289132901329113292132931329413295132961329713298132991330013301133021330313304133051330613307133081330913310133111331213313133141331513316133171331813319133201332113322133231332413325133261332713328133291333013331133321333313334133351333613337133381333913340133411334213343133441334513346133471334813349133501335113352133531335413355133561335713358133591336013361133621336313364133651336613367133681336913370133711337213373133741337513376133771337813379133801338113382133831338413385133861338713388133891339013391133921339313394133951339613397133981339913400134011340213403134041340513406134071340813409134101341113412134131341413415134161341713418134191342013421134221342313424134251342613427134281342913430134311343213433134341343513436134371343813439134401344113442134431344413445134461344713448134491345013451134521345313454134551345613457134581345913460134611346213463134641346513466134671346813469134701347113472134731347413475134761347713478134791348013481134821348313484134851348613487134881348913490134911349213493134941349513496134971349813499135001350113502135031350413505135061350713508135091351013511135121351313514135151351613517135181351913520135211352213523135241352513526135271352813529135301353113532135331353413535135361353713538135391354013541135421354313544135451354613547135481354913550135511355213553135541355513556135571355813559135601356113562135631356413565135661356713568135691357013571135721357313574135751357613577135781357913580135811358213583135841358513586135871358813589135901359113592135931359413595135961359713598135991360013601136021360313604136051360613607136081360913610136111361213613136141361513616136171361813619136201362113622136231362413625136261362713628136291363013631136321363313634136351363613637136381363913640136411364213643136441364513646136471364813649136501365113652136531365413655136561365713658136591366013661136621366313664136651366613667136681366913670
  1. // Code generated by protoc-gen-gogo.
  2. // source: control.proto
  3. // DO NOT EDIT!
  4. package api
  5. import proto "github.com/gogo/protobuf/proto"
  6. import fmt "fmt"
  7. import math "math"
  8. import _ "github.com/gogo/protobuf/gogoproto"
  9. import _ "github.com/docker/swarmkit/protobuf/plugin"
  10. import strings "strings"
  11. import github_com_gogo_protobuf_proto "github.com/gogo/protobuf/proto"
  12. import sort "sort"
  13. import strconv "strconv"
  14. import reflect "reflect"
  15. import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys"
  16. import (
  17. context "golang.org/x/net/context"
  18. grpc "google.golang.org/grpc"
  19. )
  20. import raftselector "github.com/docker/swarmkit/manager/raftselector"
  21. import codes "google.golang.org/grpc/codes"
  22. import metadata "google.golang.org/grpc/metadata"
  23. import transport "google.golang.org/grpc/transport"
  24. import time "time"
  25. import io "io"
  26. // Reference imports to suppress errors if they are not otherwise used.
  27. var _ = proto.Marshal
  28. var _ = fmt.Errorf
  29. var _ = math.Inf
  30. type GetNodeRequest struct {
  31. NodeID string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"`
  32. }
  33. func (m *GetNodeRequest) Reset() { *m = GetNodeRequest{} }
  34. func (*GetNodeRequest) ProtoMessage() {}
  35. func (*GetNodeRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{0} }
  36. type GetNodeResponse struct {
  37. Node *Node `protobuf:"bytes,1,opt,name=node" json:"node,omitempty"`
  38. }
  39. func (m *GetNodeResponse) Reset() { *m = GetNodeResponse{} }
  40. func (*GetNodeResponse) ProtoMessage() {}
  41. func (*GetNodeResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{1} }
  42. type ListNodesRequest struct {
  43. Filters *ListNodesRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  44. }
  45. func (m *ListNodesRequest) Reset() { *m = ListNodesRequest{} }
  46. func (*ListNodesRequest) ProtoMessage() {}
  47. func (*ListNodesRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{2} }
  48. type ListNodesRequest_Filters struct {
  49. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  50. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  51. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  52. Memberships []NodeSpec_Membership `protobuf:"varint,4,rep,name=memberships,enum=docker.swarmkit.v1.NodeSpec_Membership" json:"memberships,omitempty"`
  53. Roles []NodeRole `protobuf:"varint,5,rep,name=roles,enum=docker.swarmkit.v1.NodeRole" json:"roles,omitempty"`
  54. // NamePrefixes matches all objects with the given prefixes
  55. NamePrefixes []string `protobuf:"bytes,6,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  56. }
  57. func (m *ListNodesRequest_Filters) Reset() { *m = ListNodesRequest_Filters{} }
  58. func (*ListNodesRequest_Filters) ProtoMessage() {}
  59. func (*ListNodesRequest_Filters) Descriptor() ([]byte, []int) {
  60. return fileDescriptorControl, []int{2, 0}
  61. }
  62. type ListNodesResponse struct {
  63. Nodes []*Node `protobuf:"bytes,1,rep,name=nodes" json:"nodes,omitempty"`
  64. }
  65. func (m *ListNodesResponse) Reset() { *m = ListNodesResponse{} }
  66. func (*ListNodesResponse) ProtoMessage() {}
  67. func (*ListNodesResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{3} }
  68. // UpdateNodeRequest requests an update to the specified node. This may be used
  69. // to request a new availability for a node, such as PAUSE. Invalid updates
  70. // will be denied and cause an error.
  71. type UpdateNodeRequest struct {
  72. NodeID string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"`
  73. NodeVersion *Version `protobuf:"bytes,2,opt,name=node_version,json=nodeVersion" json:"node_version,omitempty"`
  74. Spec *NodeSpec `protobuf:"bytes,3,opt,name=spec" json:"spec,omitempty"`
  75. }
  76. func (m *UpdateNodeRequest) Reset() { *m = UpdateNodeRequest{} }
  77. func (*UpdateNodeRequest) ProtoMessage() {}
  78. func (*UpdateNodeRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{4} }
  79. type UpdateNodeResponse struct {
  80. Node *Node `protobuf:"bytes,1,opt,name=node" json:"node,omitempty"`
  81. }
  82. func (m *UpdateNodeResponse) Reset() { *m = UpdateNodeResponse{} }
  83. func (*UpdateNodeResponse) ProtoMessage() {}
  84. func (*UpdateNodeResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{5} }
  85. // RemoveNodeRequest requests to delete the specified node from store.
  86. type RemoveNodeRequest struct {
  87. NodeID string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"`
  88. Force bool `protobuf:"varint,2,opt,name=force,proto3" json:"force,omitempty"`
  89. }
  90. func (m *RemoveNodeRequest) Reset() { *m = RemoveNodeRequest{} }
  91. func (*RemoveNodeRequest) ProtoMessage() {}
  92. func (*RemoveNodeRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{6} }
  93. type RemoveNodeResponse struct {
  94. }
  95. func (m *RemoveNodeResponse) Reset() { *m = RemoveNodeResponse{} }
  96. func (*RemoveNodeResponse) ProtoMessage() {}
  97. func (*RemoveNodeResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{7} }
  98. type GetTaskRequest struct {
  99. TaskID string `protobuf:"bytes,1,opt,name=task_id,json=taskId,proto3" json:"task_id,omitempty"`
  100. }
  101. func (m *GetTaskRequest) Reset() { *m = GetTaskRequest{} }
  102. func (*GetTaskRequest) ProtoMessage() {}
  103. func (*GetTaskRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{8} }
  104. type GetTaskResponse struct {
  105. Task *Task `protobuf:"bytes,1,opt,name=task" json:"task,omitempty"`
  106. }
  107. func (m *GetTaskResponse) Reset() { *m = GetTaskResponse{} }
  108. func (*GetTaskResponse) ProtoMessage() {}
  109. func (*GetTaskResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{9} }
  110. type RemoveTaskRequest struct {
  111. TaskID string `protobuf:"bytes,1,opt,name=task_id,json=taskId,proto3" json:"task_id,omitempty"`
  112. }
  113. func (m *RemoveTaskRequest) Reset() { *m = RemoveTaskRequest{} }
  114. func (*RemoveTaskRequest) ProtoMessage() {}
  115. func (*RemoveTaskRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{10} }
  116. type RemoveTaskResponse struct {
  117. }
  118. func (m *RemoveTaskResponse) Reset() { *m = RemoveTaskResponse{} }
  119. func (*RemoveTaskResponse) ProtoMessage() {}
  120. func (*RemoveTaskResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{11} }
  121. type ListTasksRequest struct {
  122. Filters *ListTasksRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  123. }
  124. func (m *ListTasksRequest) Reset() { *m = ListTasksRequest{} }
  125. func (*ListTasksRequest) ProtoMessage() {}
  126. func (*ListTasksRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{12} }
  127. type ListTasksRequest_Filters struct {
  128. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  129. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  130. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  131. ServiceIDs []string `protobuf:"bytes,4,rep,name=service_ids,json=serviceIds" json:"service_ids,omitempty"`
  132. NodeIDs []string `protobuf:"bytes,5,rep,name=node_ids,json=nodeIds" json:"node_ids,omitempty"`
  133. DesiredStates []TaskState `protobuf:"varint,6,rep,name=desired_states,json=desiredStates,enum=docker.swarmkit.v1.TaskState" json:"desired_states,omitempty"`
  134. // NamePrefixes matches all objects with the given prefixes
  135. NamePrefixes []string `protobuf:"bytes,7,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  136. }
  137. func (m *ListTasksRequest_Filters) Reset() { *m = ListTasksRequest_Filters{} }
  138. func (*ListTasksRequest_Filters) ProtoMessage() {}
  139. func (*ListTasksRequest_Filters) Descriptor() ([]byte, []int) {
  140. return fileDescriptorControl, []int{12, 0}
  141. }
  142. type ListTasksResponse struct {
  143. Tasks []*Task `protobuf:"bytes,1,rep,name=tasks" json:"tasks,omitempty"`
  144. }
  145. func (m *ListTasksResponse) Reset() { *m = ListTasksResponse{} }
  146. func (*ListTasksResponse) ProtoMessage() {}
  147. func (*ListTasksResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{13} }
  148. type CreateServiceRequest struct {
  149. Spec *ServiceSpec `protobuf:"bytes,1,opt,name=spec" json:"spec,omitempty"`
  150. }
  151. func (m *CreateServiceRequest) Reset() { *m = CreateServiceRequest{} }
  152. func (*CreateServiceRequest) ProtoMessage() {}
  153. func (*CreateServiceRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{14} }
  154. type CreateServiceResponse struct {
  155. Service *Service `protobuf:"bytes,1,opt,name=service" json:"service,omitempty"`
  156. }
  157. func (m *CreateServiceResponse) Reset() { *m = CreateServiceResponse{} }
  158. func (*CreateServiceResponse) ProtoMessage() {}
  159. func (*CreateServiceResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{15} }
  160. type GetServiceRequest struct {
  161. ServiceID string `protobuf:"bytes,1,opt,name=service_id,json=serviceId,proto3" json:"service_id,omitempty"`
  162. }
  163. func (m *GetServiceRequest) Reset() { *m = GetServiceRequest{} }
  164. func (*GetServiceRequest) ProtoMessage() {}
  165. func (*GetServiceRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{16} }
  166. type GetServiceResponse struct {
  167. Service *Service `protobuf:"bytes,1,opt,name=service" json:"service,omitempty"`
  168. }
  169. func (m *GetServiceResponse) Reset() { *m = GetServiceResponse{} }
  170. func (*GetServiceResponse) ProtoMessage() {}
  171. func (*GetServiceResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{17} }
  172. type UpdateServiceRequest struct {
  173. ServiceID string `protobuf:"bytes,1,opt,name=service_id,json=serviceId,proto3" json:"service_id,omitempty"`
  174. ServiceVersion *Version `protobuf:"bytes,2,opt,name=service_version,json=serviceVersion" json:"service_version,omitempty"`
  175. Spec *ServiceSpec `protobuf:"bytes,3,opt,name=spec" json:"spec,omitempty"`
  176. }
  177. func (m *UpdateServiceRequest) Reset() { *m = UpdateServiceRequest{} }
  178. func (*UpdateServiceRequest) ProtoMessage() {}
  179. func (*UpdateServiceRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{18} }
  180. type UpdateServiceResponse struct {
  181. Service *Service `protobuf:"bytes,1,opt,name=service" json:"service,omitempty"`
  182. }
  183. func (m *UpdateServiceResponse) Reset() { *m = UpdateServiceResponse{} }
  184. func (*UpdateServiceResponse) ProtoMessage() {}
  185. func (*UpdateServiceResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{19} }
  186. type RemoveServiceRequest struct {
  187. ServiceID string `protobuf:"bytes,1,opt,name=service_id,json=serviceId,proto3" json:"service_id,omitempty"`
  188. }
  189. func (m *RemoveServiceRequest) Reset() { *m = RemoveServiceRequest{} }
  190. func (*RemoveServiceRequest) ProtoMessage() {}
  191. func (*RemoveServiceRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{20} }
  192. type RemoveServiceResponse struct {
  193. }
  194. func (m *RemoveServiceResponse) Reset() { *m = RemoveServiceResponse{} }
  195. func (*RemoveServiceResponse) ProtoMessage() {}
  196. func (*RemoveServiceResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{21} }
  197. type ListServicesRequest struct {
  198. Filters *ListServicesRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  199. }
  200. func (m *ListServicesRequest) Reset() { *m = ListServicesRequest{} }
  201. func (*ListServicesRequest) ProtoMessage() {}
  202. func (*ListServicesRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{22} }
  203. type ListServicesRequest_Filters struct {
  204. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  205. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  206. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  207. // NamePrefixes matches all objects with the given prefixes
  208. NamePrefixes []string `protobuf:"bytes,4,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  209. }
  210. func (m *ListServicesRequest_Filters) Reset() { *m = ListServicesRequest_Filters{} }
  211. func (*ListServicesRequest_Filters) ProtoMessage() {}
  212. func (*ListServicesRequest_Filters) Descriptor() ([]byte, []int) {
  213. return fileDescriptorControl, []int{22, 0}
  214. }
  215. type ListServicesResponse struct {
  216. Services []*Service `protobuf:"bytes,1,rep,name=services" json:"services,omitempty"`
  217. }
  218. func (m *ListServicesResponse) Reset() { *m = ListServicesResponse{} }
  219. func (*ListServicesResponse) ProtoMessage() {}
  220. func (*ListServicesResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{23} }
  221. type CreateNetworkRequest struct {
  222. Spec *NetworkSpec `protobuf:"bytes,1,opt,name=spec" json:"spec,omitempty"`
  223. }
  224. func (m *CreateNetworkRequest) Reset() { *m = CreateNetworkRequest{} }
  225. func (*CreateNetworkRequest) ProtoMessage() {}
  226. func (*CreateNetworkRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{24} }
  227. type CreateNetworkResponse struct {
  228. Network *Network `protobuf:"bytes,1,opt,name=network" json:"network,omitempty"`
  229. }
  230. func (m *CreateNetworkResponse) Reset() { *m = CreateNetworkResponse{} }
  231. func (*CreateNetworkResponse) ProtoMessage() {}
  232. func (*CreateNetworkResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{25} }
  233. type GetNetworkRequest struct {
  234. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
  235. NetworkID string `protobuf:"bytes,2,opt,name=network_id,json=networkId,proto3" json:"network_id,omitempty"`
  236. }
  237. func (m *GetNetworkRequest) Reset() { *m = GetNetworkRequest{} }
  238. func (*GetNetworkRequest) ProtoMessage() {}
  239. func (*GetNetworkRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{26} }
  240. type GetNetworkResponse struct {
  241. Network *Network `protobuf:"bytes,1,opt,name=network" json:"network,omitempty"`
  242. }
  243. func (m *GetNetworkResponse) Reset() { *m = GetNetworkResponse{} }
  244. func (*GetNetworkResponse) ProtoMessage() {}
  245. func (*GetNetworkResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{27} }
  246. type RemoveNetworkRequest struct {
  247. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
  248. NetworkID string `protobuf:"bytes,2,opt,name=network_id,json=networkId,proto3" json:"network_id,omitempty"`
  249. }
  250. func (m *RemoveNetworkRequest) Reset() { *m = RemoveNetworkRequest{} }
  251. func (*RemoveNetworkRequest) ProtoMessage() {}
  252. func (*RemoveNetworkRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{28} }
  253. type RemoveNetworkResponse struct {
  254. }
  255. func (m *RemoveNetworkResponse) Reset() { *m = RemoveNetworkResponse{} }
  256. func (*RemoveNetworkResponse) ProtoMessage() {}
  257. func (*RemoveNetworkResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{29} }
  258. type ListNetworksRequest struct {
  259. Filters *ListNetworksRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  260. }
  261. func (m *ListNetworksRequest) Reset() { *m = ListNetworksRequest{} }
  262. func (*ListNetworksRequest) ProtoMessage() {}
  263. func (*ListNetworksRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{30} }
  264. type ListNetworksRequest_Filters struct {
  265. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  266. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  267. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  268. // NamePrefixes matches all objects with the given prefixes
  269. NamePrefixes []string `protobuf:"bytes,4,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  270. }
  271. func (m *ListNetworksRequest_Filters) Reset() { *m = ListNetworksRequest_Filters{} }
  272. func (*ListNetworksRequest_Filters) ProtoMessage() {}
  273. func (*ListNetworksRequest_Filters) Descriptor() ([]byte, []int) {
  274. return fileDescriptorControl, []int{30, 0}
  275. }
  276. type ListNetworksResponse struct {
  277. Networks []*Network `protobuf:"bytes,1,rep,name=networks" json:"networks,omitempty"`
  278. }
  279. func (m *ListNetworksResponse) Reset() { *m = ListNetworksResponse{} }
  280. func (*ListNetworksResponse) ProtoMessage() {}
  281. func (*ListNetworksResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{31} }
  282. type GetClusterRequest struct {
  283. ClusterID string `protobuf:"bytes,1,opt,name=cluster_id,json=clusterId,proto3" json:"cluster_id,omitempty"`
  284. }
  285. func (m *GetClusterRequest) Reset() { *m = GetClusterRequest{} }
  286. func (*GetClusterRequest) ProtoMessage() {}
  287. func (*GetClusterRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{32} }
  288. type GetClusterResponse struct {
  289. Cluster *Cluster `protobuf:"bytes,1,opt,name=cluster" json:"cluster,omitempty"`
  290. }
  291. func (m *GetClusterResponse) Reset() { *m = GetClusterResponse{} }
  292. func (*GetClusterResponse) ProtoMessage() {}
  293. func (*GetClusterResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{33} }
  294. type ListClustersRequest struct {
  295. Filters *ListClustersRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  296. }
  297. func (m *ListClustersRequest) Reset() { *m = ListClustersRequest{} }
  298. func (*ListClustersRequest) ProtoMessage() {}
  299. func (*ListClustersRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{34} }
  300. type ListClustersRequest_Filters struct {
  301. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  302. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  303. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  304. // NamePrefixes matches all objects with the given prefixes
  305. NamePrefixes []string `protobuf:"bytes,4,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  306. }
  307. func (m *ListClustersRequest_Filters) Reset() { *m = ListClustersRequest_Filters{} }
  308. func (*ListClustersRequest_Filters) ProtoMessage() {}
  309. func (*ListClustersRequest_Filters) Descriptor() ([]byte, []int) {
  310. return fileDescriptorControl, []int{34, 0}
  311. }
  312. type ListClustersResponse struct {
  313. Clusters []*Cluster `protobuf:"bytes,1,rep,name=clusters" json:"clusters,omitempty"`
  314. }
  315. func (m *ListClustersResponse) Reset() { *m = ListClustersResponse{} }
  316. func (*ListClustersResponse) ProtoMessage() {}
  317. func (*ListClustersResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{35} }
  318. // KeyRotation tells UpdateCluster what items to rotate
  319. type KeyRotation struct {
  320. // WorkerJoinToken tells UpdateCluster to rotate the worker secret token.
  321. WorkerJoinToken bool `protobuf:"varint,1,opt,name=worker_join_token,json=workerJoinToken,proto3" json:"worker_join_token,omitempty"`
  322. // ManagerJoinToken tells UpdateCluster to rotate the manager secret token.
  323. ManagerJoinToken bool `protobuf:"varint,2,opt,name=manager_join_token,json=managerJoinToken,proto3" json:"manager_join_token,omitempty"`
  324. // ManagerUnlockKey tells UpdateCluster to rotate the manager unlock key
  325. ManagerUnlockKey bool `protobuf:"varint,3,opt,name=manager_unlock_key,json=managerUnlockKey,proto3" json:"manager_unlock_key,omitempty"`
  326. }
  327. func (m *KeyRotation) Reset() { *m = KeyRotation{} }
  328. func (*KeyRotation) ProtoMessage() {}
  329. func (*KeyRotation) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{36} }
  330. type UpdateClusterRequest struct {
  331. // ClusterID is the cluster ID to update.
  332. ClusterID string `protobuf:"bytes,1,opt,name=cluster_id,json=clusterId,proto3" json:"cluster_id,omitempty"`
  333. // ClusterVersion is the version of the cluster being updated.
  334. ClusterVersion *Version `protobuf:"bytes,2,opt,name=cluster_version,json=clusterVersion" json:"cluster_version,omitempty"`
  335. // Spec is the new spec to apply to the cluster.
  336. Spec *ClusterSpec `protobuf:"bytes,3,opt,name=spec" json:"spec,omitempty"`
  337. // Rotation contains flags for join token and unlock key rotation
  338. Rotation KeyRotation `protobuf:"bytes,4,opt,name=rotation" json:"rotation"`
  339. }
  340. func (m *UpdateClusterRequest) Reset() { *m = UpdateClusterRequest{} }
  341. func (*UpdateClusterRequest) ProtoMessage() {}
  342. func (*UpdateClusterRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{37} }
  343. type UpdateClusterResponse struct {
  344. Cluster *Cluster `protobuf:"bytes,1,opt,name=cluster" json:"cluster,omitempty"`
  345. }
  346. func (m *UpdateClusterResponse) Reset() { *m = UpdateClusterResponse{} }
  347. func (*UpdateClusterResponse) ProtoMessage() {}
  348. func (*UpdateClusterResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{38} }
  349. // GetSecretRequest is the request to get a `Secret` object given a secret id.
  350. type GetSecretRequest struct {
  351. SecretID string `protobuf:"bytes,1,opt,name=secret_id,json=secretId,proto3" json:"secret_id,omitempty"`
  352. }
  353. func (m *GetSecretRequest) Reset() { *m = GetSecretRequest{} }
  354. func (*GetSecretRequest) ProtoMessage() {}
  355. func (*GetSecretRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{39} }
  356. // GetSecretResponse contains the Secret corresponding to the id in
  357. // `GetSecretRequest`, but the `Secret.Spec.Data` field in each `Secret`
  358. // object should be nil instead of actually containing the secret bytes.
  359. type GetSecretResponse struct {
  360. Secret *Secret `protobuf:"bytes,1,opt,name=secret" json:"secret,omitempty"`
  361. }
  362. func (m *GetSecretResponse) Reset() { *m = GetSecretResponse{} }
  363. func (*GetSecretResponse) ProtoMessage() {}
  364. func (*GetSecretResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{40} }
  365. type UpdateSecretRequest struct {
  366. // SecretID is the secret ID to update.
  367. SecretID string `protobuf:"bytes,1,opt,name=secret_id,json=secretId,proto3" json:"secret_id,omitempty"`
  368. // SecretVersion is the version of the secret being updated.
  369. SecretVersion *Version `protobuf:"bytes,2,opt,name=secret_version,json=secretVersion" json:"secret_version,omitempty"`
  370. // Spec is the new spec to apply to the Secret
  371. // Only some fields are allowed to be updated.
  372. Spec *SecretSpec `protobuf:"bytes,3,opt,name=spec" json:"spec,omitempty"`
  373. }
  374. func (m *UpdateSecretRequest) Reset() { *m = UpdateSecretRequest{} }
  375. func (*UpdateSecretRequest) ProtoMessage() {}
  376. func (*UpdateSecretRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{41} }
  377. type UpdateSecretResponse struct {
  378. Secret *Secret `protobuf:"bytes,1,opt,name=secret" json:"secret,omitempty"`
  379. }
  380. func (m *UpdateSecretResponse) Reset() { *m = UpdateSecretResponse{} }
  381. func (*UpdateSecretResponse) ProtoMessage() {}
  382. func (*UpdateSecretResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{42} }
  383. // ListSecretRequest is the request to list all non-internal secrets in the secret store,
  384. // or all secrets filtered by (name or name prefix or id prefix) and labels.
  385. type ListSecretsRequest struct {
  386. Filters *ListSecretsRequest_Filters `protobuf:"bytes,1,opt,name=filters" json:"filters,omitempty"`
  387. }
  388. func (m *ListSecretsRequest) Reset() { *m = ListSecretsRequest{} }
  389. func (*ListSecretsRequest) ProtoMessage() {}
  390. func (*ListSecretsRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{43} }
  391. type ListSecretsRequest_Filters struct {
  392. Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
  393. IDPrefixes []string `protobuf:"bytes,2,rep,name=id_prefixes,json=idPrefixes" json:"id_prefixes,omitempty"`
  394. Labels map[string]string `protobuf:"bytes,3,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
  395. NamePrefixes []string `protobuf:"bytes,4,rep,name=name_prefixes,json=namePrefixes" json:"name_prefixes,omitempty"`
  396. }
  397. func (m *ListSecretsRequest_Filters) Reset() { *m = ListSecretsRequest_Filters{} }
  398. func (*ListSecretsRequest_Filters) ProtoMessage() {}
  399. func (*ListSecretsRequest_Filters) Descriptor() ([]byte, []int) {
  400. return fileDescriptorControl, []int{43, 0}
  401. }
  402. // ListSecretResponse contains a list of all the secrets that match the name or
  403. // name prefix filters provided in `ListSecretRequest`. The `Secret.Spec.Data`
  404. // field in each `Secret` object should be nil instead of actually containing
  405. // the secret bytes.
  406. type ListSecretsResponse struct {
  407. Secrets []*Secret `protobuf:"bytes,1,rep,name=secrets" json:"secrets,omitempty"`
  408. }
  409. func (m *ListSecretsResponse) Reset() { *m = ListSecretsResponse{} }
  410. func (*ListSecretsResponse) ProtoMessage() {}
  411. func (*ListSecretsResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{44} }
  412. // CreateSecretRequest specifies a new secret (it will not update an existing
  413. // secret) to create.
  414. type CreateSecretRequest struct {
  415. Spec *SecretSpec `protobuf:"bytes,1,opt,name=spec" json:"spec,omitempty"`
  416. }
  417. func (m *CreateSecretRequest) Reset() { *m = CreateSecretRequest{} }
  418. func (*CreateSecretRequest) ProtoMessage() {}
  419. func (*CreateSecretRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{45} }
  420. // CreateSecretResponse contains the newly created `Secret`` corresponding to the
  421. // name in `CreateSecretRequest`. The `Secret.Spec.Data` field should be nil instead
  422. // of actually containing the secret bytes.
  423. type CreateSecretResponse struct {
  424. Secret *Secret `protobuf:"bytes,1,opt,name=secret" json:"secret,omitempty"`
  425. }
  426. func (m *CreateSecretResponse) Reset() { *m = CreateSecretResponse{} }
  427. func (*CreateSecretResponse) ProtoMessage() {}
  428. func (*CreateSecretResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{46} }
  429. // RemoveSecretRequest contains the ID of the secret that should be removed. This
  430. // removes all versions of the secret.
  431. type RemoveSecretRequest struct {
  432. SecretID string `protobuf:"bytes,1,opt,name=secret_id,json=secretId,proto3" json:"secret_id,omitempty"`
  433. }
  434. func (m *RemoveSecretRequest) Reset() { *m = RemoveSecretRequest{} }
  435. func (*RemoveSecretRequest) ProtoMessage() {}
  436. func (*RemoveSecretRequest) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{47} }
  437. // RemoveSecretResponse is an empty object indicating the successful removal of
  438. // a secret.
  439. type RemoveSecretResponse struct {
  440. }
  441. func (m *RemoveSecretResponse) Reset() { *m = RemoveSecretResponse{} }
  442. func (*RemoveSecretResponse) ProtoMessage() {}
  443. func (*RemoveSecretResponse) Descriptor() ([]byte, []int) { return fileDescriptorControl, []int{48} }
  444. func init() {
  445. proto.RegisterType((*GetNodeRequest)(nil), "docker.swarmkit.v1.GetNodeRequest")
  446. proto.RegisterType((*GetNodeResponse)(nil), "docker.swarmkit.v1.GetNodeResponse")
  447. proto.RegisterType((*ListNodesRequest)(nil), "docker.swarmkit.v1.ListNodesRequest")
  448. proto.RegisterType((*ListNodesRequest_Filters)(nil), "docker.swarmkit.v1.ListNodesRequest.Filters")
  449. proto.RegisterType((*ListNodesResponse)(nil), "docker.swarmkit.v1.ListNodesResponse")
  450. proto.RegisterType((*UpdateNodeRequest)(nil), "docker.swarmkit.v1.UpdateNodeRequest")
  451. proto.RegisterType((*UpdateNodeResponse)(nil), "docker.swarmkit.v1.UpdateNodeResponse")
  452. proto.RegisterType((*RemoveNodeRequest)(nil), "docker.swarmkit.v1.RemoveNodeRequest")
  453. proto.RegisterType((*RemoveNodeResponse)(nil), "docker.swarmkit.v1.RemoveNodeResponse")
  454. proto.RegisterType((*GetTaskRequest)(nil), "docker.swarmkit.v1.GetTaskRequest")
  455. proto.RegisterType((*GetTaskResponse)(nil), "docker.swarmkit.v1.GetTaskResponse")
  456. proto.RegisterType((*RemoveTaskRequest)(nil), "docker.swarmkit.v1.RemoveTaskRequest")
  457. proto.RegisterType((*RemoveTaskResponse)(nil), "docker.swarmkit.v1.RemoveTaskResponse")
  458. proto.RegisterType((*ListTasksRequest)(nil), "docker.swarmkit.v1.ListTasksRequest")
  459. proto.RegisterType((*ListTasksRequest_Filters)(nil), "docker.swarmkit.v1.ListTasksRequest.Filters")
  460. proto.RegisterType((*ListTasksResponse)(nil), "docker.swarmkit.v1.ListTasksResponse")
  461. proto.RegisterType((*CreateServiceRequest)(nil), "docker.swarmkit.v1.CreateServiceRequest")
  462. proto.RegisterType((*CreateServiceResponse)(nil), "docker.swarmkit.v1.CreateServiceResponse")
  463. proto.RegisterType((*GetServiceRequest)(nil), "docker.swarmkit.v1.GetServiceRequest")
  464. proto.RegisterType((*GetServiceResponse)(nil), "docker.swarmkit.v1.GetServiceResponse")
  465. proto.RegisterType((*UpdateServiceRequest)(nil), "docker.swarmkit.v1.UpdateServiceRequest")
  466. proto.RegisterType((*UpdateServiceResponse)(nil), "docker.swarmkit.v1.UpdateServiceResponse")
  467. proto.RegisterType((*RemoveServiceRequest)(nil), "docker.swarmkit.v1.RemoveServiceRequest")
  468. proto.RegisterType((*RemoveServiceResponse)(nil), "docker.swarmkit.v1.RemoveServiceResponse")
  469. proto.RegisterType((*ListServicesRequest)(nil), "docker.swarmkit.v1.ListServicesRequest")
  470. proto.RegisterType((*ListServicesRequest_Filters)(nil), "docker.swarmkit.v1.ListServicesRequest.Filters")
  471. proto.RegisterType((*ListServicesResponse)(nil), "docker.swarmkit.v1.ListServicesResponse")
  472. proto.RegisterType((*CreateNetworkRequest)(nil), "docker.swarmkit.v1.CreateNetworkRequest")
  473. proto.RegisterType((*CreateNetworkResponse)(nil), "docker.swarmkit.v1.CreateNetworkResponse")
  474. proto.RegisterType((*GetNetworkRequest)(nil), "docker.swarmkit.v1.GetNetworkRequest")
  475. proto.RegisterType((*GetNetworkResponse)(nil), "docker.swarmkit.v1.GetNetworkResponse")
  476. proto.RegisterType((*RemoveNetworkRequest)(nil), "docker.swarmkit.v1.RemoveNetworkRequest")
  477. proto.RegisterType((*RemoveNetworkResponse)(nil), "docker.swarmkit.v1.RemoveNetworkResponse")
  478. proto.RegisterType((*ListNetworksRequest)(nil), "docker.swarmkit.v1.ListNetworksRequest")
  479. proto.RegisterType((*ListNetworksRequest_Filters)(nil), "docker.swarmkit.v1.ListNetworksRequest.Filters")
  480. proto.RegisterType((*ListNetworksResponse)(nil), "docker.swarmkit.v1.ListNetworksResponse")
  481. proto.RegisterType((*GetClusterRequest)(nil), "docker.swarmkit.v1.GetClusterRequest")
  482. proto.RegisterType((*GetClusterResponse)(nil), "docker.swarmkit.v1.GetClusterResponse")
  483. proto.RegisterType((*ListClustersRequest)(nil), "docker.swarmkit.v1.ListClustersRequest")
  484. proto.RegisterType((*ListClustersRequest_Filters)(nil), "docker.swarmkit.v1.ListClustersRequest.Filters")
  485. proto.RegisterType((*ListClustersResponse)(nil), "docker.swarmkit.v1.ListClustersResponse")
  486. proto.RegisterType((*KeyRotation)(nil), "docker.swarmkit.v1.KeyRotation")
  487. proto.RegisterType((*UpdateClusterRequest)(nil), "docker.swarmkit.v1.UpdateClusterRequest")
  488. proto.RegisterType((*UpdateClusterResponse)(nil), "docker.swarmkit.v1.UpdateClusterResponse")
  489. proto.RegisterType((*GetSecretRequest)(nil), "docker.swarmkit.v1.GetSecretRequest")
  490. proto.RegisterType((*GetSecretResponse)(nil), "docker.swarmkit.v1.GetSecretResponse")
  491. proto.RegisterType((*UpdateSecretRequest)(nil), "docker.swarmkit.v1.UpdateSecretRequest")
  492. proto.RegisterType((*UpdateSecretResponse)(nil), "docker.swarmkit.v1.UpdateSecretResponse")
  493. proto.RegisterType((*ListSecretsRequest)(nil), "docker.swarmkit.v1.ListSecretsRequest")
  494. proto.RegisterType((*ListSecretsRequest_Filters)(nil), "docker.swarmkit.v1.ListSecretsRequest.Filters")
  495. proto.RegisterType((*ListSecretsResponse)(nil), "docker.swarmkit.v1.ListSecretsResponse")
  496. proto.RegisterType((*CreateSecretRequest)(nil), "docker.swarmkit.v1.CreateSecretRequest")
  497. proto.RegisterType((*CreateSecretResponse)(nil), "docker.swarmkit.v1.CreateSecretResponse")
  498. proto.RegisterType((*RemoveSecretRequest)(nil), "docker.swarmkit.v1.RemoveSecretRequest")
  499. proto.RegisterType((*RemoveSecretResponse)(nil), "docker.swarmkit.v1.RemoveSecretResponse")
  500. }
  501. type authenticatedWrapperControlServer struct {
  502. local ControlServer
  503. authorize func(context.Context, []string) error
  504. }
  505. func NewAuthenticatedWrapperControlServer(local ControlServer, authorize func(context.Context, []string) error) ControlServer {
  506. return &authenticatedWrapperControlServer{
  507. local: local,
  508. authorize: authorize,
  509. }
  510. }
  511. func (p *authenticatedWrapperControlServer) GetNode(ctx context.Context, r *GetNodeRequest) (*GetNodeResponse, error) {
  512. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  513. return nil, err
  514. }
  515. return p.local.GetNode(ctx, r)
  516. }
  517. func (p *authenticatedWrapperControlServer) ListNodes(ctx context.Context, r *ListNodesRequest) (*ListNodesResponse, error) {
  518. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  519. return nil, err
  520. }
  521. return p.local.ListNodes(ctx, r)
  522. }
  523. func (p *authenticatedWrapperControlServer) UpdateNode(ctx context.Context, r *UpdateNodeRequest) (*UpdateNodeResponse, error) {
  524. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  525. return nil, err
  526. }
  527. return p.local.UpdateNode(ctx, r)
  528. }
  529. func (p *authenticatedWrapperControlServer) RemoveNode(ctx context.Context, r *RemoveNodeRequest) (*RemoveNodeResponse, error) {
  530. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  531. return nil, err
  532. }
  533. return p.local.RemoveNode(ctx, r)
  534. }
  535. func (p *authenticatedWrapperControlServer) GetTask(ctx context.Context, r *GetTaskRequest) (*GetTaskResponse, error) {
  536. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  537. return nil, err
  538. }
  539. return p.local.GetTask(ctx, r)
  540. }
  541. func (p *authenticatedWrapperControlServer) ListTasks(ctx context.Context, r *ListTasksRequest) (*ListTasksResponse, error) {
  542. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  543. return nil, err
  544. }
  545. return p.local.ListTasks(ctx, r)
  546. }
  547. func (p *authenticatedWrapperControlServer) RemoveTask(ctx context.Context, r *RemoveTaskRequest) (*RemoveTaskResponse, error) {
  548. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  549. return nil, err
  550. }
  551. return p.local.RemoveTask(ctx, r)
  552. }
  553. func (p *authenticatedWrapperControlServer) GetService(ctx context.Context, r *GetServiceRequest) (*GetServiceResponse, error) {
  554. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  555. return nil, err
  556. }
  557. return p.local.GetService(ctx, r)
  558. }
  559. func (p *authenticatedWrapperControlServer) ListServices(ctx context.Context, r *ListServicesRequest) (*ListServicesResponse, error) {
  560. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  561. return nil, err
  562. }
  563. return p.local.ListServices(ctx, r)
  564. }
  565. func (p *authenticatedWrapperControlServer) CreateService(ctx context.Context, r *CreateServiceRequest) (*CreateServiceResponse, error) {
  566. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  567. return nil, err
  568. }
  569. return p.local.CreateService(ctx, r)
  570. }
  571. func (p *authenticatedWrapperControlServer) UpdateService(ctx context.Context, r *UpdateServiceRequest) (*UpdateServiceResponse, error) {
  572. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  573. return nil, err
  574. }
  575. return p.local.UpdateService(ctx, r)
  576. }
  577. func (p *authenticatedWrapperControlServer) RemoveService(ctx context.Context, r *RemoveServiceRequest) (*RemoveServiceResponse, error) {
  578. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  579. return nil, err
  580. }
  581. return p.local.RemoveService(ctx, r)
  582. }
  583. func (p *authenticatedWrapperControlServer) GetNetwork(ctx context.Context, r *GetNetworkRequest) (*GetNetworkResponse, error) {
  584. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  585. return nil, err
  586. }
  587. return p.local.GetNetwork(ctx, r)
  588. }
  589. func (p *authenticatedWrapperControlServer) ListNetworks(ctx context.Context, r *ListNetworksRequest) (*ListNetworksResponse, error) {
  590. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  591. return nil, err
  592. }
  593. return p.local.ListNetworks(ctx, r)
  594. }
  595. func (p *authenticatedWrapperControlServer) CreateNetwork(ctx context.Context, r *CreateNetworkRequest) (*CreateNetworkResponse, error) {
  596. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  597. return nil, err
  598. }
  599. return p.local.CreateNetwork(ctx, r)
  600. }
  601. func (p *authenticatedWrapperControlServer) RemoveNetwork(ctx context.Context, r *RemoveNetworkRequest) (*RemoveNetworkResponse, error) {
  602. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  603. return nil, err
  604. }
  605. return p.local.RemoveNetwork(ctx, r)
  606. }
  607. func (p *authenticatedWrapperControlServer) GetCluster(ctx context.Context, r *GetClusterRequest) (*GetClusterResponse, error) {
  608. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  609. return nil, err
  610. }
  611. return p.local.GetCluster(ctx, r)
  612. }
  613. func (p *authenticatedWrapperControlServer) ListClusters(ctx context.Context, r *ListClustersRequest) (*ListClustersResponse, error) {
  614. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  615. return nil, err
  616. }
  617. return p.local.ListClusters(ctx, r)
  618. }
  619. func (p *authenticatedWrapperControlServer) UpdateCluster(ctx context.Context, r *UpdateClusterRequest) (*UpdateClusterResponse, error) {
  620. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  621. return nil, err
  622. }
  623. return p.local.UpdateCluster(ctx, r)
  624. }
  625. func (p *authenticatedWrapperControlServer) GetSecret(ctx context.Context, r *GetSecretRequest) (*GetSecretResponse, error) {
  626. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  627. return nil, err
  628. }
  629. return p.local.GetSecret(ctx, r)
  630. }
  631. func (p *authenticatedWrapperControlServer) UpdateSecret(ctx context.Context, r *UpdateSecretRequest) (*UpdateSecretResponse, error) {
  632. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  633. return nil, err
  634. }
  635. return p.local.UpdateSecret(ctx, r)
  636. }
  637. func (p *authenticatedWrapperControlServer) ListSecrets(ctx context.Context, r *ListSecretsRequest) (*ListSecretsResponse, error) {
  638. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  639. return nil, err
  640. }
  641. return p.local.ListSecrets(ctx, r)
  642. }
  643. func (p *authenticatedWrapperControlServer) CreateSecret(ctx context.Context, r *CreateSecretRequest) (*CreateSecretResponse, error) {
  644. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  645. return nil, err
  646. }
  647. return p.local.CreateSecret(ctx, r)
  648. }
  649. func (p *authenticatedWrapperControlServer) RemoveSecret(ctx context.Context, r *RemoveSecretRequest) (*RemoveSecretResponse, error) {
  650. if err := p.authorize(ctx, []string{"swarm-manager"}); err != nil {
  651. return nil, err
  652. }
  653. return p.local.RemoveSecret(ctx, r)
  654. }
  655. func (m *GetNodeRequest) Copy() *GetNodeRequest {
  656. if m == nil {
  657. return nil
  658. }
  659. o := &GetNodeRequest{
  660. NodeID: m.NodeID,
  661. }
  662. return o
  663. }
  664. func (m *GetNodeResponse) Copy() *GetNodeResponse {
  665. if m == nil {
  666. return nil
  667. }
  668. o := &GetNodeResponse{
  669. Node: m.Node.Copy(),
  670. }
  671. return o
  672. }
  673. func (m *ListNodesRequest) Copy() *ListNodesRequest {
  674. if m == nil {
  675. return nil
  676. }
  677. o := &ListNodesRequest{
  678. Filters: m.Filters.Copy(),
  679. }
  680. return o
  681. }
  682. func (m *ListNodesRequest_Filters) Copy() *ListNodesRequest_Filters {
  683. if m == nil {
  684. return nil
  685. }
  686. o := &ListNodesRequest_Filters{}
  687. if m.Names != nil {
  688. o.Names = make([]string, 0, len(m.Names))
  689. o.Names = append(o.Names, m.Names...)
  690. }
  691. if m.IDPrefixes != nil {
  692. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  693. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  694. }
  695. if m.Labels != nil {
  696. o.Labels = make(map[string]string)
  697. for k, v := range m.Labels {
  698. o.Labels[k] = v
  699. }
  700. }
  701. if m.Memberships != nil {
  702. o.Memberships = make([]NodeSpec_Membership, 0, len(m.Memberships))
  703. o.Memberships = append(o.Memberships, m.Memberships...)
  704. }
  705. if m.Roles != nil {
  706. o.Roles = make([]NodeRole, 0, len(m.Roles))
  707. o.Roles = append(o.Roles, m.Roles...)
  708. }
  709. if m.NamePrefixes != nil {
  710. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  711. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  712. }
  713. return o
  714. }
  715. func (m *ListNodesResponse) Copy() *ListNodesResponse {
  716. if m == nil {
  717. return nil
  718. }
  719. o := &ListNodesResponse{}
  720. if m.Nodes != nil {
  721. o.Nodes = make([]*Node, 0, len(m.Nodes))
  722. for _, v := range m.Nodes {
  723. o.Nodes = append(o.Nodes, v.Copy())
  724. }
  725. }
  726. return o
  727. }
  728. func (m *UpdateNodeRequest) Copy() *UpdateNodeRequest {
  729. if m == nil {
  730. return nil
  731. }
  732. o := &UpdateNodeRequest{
  733. NodeID: m.NodeID,
  734. NodeVersion: m.NodeVersion.Copy(),
  735. Spec: m.Spec.Copy(),
  736. }
  737. return o
  738. }
  739. func (m *UpdateNodeResponse) Copy() *UpdateNodeResponse {
  740. if m == nil {
  741. return nil
  742. }
  743. o := &UpdateNodeResponse{
  744. Node: m.Node.Copy(),
  745. }
  746. return o
  747. }
  748. func (m *RemoveNodeRequest) Copy() *RemoveNodeRequest {
  749. if m == nil {
  750. return nil
  751. }
  752. o := &RemoveNodeRequest{
  753. NodeID: m.NodeID,
  754. Force: m.Force,
  755. }
  756. return o
  757. }
  758. func (m *RemoveNodeResponse) Copy() *RemoveNodeResponse {
  759. if m == nil {
  760. return nil
  761. }
  762. o := &RemoveNodeResponse{}
  763. return o
  764. }
  765. func (m *GetTaskRequest) Copy() *GetTaskRequest {
  766. if m == nil {
  767. return nil
  768. }
  769. o := &GetTaskRequest{
  770. TaskID: m.TaskID,
  771. }
  772. return o
  773. }
  774. func (m *GetTaskResponse) Copy() *GetTaskResponse {
  775. if m == nil {
  776. return nil
  777. }
  778. o := &GetTaskResponse{
  779. Task: m.Task.Copy(),
  780. }
  781. return o
  782. }
  783. func (m *RemoveTaskRequest) Copy() *RemoveTaskRequest {
  784. if m == nil {
  785. return nil
  786. }
  787. o := &RemoveTaskRequest{
  788. TaskID: m.TaskID,
  789. }
  790. return o
  791. }
  792. func (m *RemoveTaskResponse) Copy() *RemoveTaskResponse {
  793. if m == nil {
  794. return nil
  795. }
  796. o := &RemoveTaskResponse{}
  797. return o
  798. }
  799. func (m *ListTasksRequest) Copy() *ListTasksRequest {
  800. if m == nil {
  801. return nil
  802. }
  803. o := &ListTasksRequest{
  804. Filters: m.Filters.Copy(),
  805. }
  806. return o
  807. }
  808. func (m *ListTasksRequest_Filters) Copy() *ListTasksRequest_Filters {
  809. if m == nil {
  810. return nil
  811. }
  812. o := &ListTasksRequest_Filters{}
  813. if m.Names != nil {
  814. o.Names = make([]string, 0, len(m.Names))
  815. o.Names = append(o.Names, m.Names...)
  816. }
  817. if m.IDPrefixes != nil {
  818. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  819. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  820. }
  821. if m.Labels != nil {
  822. o.Labels = make(map[string]string)
  823. for k, v := range m.Labels {
  824. o.Labels[k] = v
  825. }
  826. }
  827. if m.ServiceIDs != nil {
  828. o.ServiceIDs = make([]string, 0, len(m.ServiceIDs))
  829. o.ServiceIDs = append(o.ServiceIDs, m.ServiceIDs...)
  830. }
  831. if m.NodeIDs != nil {
  832. o.NodeIDs = make([]string, 0, len(m.NodeIDs))
  833. o.NodeIDs = append(o.NodeIDs, m.NodeIDs...)
  834. }
  835. if m.DesiredStates != nil {
  836. o.DesiredStates = make([]TaskState, 0, len(m.DesiredStates))
  837. o.DesiredStates = append(o.DesiredStates, m.DesiredStates...)
  838. }
  839. if m.NamePrefixes != nil {
  840. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  841. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  842. }
  843. return o
  844. }
  845. func (m *ListTasksResponse) Copy() *ListTasksResponse {
  846. if m == nil {
  847. return nil
  848. }
  849. o := &ListTasksResponse{}
  850. if m.Tasks != nil {
  851. o.Tasks = make([]*Task, 0, len(m.Tasks))
  852. for _, v := range m.Tasks {
  853. o.Tasks = append(o.Tasks, v.Copy())
  854. }
  855. }
  856. return o
  857. }
  858. func (m *CreateServiceRequest) Copy() *CreateServiceRequest {
  859. if m == nil {
  860. return nil
  861. }
  862. o := &CreateServiceRequest{
  863. Spec: m.Spec.Copy(),
  864. }
  865. return o
  866. }
  867. func (m *CreateServiceResponse) Copy() *CreateServiceResponse {
  868. if m == nil {
  869. return nil
  870. }
  871. o := &CreateServiceResponse{
  872. Service: m.Service.Copy(),
  873. }
  874. return o
  875. }
  876. func (m *GetServiceRequest) Copy() *GetServiceRequest {
  877. if m == nil {
  878. return nil
  879. }
  880. o := &GetServiceRequest{
  881. ServiceID: m.ServiceID,
  882. }
  883. return o
  884. }
  885. func (m *GetServiceResponse) Copy() *GetServiceResponse {
  886. if m == nil {
  887. return nil
  888. }
  889. o := &GetServiceResponse{
  890. Service: m.Service.Copy(),
  891. }
  892. return o
  893. }
  894. func (m *UpdateServiceRequest) Copy() *UpdateServiceRequest {
  895. if m == nil {
  896. return nil
  897. }
  898. o := &UpdateServiceRequest{
  899. ServiceID: m.ServiceID,
  900. ServiceVersion: m.ServiceVersion.Copy(),
  901. Spec: m.Spec.Copy(),
  902. }
  903. return o
  904. }
  905. func (m *UpdateServiceResponse) Copy() *UpdateServiceResponse {
  906. if m == nil {
  907. return nil
  908. }
  909. o := &UpdateServiceResponse{
  910. Service: m.Service.Copy(),
  911. }
  912. return o
  913. }
  914. func (m *RemoveServiceRequest) Copy() *RemoveServiceRequest {
  915. if m == nil {
  916. return nil
  917. }
  918. o := &RemoveServiceRequest{
  919. ServiceID: m.ServiceID,
  920. }
  921. return o
  922. }
  923. func (m *RemoveServiceResponse) Copy() *RemoveServiceResponse {
  924. if m == nil {
  925. return nil
  926. }
  927. o := &RemoveServiceResponse{}
  928. return o
  929. }
  930. func (m *ListServicesRequest) Copy() *ListServicesRequest {
  931. if m == nil {
  932. return nil
  933. }
  934. o := &ListServicesRequest{
  935. Filters: m.Filters.Copy(),
  936. }
  937. return o
  938. }
  939. func (m *ListServicesRequest_Filters) Copy() *ListServicesRequest_Filters {
  940. if m == nil {
  941. return nil
  942. }
  943. o := &ListServicesRequest_Filters{}
  944. if m.Names != nil {
  945. o.Names = make([]string, 0, len(m.Names))
  946. o.Names = append(o.Names, m.Names...)
  947. }
  948. if m.IDPrefixes != nil {
  949. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  950. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  951. }
  952. if m.Labels != nil {
  953. o.Labels = make(map[string]string)
  954. for k, v := range m.Labels {
  955. o.Labels[k] = v
  956. }
  957. }
  958. if m.NamePrefixes != nil {
  959. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  960. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  961. }
  962. return o
  963. }
  964. func (m *ListServicesResponse) Copy() *ListServicesResponse {
  965. if m == nil {
  966. return nil
  967. }
  968. o := &ListServicesResponse{}
  969. if m.Services != nil {
  970. o.Services = make([]*Service, 0, len(m.Services))
  971. for _, v := range m.Services {
  972. o.Services = append(o.Services, v.Copy())
  973. }
  974. }
  975. return o
  976. }
  977. func (m *CreateNetworkRequest) Copy() *CreateNetworkRequest {
  978. if m == nil {
  979. return nil
  980. }
  981. o := &CreateNetworkRequest{
  982. Spec: m.Spec.Copy(),
  983. }
  984. return o
  985. }
  986. func (m *CreateNetworkResponse) Copy() *CreateNetworkResponse {
  987. if m == nil {
  988. return nil
  989. }
  990. o := &CreateNetworkResponse{
  991. Network: m.Network.Copy(),
  992. }
  993. return o
  994. }
  995. func (m *GetNetworkRequest) Copy() *GetNetworkRequest {
  996. if m == nil {
  997. return nil
  998. }
  999. o := &GetNetworkRequest{
  1000. Name: m.Name,
  1001. NetworkID: m.NetworkID,
  1002. }
  1003. return o
  1004. }
  1005. func (m *GetNetworkResponse) Copy() *GetNetworkResponse {
  1006. if m == nil {
  1007. return nil
  1008. }
  1009. o := &GetNetworkResponse{
  1010. Network: m.Network.Copy(),
  1011. }
  1012. return o
  1013. }
  1014. func (m *RemoveNetworkRequest) Copy() *RemoveNetworkRequest {
  1015. if m == nil {
  1016. return nil
  1017. }
  1018. o := &RemoveNetworkRequest{
  1019. Name: m.Name,
  1020. NetworkID: m.NetworkID,
  1021. }
  1022. return o
  1023. }
  1024. func (m *RemoveNetworkResponse) Copy() *RemoveNetworkResponse {
  1025. if m == nil {
  1026. return nil
  1027. }
  1028. o := &RemoveNetworkResponse{}
  1029. return o
  1030. }
  1031. func (m *ListNetworksRequest) Copy() *ListNetworksRequest {
  1032. if m == nil {
  1033. return nil
  1034. }
  1035. o := &ListNetworksRequest{
  1036. Filters: m.Filters.Copy(),
  1037. }
  1038. return o
  1039. }
  1040. func (m *ListNetworksRequest_Filters) Copy() *ListNetworksRequest_Filters {
  1041. if m == nil {
  1042. return nil
  1043. }
  1044. o := &ListNetworksRequest_Filters{}
  1045. if m.Names != nil {
  1046. o.Names = make([]string, 0, len(m.Names))
  1047. o.Names = append(o.Names, m.Names...)
  1048. }
  1049. if m.IDPrefixes != nil {
  1050. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  1051. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  1052. }
  1053. if m.Labels != nil {
  1054. o.Labels = make(map[string]string)
  1055. for k, v := range m.Labels {
  1056. o.Labels[k] = v
  1057. }
  1058. }
  1059. if m.NamePrefixes != nil {
  1060. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  1061. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  1062. }
  1063. return o
  1064. }
  1065. func (m *ListNetworksResponse) Copy() *ListNetworksResponse {
  1066. if m == nil {
  1067. return nil
  1068. }
  1069. o := &ListNetworksResponse{}
  1070. if m.Networks != nil {
  1071. o.Networks = make([]*Network, 0, len(m.Networks))
  1072. for _, v := range m.Networks {
  1073. o.Networks = append(o.Networks, v.Copy())
  1074. }
  1075. }
  1076. return o
  1077. }
  1078. func (m *GetClusterRequest) Copy() *GetClusterRequest {
  1079. if m == nil {
  1080. return nil
  1081. }
  1082. o := &GetClusterRequest{
  1083. ClusterID: m.ClusterID,
  1084. }
  1085. return o
  1086. }
  1087. func (m *GetClusterResponse) Copy() *GetClusterResponse {
  1088. if m == nil {
  1089. return nil
  1090. }
  1091. o := &GetClusterResponse{
  1092. Cluster: m.Cluster.Copy(),
  1093. }
  1094. return o
  1095. }
  1096. func (m *ListClustersRequest) Copy() *ListClustersRequest {
  1097. if m == nil {
  1098. return nil
  1099. }
  1100. o := &ListClustersRequest{
  1101. Filters: m.Filters.Copy(),
  1102. }
  1103. return o
  1104. }
  1105. func (m *ListClustersRequest_Filters) Copy() *ListClustersRequest_Filters {
  1106. if m == nil {
  1107. return nil
  1108. }
  1109. o := &ListClustersRequest_Filters{}
  1110. if m.Names != nil {
  1111. o.Names = make([]string, 0, len(m.Names))
  1112. o.Names = append(o.Names, m.Names...)
  1113. }
  1114. if m.IDPrefixes != nil {
  1115. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  1116. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  1117. }
  1118. if m.Labels != nil {
  1119. o.Labels = make(map[string]string)
  1120. for k, v := range m.Labels {
  1121. o.Labels[k] = v
  1122. }
  1123. }
  1124. if m.NamePrefixes != nil {
  1125. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  1126. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  1127. }
  1128. return o
  1129. }
  1130. func (m *ListClustersResponse) Copy() *ListClustersResponse {
  1131. if m == nil {
  1132. return nil
  1133. }
  1134. o := &ListClustersResponse{}
  1135. if m.Clusters != nil {
  1136. o.Clusters = make([]*Cluster, 0, len(m.Clusters))
  1137. for _, v := range m.Clusters {
  1138. o.Clusters = append(o.Clusters, v.Copy())
  1139. }
  1140. }
  1141. return o
  1142. }
  1143. func (m *KeyRotation) Copy() *KeyRotation {
  1144. if m == nil {
  1145. return nil
  1146. }
  1147. o := &KeyRotation{
  1148. WorkerJoinToken: m.WorkerJoinToken,
  1149. ManagerJoinToken: m.ManagerJoinToken,
  1150. ManagerUnlockKey: m.ManagerUnlockKey,
  1151. }
  1152. return o
  1153. }
  1154. func (m *UpdateClusterRequest) Copy() *UpdateClusterRequest {
  1155. if m == nil {
  1156. return nil
  1157. }
  1158. o := &UpdateClusterRequest{
  1159. ClusterID: m.ClusterID,
  1160. ClusterVersion: m.ClusterVersion.Copy(),
  1161. Spec: m.Spec.Copy(),
  1162. Rotation: *m.Rotation.Copy(),
  1163. }
  1164. return o
  1165. }
  1166. func (m *UpdateClusterResponse) Copy() *UpdateClusterResponse {
  1167. if m == nil {
  1168. return nil
  1169. }
  1170. o := &UpdateClusterResponse{
  1171. Cluster: m.Cluster.Copy(),
  1172. }
  1173. return o
  1174. }
  1175. func (m *GetSecretRequest) Copy() *GetSecretRequest {
  1176. if m == nil {
  1177. return nil
  1178. }
  1179. o := &GetSecretRequest{
  1180. SecretID: m.SecretID,
  1181. }
  1182. return o
  1183. }
  1184. func (m *GetSecretResponse) Copy() *GetSecretResponse {
  1185. if m == nil {
  1186. return nil
  1187. }
  1188. o := &GetSecretResponse{
  1189. Secret: m.Secret.Copy(),
  1190. }
  1191. return o
  1192. }
  1193. func (m *UpdateSecretRequest) Copy() *UpdateSecretRequest {
  1194. if m == nil {
  1195. return nil
  1196. }
  1197. o := &UpdateSecretRequest{
  1198. SecretID: m.SecretID,
  1199. SecretVersion: m.SecretVersion.Copy(),
  1200. Spec: m.Spec.Copy(),
  1201. }
  1202. return o
  1203. }
  1204. func (m *UpdateSecretResponse) Copy() *UpdateSecretResponse {
  1205. if m == nil {
  1206. return nil
  1207. }
  1208. o := &UpdateSecretResponse{
  1209. Secret: m.Secret.Copy(),
  1210. }
  1211. return o
  1212. }
  1213. func (m *ListSecretsRequest) Copy() *ListSecretsRequest {
  1214. if m == nil {
  1215. return nil
  1216. }
  1217. o := &ListSecretsRequest{
  1218. Filters: m.Filters.Copy(),
  1219. }
  1220. return o
  1221. }
  1222. func (m *ListSecretsRequest_Filters) Copy() *ListSecretsRequest_Filters {
  1223. if m == nil {
  1224. return nil
  1225. }
  1226. o := &ListSecretsRequest_Filters{}
  1227. if m.Names != nil {
  1228. o.Names = make([]string, 0, len(m.Names))
  1229. o.Names = append(o.Names, m.Names...)
  1230. }
  1231. if m.IDPrefixes != nil {
  1232. o.IDPrefixes = make([]string, 0, len(m.IDPrefixes))
  1233. o.IDPrefixes = append(o.IDPrefixes, m.IDPrefixes...)
  1234. }
  1235. if m.Labels != nil {
  1236. o.Labels = make(map[string]string)
  1237. for k, v := range m.Labels {
  1238. o.Labels[k] = v
  1239. }
  1240. }
  1241. if m.NamePrefixes != nil {
  1242. o.NamePrefixes = make([]string, 0, len(m.NamePrefixes))
  1243. o.NamePrefixes = append(o.NamePrefixes, m.NamePrefixes...)
  1244. }
  1245. return o
  1246. }
  1247. func (m *ListSecretsResponse) Copy() *ListSecretsResponse {
  1248. if m == nil {
  1249. return nil
  1250. }
  1251. o := &ListSecretsResponse{}
  1252. if m.Secrets != nil {
  1253. o.Secrets = make([]*Secret, 0, len(m.Secrets))
  1254. for _, v := range m.Secrets {
  1255. o.Secrets = append(o.Secrets, v.Copy())
  1256. }
  1257. }
  1258. return o
  1259. }
  1260. func (m *CreateSecretRequest) Copy() *CreateSecretRequest {
  1261. if m == nil {
  1262. return nil
  1263. }
  1264. o := &CreateSecretRequest{
  1265. Spec: m.Spec.Copy(),
  1266. }
  1267. return o
  1268. }
  1269. func (m *CreateSecretResponse) Copy() *CreateSecretResponse {
  1270. if m == nil {
  1271. return nil
  1272. }
  1273. o := &CreateSecretResponse{
  1274. Secret: m.Secret.Copy(),
  1275. }
  1276. return o
  1277. }
  1278. func (m *RemoveSecretRequest) Copy() *RemoveSecretRequest {
  1279. if m == nil {
  1280. return nil
  1281. }
  1282. o := &RemoveSecretRequest{
  1283. SecretID: m.SecretID,
  1284. }
  1285. return o
  1286. }
  1287. func (m *RemoveSecretResponse) Copy() *RemoveSecretResponse {
  1288. if m == nil {
  1289. return nil
  1290. }
  1291. o := &RemoveSecretResponse{}
  1292. return o
  1293. }
  1294. func (this *GetNodeRequest) GoString() string {
  1295. if this == nil {
  1296. return "nil"
  1297. }
  1298. s := make([]string, 0, 5)
  1299. s = append(s, "&api.GetNodeRequest{")
  1300. s = append(s, "NodeID: "+fmt.Sprintf("%#v", this.NodeID)+",\n")
  1301. s = append(s, "}")
  1302. return strings.Join(s, "")
  1303. }
  1304. func (this *GetNodeResponse) GoString() string {
  1305. if this == nil {
  1306. return "nil"
  1307. }
  1308. s := make([]string, 0, 5)
  1309. s = append(s, "&api.GetNodeResponse{")
  1310. if this.Node != nil {
  1311. s = append(s, "Node: "+fmt.Sprintf("%#v", this.Node)+",\n")
  1312. }
  1313. s = append(s, "}")
  1314. return strings.Join(s, "")
  1315. }
  1316. func (this *ListNodesRequest) GoString() string {
  1317. if this == nil {
  1318. return "nil"
  1319. }
  1320. s := make([]string, 0, 5)
  1321. s = append(s, "&api.ListNodesRequest{")
  1322. if this.Filters != nil {
  1323. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1324. }
  1325. s = append(s, "}")
  1326. return strings.Join(s, "")
  1327. }
  1328. func (this *ListNodesRequest_Filters) GoString() string {
  1329. if this == nil {
  1330. return "nil"
  1331. }
  1332. s := make([]string, 0, 10)
  1333. s = append(s, "&api.ListNodesRequest_Filters{")
  1334. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1335. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1336. keysForLabels := make([]string, 0, len(this.Labels))
  1337. for k, _ := range this.Labels {
  1338. keysForLabels = append(keysForLabels, k)
  1339. }
  1340. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1341. mapStringForLabels := "map[string]string{"
  1342. for _, k := range keysForLabels {
  1343. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1344. }
  1345. mapStringForLabels += "}"
  1346. if this.Labels != nil {
  1347. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1348. }
  1349. s = append(s, "Memberships: "+fmt.Sprintf("%#v", this.Memberships)+",\n")
  1350. s = append(s, "Roles: "+fmt.Sprintf("%#v", this.Roles)+",\n")
  1351. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1352. s = append(s, "}")
  1353. return strings.Join(s, "")
  1354. }
  1355. func (this *ListNodesResponse) GoString() string {
  1356. if this == nil {
  1357. return "nil"
  1358. }
  1359. s := make([]string, 0, 5)
  1360. s = append(s, "&api.ListNodesResponse{")
  1361. if this.Nodes != nil {
  1362. s = append(s, "Nodes: "+fmt.Sprintf("%#v", this.Nodes)+",\n")
  1363. }
  1364. s = append(s, "}")
  1365. return strings.Join(s, "")
  1366. }
  1367. func (this *UpdateNodeRequest) GoString() string {
  1368. if this == nil {
  1369. return "nil"
  1370. }
  1371. s := make([]string, 0, 7)
  1372. s = append(s, "&api.UpdateNodeRequest{")
  1373. s = append(s, "NodeID: "+fmt.Sprintf("%#v", this.NodeID)+",\n")
  1374. if this.NodeVersion != nil {
  1375. s = append(s, "NodeVersion: "+fmt.Sprintf("%#v", this.NodeVersion)+",\n")
  1376. }
  1377. if this.Spec != nil {
  1378. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1379. }
  1380. s = append(s, "}")
  1381. return strings.Join(s, "")
  1382. }
  1383. func (this *UpdateNodeResponse) GoString() string {
  1384. if this == nil {
  1385. return "nil"
  1386. }
  1387. s := make([]string, 0, 5)
  1388. s = append(s, "&api.UpdateNodeResponse{")
  1389. if this.Node != nil {
  1390. s = append(s, "Node: "+fmt.Sprintf("%#v", this.Node)+",\n")
  1391. }
  1392. s = append(s, "}")
  1393. return strings.Join(s, "")
  1394. }
  1395. func (this *RemoveNodeRequest) GoString() string {
  1396. if this == nil {
  1397. return "nil"
  1398. }
  1399. s := make([]string, 0, 6)
  1400. s = append(s, "&api.RemoveNodeRequest{")
  1401. s = append(s, "NodeID: "+fmt.Sprintf("%#v", this.NodeID)+",\n")
  1402. s = append(s, "Force: "+fmt.Sprintf("%#v", this.Force)+",\n")
  1403. s = append(s, "}")
  1404. return strings.Join(s, "")
  1405. }
  1406. func (this *RemoveNodeResponse) GoString() string {
  1407. if this == nil {
  1408. return "nil"
  1409. }
  1410. s := make([]string, 0, 4)
  1411. s = append(s, "&api.RemoveNodeResponse{")
  1412. s = append(s, "}")
  1413. return strings.Join(s, "")
  1414. }
  1415. func (this *GetTaskRequest) GoString() string {
  1416. if this == nil {
  1417. return "nil"
  1418. }
  1419. s := make([]string, 0, 5)
  1420. s = append(s, "&api.GetTaskRequest{")
  1421. s = append(s, "TaskID: "+fmt.Sprintf("%#v", this.TaskID)+",\n")
  1422. s = append(s, "}")
  1423. return strings.Join(s, "")
  1424. }
  1425. func (this *GetTaskResponse) GoString() string {
  1426. if this == nil {
  1427. return "nil"
  1428. }
  1429. s := make([]string, 0, 5)
  1430. s = append(s, "&api.GetTaskResponse{")
  1431. if this.Task != nil {
  1432. s = append(s, "Task: "+fmt.Sprintf("%#v", this.Task)+",\n")
  1433. }
  1434. s = append(s, "}")
  1435. return strings.Join(s, "")
  1436. }
  1437. func (this *RemoveTaskRequest) GoString() string {
  1438. if this == nil {
  1439. return "nil"
  1440. }
  1441. s := make([]string, 0, 5)
  1442. s = append(s, "&api.RemoveTaskRequest{")
  1443. s = append(s, "TaskID: "+fmt.Sprintf("%#v", this.TaskID)+",\n")
  1444. s = append(s, "}")
  1445. return strings.Join(s, "")
  1446. }
  1447. func (this *RemoveTaskResponse) GoString() string {
  1448. if this == nil {
  1449. return "nil"
  1450. }
  1451. s := make([]string, 0, 4)
  1452. s = append(s, "&api.RemoveTaskResponse{")
  1453. s = append(s, "}")
  1454. return strings.Join(s, "")
  1455. }
  1456. func (this *ListTasksRequest) GoString() string {
  1457. if this == nil {
  1458. return "nil"
  1459. }
  1460. s := make([]string, 0, 5)
  1461. s = append(s, "&api.ListTasksRequest{")
  1462. if this.Filters != nil {
  1463. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1464. }
  1465. s = append(s, "}")
  1466. return strings.Join(s, "")
  1467. }
  1468. func (this *ListTasksRequest_Filters) GoString() string {
  1469. if this == nil {
  1470. return "nil"
  1471. }
  1472. s := make([]string, 0, 11)
  1473. s = append(s, "&api.ListTasksRequest_Filters{")
  1474. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1475. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1476. keysForLabels := make([]string, 0, len(this.Labels))
  1477. for k, _ := range this.Labels {
  1478. keysForLabels = append(keysForLabels, k)
  1479. }
  1480. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1481. mapStringForLabels := "map[string]string{"
  1482. for _, k := range keysForLabels {
  1483. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1484. }
  1485. mapStringForLabels += "}"
  1486. if this.Labels != nil {
  1487. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1488. }
  1489. s = append(s, "ServiceIDs: "+fmt.Sprintf("%#v", this.ServiceIDs)+",\n")
  1490. s = append(s, "NodeIDs: "+fmt.Sprintf("%#v", this.NodeIDs)+",\n")
  1491. s = append(s, "DesiredStates: "+fmt.Sprintf("%#v", this.DesiredStates)+",\n")
  1492. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1493. s = append(s, "}")
  1494. return strings.Join(s, "")
  1495. }
  1496. func (this *ListTasksResponse) GoString() string {
  1497. if this == nil {
  1498. return "nil"
  1499. }
  1500. s := make([]string, 0, 5)
  1501. s = append(s, "&api.ListTasksResponse{")
  1502. if this.Tasks != nil {
  1503. s = append(s, "Tasks: "+fmt.Sprintf("%#v", this.Tasks)+",\n")
  1504. }
  1505. s = append(s, "}")
  1506. return strings.Join(s, "")
  1507. }
  1508. func (this *CreateServiceRequest) GoString() string {
  1509. if this == nil {
  1510. return "nil"
  1511. }
  1512. s := make([]string, 0, 5)
  1513. s = append(s, "&api.CreateServiceRequest{")
  1514. if this.Spec != nil {
  1515. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1516. }
  1517. s = append(s, "}")
  1518. return strings.Join(s, "")
  1519. }
  1520. func (this *CreateServiceResponse) GoString() string {
  1521. if this == nil {
  1522. return "nil"
  1523. }
  1524. s := make([]string, 0, 5)
  1525. s = append(s, "&api.CreateServiceResponse{")
  1526. if this.Service != nil {
  1527. s = append(s, "Service: "+fmt.Sprintf("%#v", this.Service)+",\n")
  1528. }
  1529. s = append(s, "}")
  1530. return strings.Join(s, "")
  1531. }
  1532. func (this *GetServiceRequest) GoString() string {
  1533. if this == nil {
  1534. return "nil"
  1535. }
  1536. s := make([]string, 0, 5)
  1537. s = append(s, "&api.GetServiceRequest{")
  1538. s = append(s, "ServiceID: "+fmt.Sprintf("%#v", this.ServiceID)+",\n")
  1539. s = append(s, "}")
  1540. return strings.Join(s, "")
  1541. }
  1542. func (this *GetServiceResponse) GoString() string {
  1543. if this == nil {
  1544. return "nil"
  1545. }
  1546. s := make([]string, 0, 5)
  1547. s = append(s, "&api.GetServiceResponse{")
  1548. if this.Service != nil {
  1549. s = append(s, "Service: "+fmt.Sprintf("%#v", this.Service)+",\n")
  1550. }
  1551. s = append(s, "}")
  1552. return strings.Join(s, "")
  1553. }
  1554. func (this *UpdateServiceRequest) GoString() string {
  1555. if this == nil {
  1556. return "nil"
  1557. }
  1558. s := make([]string, 0, 7)
  1559. s = append(s, "&api.UpdateServiceRequest{")
  1560. s = append(s, "ServiceID: "+fmt.Sprintf("%#v", this.ServiceID)+",\n")
  1561. if this.ServiceVersion != nil {
  1562. s = append(s, "ServiceVersion: "+fmt.Sprintf("%#v", this.ServiceVersion)+",\n")
  1563. }
  1564. if this.Spec != nil {
  1565. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1566. }
  1567. s = append(s, "}")
  1568. return strings.Join(s, "")
  1569. }
  1570. func (this *UpdateServiceResponse) GoString() string {
  1571. if this == nil {
  1572. return "nil"
  1573. }
  1574. s := make([]string, 0, 5)
  1575. s = append(s, "&api.UpdateServiceResponse{")
  1576. if this.Service != nil {
  1577. s = append(s, "Service: "+fmt.Sprintf("%#v", this.Service)+",\n")
  1578. }
  1579. s = append(s, "}")
  1580. return strings.Join(s, "")
  1581. }
  1582. func (this *RemoveServiceRequest) GoString() string {
  1583. if this == nil {
  1584. return "nil"
  1585. }
  1586. s := make([]string, 0, 5)
  1587. s = append(s, "&api.RemoveServiceRequest{")
  1588. s = append(s, "ServiceID: "+fmt.Sprintf("%#v", this.ServiceID)+",\n")
  1589. s = append(s, "}")
  1590. return strings.Join(s, "")
  1591. }
  1592. func (this *RemoveServiceResponse) GoString() string {
  1593. if this == nil {
  1594. return "nil"
  1595. }
  1596. s := make([]string, 0, 4)
  1597. s = append(s, "&api.RemoveServiceResponse{")
  1598. s = append(s, "}")
  1599. return strings.Join(s, "")
  1600. }
  1601. func (this *ListServicesRequest) GoString() string {
  1602. if this == nil {
  1603. return "nil"
  1604. }
  1605. s := make([]string, 0, 5)
  1606. s = append(s, "&api.ListServicesRequest{")
  1607. if this.Filters != nil {
  1608. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1609. }
  1610. s = append(s, "}")
  1611. return strings.Join(s, "")
  1612. }
  1613. func (this *ListServicesRequest_Filters) GoString() string {
  1614. if this == nil {
  1615. return "nil"
  1616. }
  1617. s := make([]string, 0, 8)
  1618. s = append(s, "&api.ListServicesRequest_Filters{")
  1619. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1620. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1621. keysForLabels := make([]string, 0, len(this.Labels))
  1622. for k, _ := range this.Labels {
  1623. keysForLabels = append(keysForLabels, k)
  1624. }
  1625. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1626. mapStringForLabels := "map[string]string{"
  1627. for _, k := range keysForLabels {
  1628. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1629. }
  1630. mapStringForLabels += "}"
  1631. if this.Labels != nil {
  1632. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1633. }
  1634. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1635. s = append(s, "}")
  1636. return strings.Join(s, "")
  1637. }
  1638. func (this *ListServicesResponse) GoString() string {
  1639. if this == nil {
  1640. return "nil"
  1641. }
  1642. s := make([]string, 0, 5)
  1643. s = append(s, "&api.ListServicesResponse{")
  1644. if this.Services != nil {
  1645. s = append(s, "Services: "+fmt.Sprintf("%#v", this.Services)+",\n")
  1646. }
  1647. s = append(s, "}")
  1648. return strings.Join(s, "")
  1649. }
  1650. func (this *CreateNetworkRequest) GoString() string {
  1651. if this == nil {
  1652. return "nil"
  1653. }
  1654. s := make([]string, 0, 5)
  1655. s = append(s, "&api.CreateNetworkRequest{")
  1656. if this.Spec != nil {
  1657. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1658. }
  1659. s = append(s, "}")
  1660. return strings.Join(s, "")
  1661. }
  1662. func (this *CreateNetworkResponse) GoString() string {
  1663. if this == nil {
  1664. return "nil"
  1665. }
  1666. s := make([]string, 0, 5)
  1667. s = append(s, "&api.CreateNetworkResponse{")
  1668. if this.Network != nil {
  1669. s = append(s, "Network: "+fmt.Sprintf("%#v", this.Network)+",\n")
  1670. }
  1671. s = append(s, "}")
  1672. return strings.Join(s, "")
  1673. }
  1674. func (this *GetNetworkRequest) GoString() string {
  1675. if this == nil {
  1676. return "nil"
  1677. }
  1678. s := make([]string, 0, 6)
  1679. s = append(s, "&api.GetNetworkRequest{")
  1680. s = append(s, "Name: "+fmt.Sprintf("%#v", this.Name)+",\n")
  1681. s = append(s, "NetworkID: "+fmt.Sprintf("%#v", this.NetworkID)+",\n")
  1682. s = append(s, "}")
  1683. return strings.Join(s, "")
  1684. }
  1685. func (this *GetNetworkResponse) GoString() string {
  1686. if this == nil {
  1687. return "nil"
  1688. }
  1689. s := make([]string, 0, 5)
  1690. s = append(s, "&api.GetNetworkResponse{")
  1691. if this.Network != nil {
  1692. s = append(s, "Network: "+fmt.Sprintf("%#v", this.Network)+",\n")
  1693. }
  1694. s = append(s, "}")
  1695. return strings.Join(s, "")
  1696. }
  1697. func (this *RemoveNetworkRequest) GoString() string {
  1698. if this == nil {
  1699. return "nil"
  1700. }
  1701. s := make([]string, 0, 6)
  1702. s = append(s, "&api.RemoveNetworkRequest{")
  1703. s = append(s, "Name: "+fmt.Sprintf("%#v", this.Name)+",\n")
  1704. s = append(s, "NetworkID: "+fmt.Sprintf("%#v", this.NetworkID)+",\n")
  1705. s = append(s, "}")
  1706. return strings.Join(s, "")
  1707. }
  1708. func (this *RemoveNetworkResponse) GoString() string {
  1709. if this == nil {
  1710. return "nil"
  1711. }
  1712. s := make([]string, 0, 4)
  1713. s = append(s, "&api.RemoveNetworkResponse{")
  1714. s = append(s, "}")
  1715. return strings.Join(s, "")
  1716. }
  1717. func (this *ListNetworksRequest) GoString() string {
  1718. if this == nil {
  1719. return "nil"
  1720. }
  1721. s := make([]string, 0, 5)
  1722. s = append(s, "&api.ListNetworksRequest{")
  1723. if this.Filters != nil {
  1724. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1725. }
  1726. s = append(s, "}")
  1727. return strings.Join(s, "")
  1728. }
  1729. func (this *ListNetworksRequest_Filters) GoString() string {
  1730. if this == nil {
  1731. return "nil"
  1732. }
  1733. s := make([]string, 0, 8)
  1734. s = append(s, "&api.ListNetworksRequest_Filters{")
  1735. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1736. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1737. keysForLabels := make([]string, 0, len(this.Labels))
  1738. for k, _ := range this.Labels {
  1739. keysForLabels = append(keysForLabels, k)
  1740. }
  1741. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1742. mapStringForLabels := "map[string]string{"
  1743. for _, k := range keysForLabels {
  1744. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1745. }
  1746. mapStringForLabels += "}"
  1747. if this.Labels != nil {
  1748. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1749. }
  1750. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1751. s = append(s, "}")
  1752. return strings.Join(s, "")
  1753. }
  1754. func (this *ListNetworksResponse) GoString() string {
  1755. if this == nil {
  1756. return "nil"
  1757. }
  1758. s := make([]string, 0, 5)
  1759. s = append(s, "&api.ListNetworksResponse{")
  1760. if this.Networks != nil {
  1761. s = append(s, "Networks: "+fmt.Sprintf("%#v", this.Networks)+",\n")
  1762. }
  1763. s = append(s, "}")
  1764. return strings.Join(s, "")
  1765. }
  1766. func (this *GetClusterRequest) GoString() string {
  1767. if this == nil {
  1768. return "nil"
  1769. }
  1770. s := make([]string, 0, 5)
  1771. s = append(s, "&api.GetClusterRequest{")
  1772. s = append(s, "ClusterID: "+fmt.Sprintf("%#v", this.ClusterID)+",\n")
  1773. s = append(s, "}")
  1774. return strings.Join(s, "")
  1775. }
  1776. func (this *GetClusterResponse) GoString() string {
  1777. if this == nil {
  1778. return "nil"
  1779. }
  1780. s := make([]string, 0, 5)
  1781. s = append(s, "&api.GetClusterResponse{")
  1782. if this.Cluster != nil {
  1783. s = append(s, "Cluster: "+fmt.Sprintf("%#v", this.Cluster)+",\n")
  1784. }
  1785. s = append(s, "}")
  1786. return strings.Join(s, "")
  1787. }
  1788. func (this *ListClustersRequest) GoString() string {
  1789. if this == nil {
  1790. return "nil"
  1791. }
  1792. s := make([]string, 0, 5)
  1793. s = append(s, "&api.ListClustersRequest{")
  1794. if this.Filters != nil {
  1795. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1796. }
  1797. s = append(s, "}")
  1798. return strings.Join(s, "")
  1799. }
  1800. func (this *ListClustersRequest_Filters) GoString() string {
  1801. if this == nil {
  1802. return "nil"
  1803. }
  1804. s := make([]string, 0, 8)
  1805. s = append(s, "&api.ListClustersRequest_Filters{")
  1806. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1807. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1808. keysForLabels := make([]string, 0, len(this.Labels))
  1809. for k, _ := range this.Labels {
  1810. keysForLabels = append(keysForLabels, k)
  1811. }
  1812. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1813. mapStringForLabels := "map[string]string{"
  1814. for _, k := range keysForLabels {
  1815. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1816. }
  1817. mapStringForLabels += "}"
  1818. if this.Labels != nil {
  1819. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1820. }
  1821. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1822. s = append(s, "}")
  1823. return strings.Join(s, "")
  1824. }
  1825. func (this *ListClustersResponse) GoString() string {
  1826. if this == nil {
  1827. return "nil"
  1828. }
  1829. s := make([]string, 0, 5)
  1830. s = append(s, "&api.ListClustersResponse{")
  1831. if this.Clusters != nil {
  1832. s = append(s, "Clusters: "+fmt.Sprintf("%#v", this.Clusters)+",\n")
  1833. }
  1834. s = append(s, "}")
  1835. return strings.Join(s, "")
  1836. }
  1837. func (this *KeyRotation) GoString() string {
  1838. if this == nil {
  1839. return "nil"
  1840. }
  1841. s := make([]string, 0, 7)
  1842. s = append(s, "&api.KeyRotation{")
  1843. s = append(s, "WorkerJoinToken: "+fmt.Sprintf("%#v", this.WorkerJoinToken)+",\n")
  1844. s = append(s, "ManagerJoinToken: "+fmt.Sprintf("%#v", this.ManagerJoinToken)+",\n")
  1845. s = append(s, "ManagerUnlockKey: "+fmt.Sprintf("%#v", this.ManagerUnlockKey)+",\n")
  1846. s = append(s, "}")
  1847. return strings.Join(s, "")
  1848. }
  1849. func (this *UpdateClusterRequest) GoString() string {
  1850. if this == nil {
  1851. return "nil"
  1852. }
  1853. s := make([]string, 0, 8)
  1854. s = append(s, "&api.UpdateClusterRequest{")
  1855. s = append(s, "ClusterID: "+fmt.Sprintf("%#v", this.ClusterID)+",\n")
  1856. if this.ClusterVersion != nil {
  1857. s = append(s, "ClusterVersion: "+fmt.Sprintf("%#v", this.ClusterVersion)+",\n")
  1858. }
  1859. if this.Spec != nil {
  1860. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1861. }
  1862. s = append(s, "Rotation: "+strings.Replace(this.Rotation.GoString(), `&`, ``, 1)+",\n")
  1863. s = append(s, "}")
  1864. return strings.Join(s, "")
  1865. }
  1866. func (this *UpdateClusterResponse) GoString() string {
  1867. if this == nil {
  1868. return "nil"
  1869. }
  1870. s := make([]string, 0, 5)
  1871. s = append(s, "&api.UpdateClusterResponse{")
  1872. if this.Cluster != nil {
  1873. s = append(s, "Cluster: "+fmt.Sprintf("%#v", this.Cluster)+",\n")
  1874. }
  1875. s = append(s, "}")
  1876. return strings.Join(s, "")
  1877. }
  1878. func (this *GetSecretRequest) GoString() string {
  1879. if this == nil {
  1880. return "nil"
  1881. }
  1882. s := make([]string, 0, 5)
  1883. s = append(s, "&api.GetSecretRequest{")
  1884. s = append(s, "SecretID: "+fmt.Sprintf("%#v", this.SecretID)+",\n")
  1885. s = append(s, "}")
  1886. return strings.Join(s, "")
  1887. }
  1888. func (this *GetSecretResponse) GoString() string {
  1889. if this == nil {
  1890. return "nil"
  1891. }
  1892. s := make([]string, 0, 5)
  1893. s = append(s, "&api.GetSecretResponse{")
  1894. if this.Secret != nil {
  1895. s = append(s, "Secret: "+fmt.Sprintf("%#v", this.Secret)+",\n")
  1896. }
  1897. s = append(s, "}")
  1898. return strings.Join(s, "")
  1899. }
  1900. func (this *UpdateSecretRequest) GoString() string {
  1901. if this == nil {
  1902. return "nil"
  1903. }
  1904. s := make([]string, 0, 7)
  1905. s = append(s, "&api.UpdateSecretRequest{")
  1906. s = append(s, "SecretID: "+fmt.Sprintf("%#v", this.SecretID)+",\n")
  1907. if this.SecretVersion != nil {
  1908. s = append(s, "SecretVersion: "+fmt.Sprintf("%#v", this.SecretVersion)+",\n")
  1909. }
  1910. if this.Spec != nil {
  1911. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1912. }
  1913. s = append(s, "}")
  1914. return strings.Join(s, "")
  1915. }
  1916. func (this *UpdateSecretResponse) GoString() string {
  1917. if this == nil {
  1918. return "nil"
  1919. }
  1920. s := make([]string, 0, 5)
  1921. s = append(s, "&api.UpdateSecretResponse{")
  1922. if this.Secret != nil {
  1923. s = append(s, "Secret: "+fmt.Sprintf("%#v", this.Secret)+",\n")
  1924. }
  1925. s = append(s, "}")
  1926. return strings.Join(s, "")
  1927. }
  1928. func (this *ListSecretsRequest) GoString() string {
  1929. if this == nil {
  1930. return "nil"
  1931. }
  1932. s := make([]string, 0, 5)
  1933. s = append(s, "&api.ListSecretsRequest{")
  1934. if this.Filters != nil {
  1935. s = append(s, "Filters: "+fmt.Sprintf("%#v", this.Filters)+",\n")
  1936. }
  1937. s = append(s, "}")
  1938. return strings.Join(s, "")
  1939. }
  1940. func (this *ListSecretsRequest_Filters) GoString() string {
  1941. if this == nil {
  1942. return "nil"
  1943. }
  1944. s := make([]string, 0, 8)
  1945. s = append(s, "&api.ListSecretsRequest_Filters{")
  1946. s = append(s, "Names: "+fmt.Sprintf("%#v", this.Names)+",\n")
  1947. s = append(s, "IDPrefixes: "+fmt.Sprintf("%#v", this.IDPrefixes)+",\n")
  1948. keysForLabels := make([]string, 0, len(this.Labels))
  1949. for k, _ := range this.Labels {
  1950. keysForLabels = append(keysForLabels, k)
  1951. }
  1952. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  1953. mapStringForLabels := "map[string]string{"
  1954. for _, k := range keysForLabels {
  1955. mapStringForLabels += fmt.Sprintf("%#v: %#v,", k, this.Labels[k])
  1956. }
  1957. mapStringForLabels += "}"
  1958. if this.Labels != nil {
  1959. s = append(s, "Labels: "+mapStringForLabels+",\n")
  1960. }
  1961. s = append(s, "NamePrefixes: "+fmt.Sprintf("%#v", this.NamePrefixes)+",\n")
  1962. s = append(s, "}")
  1963. return strings.Join(s, "")
  1964. }
  1965. func (this *ListSecretsResponse) GoString() string {
  1966. if this == nil {
  1967. return "nil"
  1968. }
  1969. s := make([]string, 0, 5)
  1970. s = append(s, "&api.ListSecretsResponse{")
  1971. if this.Secrets != nil {
  1972. s = append(s, "Secrets: "+fmt.Sprintf("%#v", this.Secrets)+",\n")
  1973. }
  1974. s = append(s, "}")
  1975. return strings.Join(s, "")
  1976. }
  1977. func (this *CreateSecretRequest) GoString() string {
  1978. if this == nil {
  1979. return "nil"
  1980. }
  1981. s := make([]string, 0, 5)
  1982. s = append(s, "&api.CreateSecretRequest{")
  1983. if this.Spec != nil {
  1984. s = append(s, "Spec: "+fmt.Sprintf("%#v", this.Spec)+",\n")
  1985. }
  1986. s = append(s, "}")
  1987. return strings.Join(s, "")
  1988. }
  1989. func (this *CreateSecretResponse) GoString() string {
  1990. if this == nil {
  1991. return "nil"
  1992. }
  1993. s := make([]string, 0, 5)
  1994. s = append(s, "&api.CreateSecretResponse{")
  1995. if this.Secret != nil {
  1996. s = append(s, "Secret: "+fmt.Sprintf("%#v", this.Secret)+",\n")
  1997. }
  1998. s = append(s, "}")
  1999. return strings.Join(s, "")
  2000. }
  2001. func (this *RemoveSecretRequest) GoString() string {
  2002. if this == nil {
  2003. return "nil"
  2004. }
  2005. s := make([]string, 0, 5)
  2006. s = append(s, "&api.RemoveSecretRequest{")
  2007. s = append(s, "SecretID: "+fmt.Sprintf("%#v", this.SecretID)+",\n")
  2008. s = append(s, "}")
  2009. return strings.Join(s, "")
  2010. }
  2011. func (this *RemoveSecretResponse) GoString() string {
  2012. if this == nil {
  2013. return "nil"
  2014. }
  2015. s := make([]string, 0, 4)
  2016. s = append(s, "&api.RemoveSecretResponse{")
  2017. s = append(s, "}")
  2018. return strings.Join(s, "")
  2019. }
  2020. func valueToGoStringControl(v interface{}, typ string) string {
  2021. rv := reflect.ValueOf(v)
  2022. if rv.IsNil() {
  2023. return "nil"
  2024. }
  2025. pv := reflect.Indirect(rv).Interface()
  2026. return fmt.Sprintf("func(v %v) *%v { return &v } ( %#v )", typ, typ, pv)
  2027. }
  2028. func extensionToGoStringControl(m github_com_gogo_protobuf_proto.Message) string {
  2029. e := github_com_gogo_protobuf_proto.GetUnsafeExtensionsMap(m)
  2030. if e == nil {
  2031. return "nil"
  2032. }
  2033. s := "proto.NewUnsafeXXX_InternalExtensions(map[int32]proto.Extension{"
  2034. keys := make([]int, 0, len(e))
  2035. for k := range e {
  2036. keys = append(keys, int(k))
  2037. }
  2038. sort.Ints(keys)
  2039. ss := []string{}
  2040. for _, k := range keys {
  2041. ss = append(ss, strconv.Itoa(k)+": "+e[int32(k)].GoString())
  2042. }
  2043. s += strings.Join(ss, ",") + "})"
  2044. return s
  2045. }
  2046. // Reference imports to suppress errors if they are not otherwise used.
  2047. var _ context.Context
  2048. var _ grpc.ClientConn
  2049. // This is a compile-time assertion to ensure that this generated file
  2050. // is compatible with the grpc package it is being compiled against.
  2051. const _ = grpc.SupportPackageIsVersion3
  2052. // Client API for Control service
  2053. type ControlClient interface {
  2054. GetNode(ctx context.Context, in *GetNodeRequest, opts ...grpc.CallOption) (*GetNodeResponse, error)
  2055. ListNodes(ctx context.Context, in *ListNodesRequest, opts ...grpc.CallOption) (*ListNodesResponse, error)
  2056. UpdateNode(ctx context.Context, in *UpdateNodeRequest, opts ...grpc.CallOption) (*UpdateNodeResponse, error)
  2057. RemoveNode(ctx context.Context, in *RemoveNodeRequest, opts ...grpc.CallOption) (*RemoveNodeResponse, error)
  2058. GetTask(ctx context.Context, in *GetTaskRequest, opts ...grpc.CallOption) (*GetTaskResponse, error)
  2059. ListTasks(ctx context.Context, in *ListTasksRequest, opts ...grpc.CallOption) (*ListTasksResponse, error)
  2060. RemoveTask(ctx context.Context, in *RemoveTaskRequest, opts ...grpc.CallOption) (*RemoveTaskResponse, error)
  2061. GetService(ctx context.Context, in *GetServiceRequest, opts ...grpc.CallOption) (*GetServiceResponse, error)
  2062. ListServices(ctx context.Context, in *ListServicesRequest, opts ...grpc.CallOption) (*ListServicesResponse, error)
  2063. CreateService(ctx context.Context, in *CreateServiceRequest, opts ...grpc.CallOption) (*CreateServiceResponse, error)
  2064. UpdateService(ctx context.Context, in *UpdateServiceRequest, opts ...grpc.CallOption) (*UpdateServiceResponse, error)
  2065. RemoveService(ctx context.Context, in *RemoveServiceRequest, opts ...grpc.CallOption) (*RemoveServiceResponse, error)
  2066. GetNetwork(ctx context.Context, in *GetNetworkRequest, opts ...grpc.CallOption) (*GetNetworkResponse, error)
  2067. ListNetworks(ctx context.Context, in *ListNetworksRequest, opts ...grpc.CallOption) (*ListNetworksResponse, error)
  2068. CreateNetwork(ctx context.Context, in *CreateNetworkRequest, opts ...grpc.CallOption) (*CreateNetworkResponse, error)
  2069. RemoveNetwork(ctx context.Context, in *RemoveNetworkRequest, opts ...grpc.CallOption) (*RemoveNetworkResponse, error)
  2070. GetCluster(ctx context.Context, in *GetClusterRequest, opts ...grpc.CallOption) (*GetClusterResponse, error)
  2071. ListClusters(ctx context.Context, in *ListClustersRequest, opts ...grpc.CallOption) (*ListClustersResponse, error)
  2072. UpdateCluster(ctx context.Context, in *UpdateClusterRequest, opts ...grpc.CallOption) (*UpdateClusterResponse, error)
  2073. // GetSecret returns a `GetSecretResponse` with a `Secret` with the same
  2074. // id as `GetSecretRequest.SecretID`
  2075. // - Returns `NotFound` if the Secret with the given id is not found.
  2076. // - Returns `InvalidArgument` if the `GetSecretRequest.SecretID` is empty.
  2077. // - Returns an error if getting fails.
  2078. GetSecret(ctx context.Context, in *GetSecretRequest, opts ...grpc.CallOption) (*GetSecretResponse, error)
  2079. // UpdateSecret returns a `UpdateSecretResponse` with a `Secret` with the same
  2080. // id as `GetSecretRequest.SecretID`
  2081. // - Returns `NotFound` if the Secret with the given id is not found.
  2082. // - Returns `InvalidArgument` if the `GetSecretRequest.SecretID` is empty.
  2083. // - Returns an error if updating fails.
  2084. UpdateSecret(ctx context.Context, in *UpdateSecretRequest, opts ...grpc.CallOption) (*UpdateSecretResponse, error)
  2085. // ListSecrets returns a `ListSecretResponse` with a list all non-internal `Secret`s being
  2086. // managed, or all secrets matching any name in `ListSecretsRequest.Names`, any
  2087. // name prefix in `ListSecretsRequest.NamePrefixes`, any id in
  2088. // `ListSecretsRequest.SecretIDs`, or any id prefix in `ListSecretsRequest.IDPrefixes`.
  2089. // - Returns an error if listing fails.
  2090. ListSecrets(ctx context.Context, in *ListSecretsRequest, opts ...grpc.CallOption) (*ListSecretsResponse, error)
  2091. // CreateSecret creates and return a `CreateSecretResponse` with a `Secret` based
  2092. // on the provided `CreateSecretRequest.SecretSpec`.
  2093. // - Returns `InvalidArgument` if the `CreateSecretRequest.SecretSpec` is malformed,
  2094. // or if the secret data is too long or contains invalid characters.
  2095. // - Returns an error if the creation fails.
  2096. CreateSecret(ctx context.Context, in *CreateSecretRequest, opts ...grpc.CallOption) (*CreateSecretResponse, error)
  2097. // RemoveSecret removes the secret referenced by `RemoveSecretRequest.ID`.
  2098. // - Returns `InvalidArgument` if `RemoveSecretRequest.ID` is empty.
  2099. // - Returns `NotFound` if the a secret named `RemoveSecretRequest.ID` is not found.
  2100. // - Returns an error if the deletion fails.
  2101. RemoveSecret(ctx context.Context, in *RemoveSecretRequest, opts ...grpc.CallOption) (*RemoveSecretResponse, error)
  2102. }
  2103. type controlClient struct {
  2104. cc *grpc.ClientConn
  2105. }
  2106. func NewControlClient(cc *grpc.ClientConn) ControlClient {
  2107. return &controlClient{cc}
  2108. }
  2109. func (c *controlClient) GetNode(ctx context.Context, in *GetNodeRequest, opts ...grpc.CallOption) (*GetNodeResponse, error) {
  2110. out := new(GetNodeResponse)
  2111. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetNode", in, out, c.cc, opts...)
  2112. if err != nil {
  2113. return nil, err
  2114. }
  2115. return out, nil
  2116. }
  2117. func (c *controlClient) ListNodes(ctx context.Context, in *ListNodesRequest, opts ...grpc.CallOption) (*ListNodesResponse, error) {
  2118. out := new(ListNodesResponse)
  2119. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListNodes", in, out, c.cc, opts...)
  2120. if err != nil {
  2121. return nil, err
  2122. }
  2123. return out, nil
  2124. }
  2125. func (c *controlClient) UpdateNode(ctx context.Context, in *UpdateNodeRequest, opts ...grpc.CallOption) (*UpdateNodeResponse, error) {
  2126. out := new(UpdateNodeResponse)
  2127. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/UpdateNode", in, out, c.cc, opts...)
  2128. if err != nil {
  2129. return nil, err
  2130. }
  2131. return out, nil
  2132. }
  2133. func (c *controlClient) RemoveNode(ctx context.Context, in *RemoveNodeRequest, opts ...grpc.CallOption) (*RemoveNodeResponse, error) {
  2134. out := new(RemoveNodeResponse)
  2135. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/RemoveNode", in, out, c.cc, opts...)
  2136. if err != nil {
  2137. return nil, err
  2138. }
  2139. return out, nil
  2140. }
  2141. func (c *controlClient) GetTask(ctx context.Context, in *GetTaskRequest, opts ...grpc.CallOption) (*GetTaskResponse, error) {
  2142. out := new(GetTaskResponse)
  2143. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetTask", in, out, c.cc, opts...)
  2144. if err != nil {
  2145. return nil, err
  2146. }
  2147. return out, nil
  2148. }
  2149. func (c *controlClient) ListTasks(ctx context.Context, in *ListTasksRequest, opts ...grpc.CallOption) (*ListTasksResponse, error) {
  2150. out := new(ListTasksResponse)
  2151. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListTasks", in, out, c.cc, opts...)
  2152. if err != nil {
  2153. return nil, err
  2154. }
  2155. return out, nil
  2156. }
  2157. func (c *controlClient) RemoveTask(ctx context.Context, in *RemoveTaskRequest, opts ...grpc.CallOption) (*RemoveTaskResponse, error) {
  2158. out := new(RemoveTaskResponse)
  2159. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/RemoveTask", in, out, c.cc, opts...)
  2160. if err != nil {
  2161. return nil, err
  2162. }
  2163. return out, nil
  2164. }
  2165. func (c *controlClient) GetService(ctx context.Context, in *GetServiceRequest, opts ...grpc.CallOption) (*GetServiceResponse, error) {
  2166. out := new(GetServiceResponse)
  2167. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetService", in, out, c.cc, opts...)
  2168. if err != nil {
  2169. return nil, err
  2170. }
  2171. return out, nil
  2172. }
  2173. func (c *controlClient) ListServices(ctx context.Context, in *ListServicesRequest, opts ...grpc.CallOption) (*ListServicesResponse, error) {
  2174. out := new(ListServicesResponse)
  2175. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListServices", in, out, c.cc, opts...)
  2176. if err != nil {
  2177. return nil, err
  2178. }
  2179. return out, nil
  2180. }
  2181. func (c *controlClient) CreateService(ctx context.Context, in *CreateServiceRequest, opts ...grpc.CallOption) (*CreateServiceResponse, error) {
  2182. out := new(CreateServiceResponse)
  2183. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/CreateService", in, out, c.cc, opts...)
  2184. if err != nil {
  2185. return nil, err
  2186. }
  2187. return out, nil
  2188. }
  2189. func (c *controlClient) UpdateService(ctx context.Context, in *UpdateServiceRequest, opts ...grpc.CallOption) (*UpdateServiceResponse, error) {
  2190. out := new(UpdateServiceResponse)
  2191. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/UpdateService", in, out, c.cc, opts...)
  2192. if err != nil {
  2193. return nil, err
  2194. }
  2195. return out, nil
  2196. }
  2197. func (c *controlClient) RemoveService(ctx context.Context, in *RemoveServiceRequest, opts ...grpc.CallOption) (*RemoveServiceResponse, error) {
  2198. out := new(RemoveServiceResponse)
  2199. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/RemoveService", in, out, c.cc, opts...)
  2200. if err != nil {
  2201. return nil, err
  2202. }
  2203. return out, nil
  2204. }
  2205. func (c *controlClient) GetNetwork(ctx context.Context, in *GetNetworkRequest, opts ...grpc.CallOption) (*GetNetworkResponse, error) {
  2206. out := new(GetNetworkResponse)
  2207. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetNetwork", in, out, c.cc, opts...)
  2208. if err != nil {
  2209. return nil, err
  2210. }
  2211. return out, nil
  2212. }
  2213. func (c *controlClient) ListNetworks(ctx context.Context, in *ListNetworksRequest, opts ...grpc.CallOption) (*ListNetworksResponse, error) {
  2214. out := new(ListNetworksResponse)
  2215. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListNetworks", in, out, c.cc, opts...)
  2216. if err != nil {
  2217. return nil, err
  2218. }
  2219. return out, nil
  2220. }
  2221. func (c *controlClient) CreateNetwork(ctx context.Context, in *CreateNetworkRequest, opts ...grpc.CallOption) (*CreateNetworkResponse, error) {
  2222. out := new(CreateNetworkResponse)
  2223. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/CreateNetwork", in, out, c.cc, opts...)
  2224. if err != nil {
  2225. return nil, err
  2226. }
  2227. return out, nil
  2228. }
  2229. func (c *controlClient) RemoveNetwork(ctx context.Context, in *RemoveNetworkRequest, opts ...grpc.CallOption) (*RemoveNetworkResponse, error) {
  2230. out := new(RemoveNetworkResponse)
  2231. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/RemoveNetwork", in, out, c.cc, opts...)
  2232. if err != nil {
  2233. return nil, err
  2234. }
  2235. return out, nil
  2236. }
  2237. func (c *controlClient) GetCluster(ctx context.Context, in *GetClusterRequest, opts ...grpc.CallOption) (*GetClusterResponse, error) {
  2238. out := new(GetClusterResponse)
  2239. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetCluster", in, out, c.cc, opts...)
  2240. if err != nil {
  2241. return nil, err
  2242. }
  2243. return out, nil
  2244. }
  2245. func (c *controlClient) ListClusters(ctx context.Context, in *ListClustersRequest, opts ...grpc.CallOption) (*ListClustersResponse, error) {
  2246. out := new(ListClustersResponse)
  2247. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListClusters", in, out, c.cc, opts...)
  2248. if err != nil {
  2249. return nil, err
  2250. }
  2251. return out, nil
  2252. }
  2253. func (c *controlClient) UpdateCluster(ctx context.Context, in *UpdateClusterRequest, opts ...grpc.CallOption) (*UpdateClusterResponse, error) {
  2254. out := new(UpdateClusterResponse)
  2255. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/UpdateCluster", in, out, c.cc, opts...)
  2256. if err != nil {
  2257. return nil, err
  2258. }
  2259. return out, nil
  2260. }
  2261. func (c *controlClient) GetSecret(ctx context.Context, in *GetSecretRequest, opts ...grpc.CallOption) (*GetSecretResponse, error) {
  2262. out := new(GetSecretResponse)
  2263. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/GetSecret", in, out, c.cc, opts...)
  2264. if err != nil {
  2265. return nil, err
  2266. }
  2267. return out, nil
  2268. }
  2269. func (c *controlClient) UpdateSecret(ctx context.Context, in *UpdateSecretRequest, opts ...grpc.CallOption) (*UpdateSecretResponse, error) {
  2270. out := new(UpdateSecretResponse)
  2271. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/UpdateSecret", in, out, c.cc, opts...)
  2272. if err != nil {
  2273. return nil, err
  2274. }
  2275. return out, nil
  2276. }
  2277. func (c *controlClient) ListSecrets(ctx context.Context, in *ListSecretsRequest, opts ...grpc.CallOption) (*ListSecretsResponse, error) {
  2278. out := new(ListSecretsResponse)
  2279. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/ListSecrets", in, out, c.cc, opts...)
  2280. if err != nil {
  2281. return nil, err
  2282. }
  2283. return out, nil
  2284. }
  2285. func (c *controlClient) CreateSecret(ctx context.Context, in *CreateSecretRequest, opts ...grpc.CallOption) (*CreateSecretResponse, error) {
  2286. out := new(CreateSecretResponse)
  2287. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/CreateSecret", in, out, c.cc, opts...)
  2288. if err != nil {
  2289. return nil, err
  2290. }
  2291. return out, nil
  2292. }
  2293. func (c *controlClient) RemoveSecret(ctx context.Context, in *RemoveSecretRequest, opts ...grpc.CallOption) (*RemoveSecretResponse, error) {
  2294. out := new(RemoveSecretResponse)
  2295. err := grpc.Invoke(ctx, "/docker.swarmkit.v1.Control/RemoveSecret", in, out, c.cc, opts...)
  2296. if err != nil {
  2297. return nil, err
  2298. }
  2299. return out, nil
  2300. }
  2301. // Server API for Control service
  2302. type ControlServer interface {
  2303. GetNode(context.Context, *GetNodeRequest) (*GetNodeResponse, error)
  2304. ListNodes(context.Context, *ListNodesRequest) (*ListNodesResponse, error)
  2305. UpdateNode(context.Context, *UpdateNodeRequest) (*UpdateNodeResponse, error)
  2306. RemoveNode(context.Context, *RemoveNodeRequest) (*RemoveNodeResponse, error)
  2307. GetTask(context.Context, *GetTaskRequest) (*GetTaskResponse, error)
  2308. ListTasks(context.Context, *ListTasksRequest) (*ListTasksResponse, error)
  2309. RemoveTask(context.Context, *RemoveTaskRequest) (*RemoveTaskResponse, error)
  2310. GetService(context.Context, *GetServiceRequest) (*GetServiceResponse, error)
  2311. ListServices(context.Context, *ListServicesRequest) (*ListServicesResponse, error)
  2312. CreateService(context.Context, *CreateServiceRequest) (*CreateServiceResponse, error)
  2313. UpdateService(context.Context, *UpdateServiceRequest) (*UpdateServiceResponse, error)
  2314. RemoveService(context.Context, *RemoveServiceRequest) (*RemoveServiceResponse, error)
  2315. GetNetwork(context.Context, *GetNetworkRequest) (*GetNetworkResponse, error)
  2316. ListNetworks(context.Context, *ListNetworksRequest) (*ListNetworksResponse, error)
  2317. CreateNetwork(context.Context, *CreateNetworkRequest) (*CreateNetworkResponse, error)
  2318. RemoveNetwork(context.Context, *RemoveNetworkRequest) (*RemoveNetworkResponse, error)
  2319. GetCluster(context.Context, *GetClusterRequest) (*GetClusterResponse, error)
  2320. ListClusters(context.Context, *ListClustersRequest) (*ListClustersResponse, error)
  2321. UpdateCluster(context.Context, *UpdateClusterRequest) (*UpdateClusterResponse, error)
  2322. // GetSecret returns a `GetSecretResponse` with a `Secret` with the same
  2323. // id as `GetSecretRequest.SecretID`
  2324. // - Returns `NotFound` if the Secret with the given id is not found.
  2325. // - Returns `InvalidArgument` if the `GetSecretRequest.SecretID` is empty.
  2326. // - Returns an error if getting fails.
  2327. GetSecret(context.Context, *GetSecretRequest) (*GetSecretResponse, error)
  2328. // UpdateSecret returns a `UpdateSecretResponse` with a `Secret` with the same
  2329. // id as `GetSecretRequest.SecretID`
  2330. // - Returns `NotFound` if the Secret with the given id is not found.
  2331. // - Returns `InvalidArgument` if the `GetSecretRequest.SecretID` is empty.
  2332. // - Returns an error if updating fails.
  2333. UpdateSecret(context.Context, *UpdateSecretRequest) (*UpdateSecretResponse, error)
  2334. // ListSecrets returns a `ListSecretResponse` with a list all non-internal `Secret`s being
  2335. // managed, or all secrets matching any name in `ListSecretsRequest.Names`, any
  2336. // name prefix in `ListSecretsRequest.NamePrefixes`, any id in
  2337. // `ListSecretsRequest.SecretIDs`, or any id prefix in `ListSecretsRequest.IDPrefixes`.
  2338. // - Returns an error if listing fails.
  2339. ListSecrets(context.Context, *ListSecretsRequest) (*ListSecretsResponse, error)
  2340. // CreateSecret creates and return a `CreateSecretResponse` with a `Secret` based
  2341. // on the provided `CreateSecretRequest.SecretSpec`.
  2342. // - Returns `InvalidArgument` if the `CreateSecretRequest.SecretSpec` is malformed,
  2343. // or if the secret data is too long or contains invalid characters.
  2344. // - Returns an error if the creation fails.
  2345. CreateSecret(context.Context, *CreateSecretRequest) (*CreateSecretResponse, error)
  2346. // RemoveSecret removes the secret referenced by `RemoveSecretRequest.ID`.
  2347. // - Returns `InvalidArgument` if `RemoveSecretRequest.ID` is empty.
  2348. // - Returns `NotFound` if the a secret named `RemoveSecretRequest.ID` is not found.
  2349. // - Returns an error if the deletion fails.
  2350. RemoveSecret(context.Context, *RemoveSecretRequest) (*RemoveSecretResponse, error)
  2351. }
  2352. func RegisterControlServer(s *grpc.Server, srv ControlServer) {
  2353. s.RegisterService(&_Control_serviceDesc, srv)
  2354. }
  2355. func _Control_GetNode_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2356. in := new(GetNodeRequest)
  2357. if err := dec(in); err != nil {
  2358. return nil, err
  2359. }
  2360. if interceptor == nil {
  2361. return srv.(ControlServer).GetNode(ctx, in)
  2362. }
  2363. info := &grpc.UnaryServerInfo{
  2364. Server: srv,
  2365. FullMethod: "/docker.swarmkit.v1.Control/GetNode",
  2366. }
  2367. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2368. return srv.(ControlServer).GetNode(ctx, req.(*GetNodeRequest))
  2369. }
  2370. return interceptor(ctx, in, info, handler)
  2371. }
  2372. func _Control_ListNodes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2373. in := new(ListNodesRequest)
  2374. if err := dec(in); err != nil {
  2375. return nil, err
  2376. }
  2377. if interceptor == nil {
  2378. return srv.(ControlServer).ListNodes(ctx, in)
  2379. }
  2380. info := &grpc.UnaryServerInfo{
  2381. Server: srv,
  2382. FullMethod: "/docker.swarmkit.v1.Control/ListNodes",
  2383. }
  2384. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2385. return srv.(ControlServer).ListNodes(ctx, req.(*ListNodesRequest))
  2386. }
  2387. return interceptor(ctx, in, info, handler)
  2388. }
  2389. func _Control_UpdateNode_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2390. in := new(UpdateNodeRequest)
  2391. if err := dec(in); err != nil {
  2392. return nil, err
  2393. }
  2394. if interceptor == nil {
  2395. return srv.(ControlServer).UpdateNode(ctx, in)
  2396. }
  2397. info := &grpc.UnaryServerInfo{
  2398. Server: srv,
  2399. FullMethod: "/docker.swarmkit.v1.Control/UpdateNode",
  2400. }
  2401. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2402. return srv.(ControlServer).UpdateNode(ctx, req.(*UpdateNodeRequest))
  2403. }
  2404. return interceptor(ctx, in, info, handler)
  2405. }
  2406. func _Control_RemoveNode_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2407. in := new(RemoveNodeRequest)
  2408. if err := dec(in); err != nil {
  2409. return nil, err
  2410. }
  2411. if interceptor == nil {
  2412. return srv.(ControlServer).RemoveNode(ctx, in)
  2413. }
  2414. info := &grpc.UnaryServerInfo{
  2415. Server: srv,
  2416. FullMethod: "/docker.swarmkit.v1.Control/RemoveNode",
  2417. }
  2418. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2419. return srv.(ControlServer).RemoveNode(ctx, req.(*RemoveNodeRequest))
  2420. }
  2421. return interceptor(ctx, in, info, handler)
  2422. }
  2423. func _Control_GetTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2424. in := new(GetTaskRequest)
  2425. if err := dec(in); err != nil {
  2426. return nil, err
  2427. }
  2428. if interceptor == nil {
  2429. return srv.(ControlServer).GetTask(ctx, in)
  2430. }
  2431. info := &grpc.UnaryServerInfo{
  2432. Server: srv,
  2433. FullMethod: "/docker.swarmkit.v1.Control/GetTask",
  2434. }
  2435. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2436. return srv.(ControlServer).GetTask(ctx, req.(*GetTaskRequest))
  2437. }
  2438. return interceptor(ctx, in, info, handler)
  2439. }
  2440. func _Control_ListTasks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2441. in := new(ListTasksRequest)
  2442. if err := dec(in); err != nil {
  2443. return nil, err
  2444. }
  2445. if interceptor == nil {
  2446. return srv.(ControlServer).ListTasks(ctx, in)
  2447. }
  2448. info := &grpc.UnaryServerInfo{
  2449. Server: srv,
  2450. FullMethod: "/docker.swarmkit.v1.Control/ListTasks",
  2451. }
  2452. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2453. return srv.(ControlServer).ListTasks(ctx, req.(*ListTasksRequest))
  2454. }
  2455. return interceptor(ctx, in, info, handler)
  2456. }
  2457. func _Control_RemoveTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2458. in := new(RemoveTaskRequest)
  2459. if err := dec(in); err != nil {
  2460. return nil, err
  2461. }
  2462. if interceptor == nil {
  2463. return srv.(ControlServer).RemoveTask(ctx, in)
  2464. }
  2465. info := &grpc.UnaryServerInfo{
  2466. Server: srv,
  2467. FullMethod: "/docker.swarmkit.v1.Control/RemoveTask",
  2468. }
  2469. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2470. return srv.(ControlServer).RemoveTask(ctx, req.(*RemoveTaskRequest))
  2471. }
  2472. return interceptor(ctx, in, info, handler)
  2473. }
  2474. func _Control_GetService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2475. in := new(GetServiceRequest)
  2476. if err := dec(in); err != nil {
  2477. return nil, err
  2478. }
  2479. if interceptor == nil {
  2480. return srv.(ControlServer).GetService(ctx, in)
  2481. }
  2482. info := &grpc.UnaryServerInfo{
  2483. Server: srv,
  2484. FullMethod: "/docker.swarmkit.v1.Control/GetService",
  2485. }
  2486. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2487. return srv.(ControlServer).GetService(ctx, req.(*GetServiceRequest))
  2488. }
  2489. return interceptor(ctx, in, info, handler)
  2490. }
  2491. func _Control_ListServices_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2492. in := new(ListServicesRequest)
  2493. if err := dec(in); err != nil {
  2494. return nil, err
  2495. }
  2496. if interceptor == nil {
  2497. return srv.(ControlServer).ListServices(ctx, in)
  2498. }
  2499. info := &grpc.UnaryServerInfo{
  2500. Server: srv,
  2501. FullMethod: "/docker.swarmkit.v1.Control/ListServices",
  2502. }
  2503. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2504. return srv.(ControlServer).ListServices(ctx, req.(*ListServicesRequest))
  2505. }
  2506. return interceptor(ctx, in, info, handler)
  2507. }
  2508. func _Control_CreateService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2509. in := new(CreateServiceRequest)
  2510. if err := dec(in); err != nil {
  2511. return nil, err
  2512. }
  2513. if interceptor == nil {
  2514. return srv.(ControlServer).CreateService(ctx, in)
  2515. }
  2516. info := &grpc.UnaryServerInfo{
  2517. Server: srv,
  2518. FullMethod: "/docker.swarmkit.v1.Control/CreateService",
  2519. }
  2520. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2521. return srv.(ControlServer).CreateService(ctx, req.(*CreateServiceRequest))
  2522. }
  2523. return interceptor(ctx, in, info, handler)
  2524. }
  2525. func _Control_UpdateService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2526. in := new(UpdateServiceRequest)
  2527. if err := dec(in); err != nil {
  2528. return nil, err
  2529. }
  2530. if interceptor == nil {
  2531. return srv.(ControlServer).UpdateService(ctx, in)
  2532. }
  2533. info := &grpc.UnaryServerInfo{
  2534. Server: srv,
  2535. FullMethod: "/docker.swarmkit.v1.Control/UpdateService",
  2536. }
  2537. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2538. return srv.(ControlServer).UpdateService(ctx, req.(*UpdateServiceRequest))
  2539. }
  2540. return interceptor(ctx, in, info, handler)
  2541. }
  2542. func _Control_RemoveService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2543. in := new(RemoveServiceRequest)
  2544. if err := dec(in); err != nil {
  2545. return nil, err
  2546. }
  2547. if interceptor == nil {
  2548. return srv.(ControlServer).RemoveService(ctx, in)
  2549. }
  2550. info := &grpc.UnaryServerInfo{
  2551. Server: srv,
  2552. FullMethod: "/docker.swarmkit.v1.Control/RemoveService",
  2553. }
  2554. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2555. return srv.(ControlServer).RemoveService(ctx, req.(*RemoveServiceRequest))
  2556. }
  2557. return interceptor(ctx, in, info, handler)
  2558. }
  2559. func _Control_GetNetwork_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2560. in := new(GetNetworkRequest)
  2561. if err := dec(in); err != nil {
  2562. return nil, err
  2563. }
  2564. if interceptor == nil {
  2565. return srv.(ControlServer).GetNetwork(ctx, in)
  2566. }
  2567. info := &grpc.UnaryServerInfo{
  2568. Server: srv,
  2569. FullMethod: "/docker.swarmkit.v1.Control/GetNetwork",
  2570. }
  2571. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2572. return srv.(ControlServer).GetNetwork(ctx, req.(*GetNetworkRequest))
  2573. }
  2574. return interceptor(ctx, in, info, handler)
  2575. }
  2576. func _Control_ListNetworks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2577. in := new(ListNetworksRequest)
  2578. if err := dec(in); err != nil {
  2579. return nil, err
  2580. }
  2581. if interceptor == nil {
  2582. return srv.(ControlServer).ListNetworks(ctx, in)
  2583. }
  2584. info := &grpc.UnaryServerInfo{
  2585. Server: srv,
  2586. FullMethod: "/docker.swarmkit.v1.Control/ListNetworks",
  2587. }
  2588. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2589. return srv.(ControlServer).ListNetworks(ctx, req.(*ListNetworksRequest))
  2590. }
  2591. return interceptor(ctx, in, info, handler)
  2592. }
  2593. func _Control_CreateNetwork_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2594. in := new(CreateNetworkRequest)
  2595. if err := dec(in); err != nil {
  2596. return nil, err
  2597. }
  2598. if interceptor == nil {
  2599. return srv.(ControlServer).CreateNetwork(ctx, in)
  2600. }
  2601. info := &grpc.UnaryServerInfo{
  2602. Server: srv,
  2603. FullMethod: "/docker.swarmkit.v1.Control/CreateNetwork",
  2604. }
  2605. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2606. return srv.(ControlServer).CreateNetwork(ctx, req.(*CreateNetworkRequest))
  2607. }
  2608. return interceptor(ctx, in, info, handler)
  2609. }
  2610. func _Control_RemoveNetwork_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2611. in := new(RemoveNetworkRequest)
  2612. if err := dec(in); err != nil {
  2613. return nil, err
  2614. }
  2615. if interceptor == nil {
  2616. return srv.(ControlServer).RemoveNetwork(ctx, in)
  2617. }
  2618. info := &grpc.UnaryServerInfo{
  2619. Server: srv,
  2620. FullMethod: "/docker.swarmkit.v1.Control/RemoveNetwork",
  2621. }
  2622. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2623. return srv.(ControlServer).RemoveNetwork(ctx, req.(*RemoveNetworkRequest))
  2624. }
  2625. return interceptor(ctx, in, info, handler)
  2626. }
  2627. func _Control_GetCluster_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2628. in := new(GetClusterRequest)
  2629. if err := dec(in); err != nil {
  2630. return nil, err
  2631. }
  2632. if interceptor == nil {
  2633. return srv.(ControlServer).GetCluster(ctx, in)
  2634. }
  2635. info := &grpc.UnaryServerInfo{
  2636. Server: srv,
  2637. FullMethod: "/docker.swarmkit.v1.Control/GetCluster",
  2638. }
  2639. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2640. return srv.(ControlServer).GetCluster(ctx, req.(*GetClusterRequest))
  2641. }
  2642. return interceptor(ctx, in, info, handler)
  2643. }
  2644. func _Control_ListClusters_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2645. in := new(ListClustersRequest)
  2646. if err := dec(in); err != nil {
  2647. return nil, err
  2648. }
  2649. if interceptor == nil {
  2650. return srv.(ControlServer).ListClusters(ctx, in)
  2651. }
  2652. info := &grpc.UnaryServerInfo{
  2653. Server: srv,
  2654. FullMethod: "/docker.swarmkit.v1.Control/ListClusters",
  2655. }
  2656. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2657. return srv.(ControlServer).ListClusters(ctx, req.(*ListClustersRequest))
  2658. }
  2659. return interceptor(ctx, in, info, handler)
  2660. }
  2661. func _Control_UpdateCluster_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2662. in := new(UpdateClusterRequest)
  2663. if err := dec(in); err != nil {
  2664. return nil, err
  2665. }
  2666. if interceptor == nil {
  2667. return srv.(ControlServer).UpdateCluster(ctx, in)
  2668. }
  2669. info := &grpc.UnaryServerInfo{
  2670. Server: srv,
  2671. FullMethod: "/docker.swarmkit.v1.Control/UpdateCluster",
  2672. }
  2673. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2674. return srv.(ControlServer).UpdateCluster(ctx, req.(*UpdateClusterRequest))
  2675. }
  2676. return interceptor(ctx, in, info, handler)
  2677. }
  2678. func _Control_GetSecret_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2679. in := new(GetSecretRequest)
  2680. if err := dec(in); err != nil {
  2681. return nil, err
  2682. }
  2683. if interceptor == nil {
  2684. return srv.(ControlServer).GetSecret(ctx, in)
  2685. }
  2686. info := &grpc.UnaryServerInfo{
  2687. Server: srv,
  2688. FullMethod: "/docker.swarmkit.v1.Control/GetSecret",
  2689. }
  2690. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2691. return srv.(ControlServer).GetSecret(ctx, req.(*GetSecretRequest))
  2692. }
  2693. return interceptor(ctx, in, info, handler)
  2694. }
  2695. func _Control_UpdateSecret_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2696. in := new(UpdateSecretRequest)
  2697. if err := dec(in); err != nil {
  2698. return nil, err
  2699. }
  2700. if interceptor == nil {
  2701. return srv.(ControlServer).UpdateSecret(ctx, in)
  2702. }
  2703. info := &grpc.UnaryServerInfo{
  2704. Server: srv,
  2705. FullMethod: "/docker.swarmkit.v1.Control/UpdateSecret",
  2706. }
  2707. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2708. return srv.(ControlServer).UpdateSecret(ctx, req.(*UpdateSecretRequest))
  2709. }
  2710. return interceptor(ctx, in, info, handler)
  2711. }
  2712. func _Control_ListSecrets_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2713. in := new(ListSecretsRequest)
  2714. if err := dec(in); err != nil {
  2715. return nil, err
  2716. }
  2717. if interceptor == nil {
  2718. return srv.(ControlServer).ListSecrets(ctx, in)
  2719. }
  2720. info := &grpc.UnaryServerInfo{
  2721. Server: srv,
  2722. FullMethod: "/docker.swarmkit.v1.Control/ListSecrets",
  2723. }
  2724. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2725. return srv.(ControlServer).ListSecrets(ctx, req.(*ListSecretsRequest))
  2726. }
  2727. return interceptor(ctx, in, info, handler)
  2728. }
  2729. func _Control_CreateSecret_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2730. in := new(CreateSecretRequest)
  2731. if err := dec(in); err != nil {
  2732. return nil, err
  2733. }
  2734. if interceptor == nil {
  2735. return srv.(ControlServer).CreateSecret(ctx, in)
  2736. }
  2737. info := &grpc.UnaryServerInfo{
  2738. Server: srv,
  2739. FullMethod: "/docker.swarmkit.v1.Control/CreateSecret",
  2740. }
  2741. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2742. return srv.(ControlServer).CreateSecret(ctx, req.(*CreateSecretRequest))
  2743. }
  2744. return interceptor(ctx, in, info, handler)
  2745. }
  2746. func _Control_RemoveSecret_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  2747. in := new(RemoveSecretRequest)
  2748. if err := dec(in); err != nil {
  2749. return nil, err
  2750. }
  2751. if interceptor == nil {
  2752. return srv.(ControlServer).RemoveSecret(ctx, in)
  2753. }
  2754. info := &grpc.UnaryServerInfo{
  2755. Server: srv,
  2756. FullMethod: "/docker.swarmkit.v1.Control/RemoveSecret",
  2757. }
  2758. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  2759. return srv.(ControlServer).RemoveSecret(ctx, req.(*RemoveSecretRequest))
  2760. }
  2761. return interceptor(ctx, in, info, handler)
  2762. }
  2763. var _Control_serviceDesc = grpc.ServiceDesc{
  2764. ServiceName: "docker.swarmkit.v1.Control",
  2765. HandlerType: (*ControlServer)(nil),
  2766. Methods: []grpc.MethodDesc{
  2767. {
  2768. MethodName: "GetNode",
  2769. Handler: _Control_GetNode_Handler,
  2770. },
  2771. {
  2772. MethodName: "ListNodes",
  2773. Handler: _Control_ListNodes_Handler,
  2774. },
  2775. {
  2776. MethodName: "UpdateNode",
  2777. Handler: _Control_UpdateNode_Handler,
  2778. },
  2779. {
  2780. MethodName: "RemoveNode",
  2781. Handler: _Control_RemoveNode_Handler,
  2782. },
  2783. {
  2784. MethodName: "GetTask",
  2785. Handler: _Control_GetTask_Handler,
  2786. },
  2787. {
  2788. MethodName: "ListTasks",
  2789. Handler: _Control_ListTasks_Handler,
  2790. },
  2791. {
  2792. MethodName: "RemoveTask",
  2793. Handler: _Control_RemoveTask_Handler,
  2794. },
  2795. {
  2796. MethodName: "GetService",
  2797. Handler: _Control_GetService_Handler,
  2798. },
  2799. {
  2800. MethodName: "ListServices",
  2801. Handler: _Control_ListServices_Handler,
  2802. },
  2803. {
  2804. MethodName: "CreateService",
  2805. Handler: _Control_CreateService_Handler,
  2806. },
  2807. {
  2808. MethodName: "UpdateService",
  2809. Handler: _Control_UpdateService_Handler,
  2810. },
  2811. {
  2812. MethodName: "RemoveService",
  2813. Handler: _Control_RemoveService_Handler,
  2814. },
  2815. {
  2816. MethodName: "GetNetwork",
  2817. Handler: _Control_GetNetwork_Handler,
  2818. },
  2819. {
  2820. MethodName: "ListNetworks",
  2821. Handler: _Control_ListNetworks_Handler,
  2822. },
  2823. {
  2824. MethodName: "CreateNetwork",
  2825. Handler: _Control_CreateNetwork_Handler,
  2826. },
  2827. {
  2828. MethodName: "RemoveNetwork",
  2829. Handler: _Control_RemoveNetwork_Handler,
  2830. },
  2831. {
  2832. MethodName: "GetCluster",
  2833. Handler: _Control_GetCluster_Handler,
  2834. },
  2835. {
  2836. MethodName: "ListClusters",
  2837. Handler: _Control_ListClusters_Handler,
  2838. },
  2839. {
  2840. MethodName: "UpdateCluster",
  2841. Handler: _Control_UpdateCluster_Handler,
  2842. },
  2843. {
  2844. MethodName: "GetSecret",
  2845. Handler: _Control_GetSecret_Handler,
  2846. },
  2847. {
  2848. MethodName: "UpdateSecret",
  2849. Handler: _Control_UpdateSecret_Handler,
  2850. },
  2851. {
  2852. MethodName: "ListSecrets",
  2853. Handler: _Control_ListSecrets_Handler,
  2854. },
  2855. {
  2856. MethodName: "CreateSecret",
  2857. Handler: _Control_CreateSecret_Handler,
  2858. },
  2859. {
  2860. MethodName: "RemoveSecret",
  2861. Handler: _Control_RemoveSecret_Handler,
  2862. },
  2863. },
  2864. Streams: []grpc.StreamDesc{},
  2865. Metadata: fileDescriptorControl,
  2866. }
  2867. func (m *GetNodeRequest) Marshal() (data []byte, err error) {
  2868. size := m.Size()
  2869. data = make([]byte, size)
  2870. n, err := m.MarshalTo(data)
  2871. if err != nil {
  2872. return nil, err
  2873. }
  2874. return data[:n], nil
  2875. }
  2876. func (m *GetNodeRequest) MarshalTo(data []byte) (int, error) {
  2877. var i int
  2878. _ = i
  2879. var l int
  2880. _ = l
  2881. if len(m.NodeID) > 0 {
  2882. data[i] = 0xa
  2883. i++
  2884. i = encodeVarintControl(data, i, uint64(len(m.NodeID)))
  2885. i += copy(data[i:], m.NodeID)
  2886. }
  2887. return i, nil
  2888. }
  2889. func (m *GetNodeResponse) Marshal() (data []byte, err error) {
  2890. size := m.Size()
  2891. data = make([]byte, size)
  2892. n, err := m.MarshalTo(data)
  2893. if err != nil {
  2894. return nil, err
  2895. }
  2896. return data[:n], nil
  2897. }
  2898. func (m *GetNodeResponse) MarshalTo(data []byte) (int, error) {
  2899. var i int
  2900. _ = i
  2901. var l int
  2902. _ = l
  2903. if m.Node != nil {
  2904. data[i] = 0xa
  2905. i++
  2906. i = encodeVarintControl(data, i, uint64(m.Node.Size()))
  2907. n1, err := m.Node.MarshalTo(data[i:])
  2908. if err != nil {
  2909. return 0, err
  2910. }
  2911. i += n1
  2912. }
  2913. return i, nil
  2914. }
  2915. func (m *ListNodesRequest) Marshal() (data []byte, err error) {
  2916. size := m.Size()
  2917. data = make([]byte, size)
  2918. n, err := m.MarshalTo(data)
  2919. if err != nil {
  2920. return nil, err
  2921. }
  2922. return data[:n], nil
  2923. }
  2924. func (m *ListNodesRequest) MarshalTo(data []byte) (int, error) {
  2925. var i int
  2926. _ = i
  2927. var l int
  2928. _ = l
  2929. if m.Filters != nil {
  2930. data[i] = 0xa
  2931. i++
  2932. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  2933. n2, err := m.Filters.MarshalTo(data[i:])
  2934. if err != nil {
  2935. return 0, err
  2936. }
  2937. i += n2
  2938. }
  2939. return i, nil
  2940. }
  2941. func (m *ListNodesRequest_Filters) Marshal() (data []byte, err error) {
  2942. size := m.Size()
  2943. data = make([]byte, size)
  2944. n, err := m.MarshalTo(data)
  2945. if err != nil {
  2946. return nil, err
  2947. }
  2948. return data[:n], nil
  2949. }
  2950. func (m *ListNodesRequest_Filters) MarshalTo(data []byte) (int, error) {
  2951. var i int
  2952. _ = i
  2953. var l int
  2954. _ = l
  2955. if len(m.Names) > 0 {
  2956. for _, s := range m.Names {
  2957. data[i] = 0xa
  2958. i++
  2959. l = len(s)
  2960. for l >= 1<<7 {
  2961. data[i] = uint8(uint64(l)&0x7f | 0x80)
  2962. l >>= 7
  2963. i++
  2964. }
  2965. data[i] = uint8(l)
  2966. i++
  2967. i += copy(data[i:], s)
  2968. }
  2969. }
  2970. if len(m.IDPrefixes) > 0 {
  2971. for _, s := range m.IDPrefixes {
  2972. data[i] = 0x12
  2973. i++
  2974. l = len(s)
  2975. for l >= 1<<7 {
  2976. data[i] = uint8(uint64(l)&0x7f | 0x80)
  2977. l >>= 7
  2978. i++
  2979. }
  2980. data[i] = uint8(l)
  2981. i++
  2982. i += copy(data[i:], s)
  2983. }
  2984. }
  2985. if len(m.Labels) > 0 {
  2986. for k, _ := range m.Labels {
  2987. data[i] = 0x1a
  2988. i++
  2989. v := m.Labels[k]
  2990. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  2991. i = encodeVarintControl(data, i, uint64(mapSize))
  2992. data[i] = 0xa
  2993. i++
  2994. i = encodeVarintControl(data, i, uint64(len(k)))
  2995. i += copy(data[i:], k)
  2996. data[i] = 0x12
  2997. i++
  2998. i = encodeVarintControl(data, i, uint64(len(v)))
  2999. i += copy(data[i:], v)
  3000. }
  3001. }
  3002. if len(m.Memberships) > 0 {
  3003. for _, num := range m.Memberships {
  3004. data[i] = 0x20
  3005. i++
  3006. i = encodeVarintControl(data, i, uint64(num))
  3007. }
  3008. }
  3009. if len(m.Roles) > 0 {
  3010. for _, num := range m.Roles {
  3011. data[i] = 0x28
  3012. i++
  3013. i = encodeVarintControl(data, i, uint64(num))
  3014. }
  3015. }
  3016. if len(m.NamePrefixes) > 0 {
  3017. for _, s := range m.NamePrefixes {
  3018. data[i] = 0x32
  3019. i++
  3020. l = len(s)
  3021. for l >= 1<<7 {
  3022. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3023. l >>= 7
  3024. i++
  3025. }
  3026. data[i] = uint8(l)
  3027. i++
  3028. i += copy(data[i:], s)
  3029. }
  3030. }
  3031. return i, nil
  3032. }
  3033. func (m *ListNodesResponse) Marshal() (data []byte, err error) {
  3034. size := m.Size()
  3035. data = make([]byte, size)
  3036. n, err := m.MarshalTo(data)
  3037. if err != nil {
  3038. return nil, err
  3039. }
  3040. return data[:n], nil
  3041. }
  3042. func (m *ListNodesResponse) MarshalTo(data []byte) (int, error) {
  3043. var i int
  3044. _ = i
  3045. var l int
  3046. _ = l
  3047. if len(m.Nodes) > 0 {
  3048. for _, msg := range m.Nodes {
  3049. data[i] = 0xa
  3050. i++
  3051. i = encodeVarintControl(data, i, uint64(msg.Size()))
  3052. n, err := msg.MarshalTo(data[i:])
  3053. if err != nil {
  3054. return 0, err
  3055. }
  3056. i += n
  3057. }
  3058. }
  3059. return i, nil
  3060. }
  3061. func (m *UpdateNodeRequest) Marshal() (data []byte, err error) {
  3062. size := m.Size()
  3063. data = make([]byte, size)
  3064. n, err := m.MarshalTo(data)
  3065. if err != nil {
  3066. return nil, err
  3067. }
  3068. return data[:n], nil
  3069. }
  3070. func (m *UpdateNodeRequest) MarshalTo(data []byte) (int, error) {
  3071. var i int
  3072. _ = i
  3073. var l int
  3074. _ = l
  3075. if len(m.NodeID) > 0 {
  3076. data[i] = 0xa
  3077. i++
  3078. i = encodeVarintControl(data, i, uint64(len(m.NodeID)))
  3079. i += copy(data[i:], m.NodeID)
  3080. }
  3081. if m.NodeVersion != nil {
  3082. data[i] = 0x12
  3083. i++
  3084. i = encodeVarintControl(data, i, uint64(m.NodeVersion.Size()))
  3085. n3, err := m.NodeVersion.MarshalTo(data[i:])
  3086. if err != nil {
  3087. return 0, err
  3088. }
  3089. i += n3
  3090. }
  3091. if m.Spec != nil {
  3092. data[i] = 0x1a
  3093. i++
  3094. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  3095. n4, err := m.Spec.MarshalTo(data[i:])
  3096. if err != nil {
  3097. return 0, err
  3098. }
  3099. i += n4
  3100. }
  3101. return i, nil
  3102. }
  3103. func (m *UpdateNodeResponse) Marshal() (data []byte, err error) {
  3104. size := m.Size()
  3105. data = make([]byte, size)
  3106. n, err := m.MarshalTo(data)
  3107. if err != nil {
  3108. return nil, err
  3109. }
  3110. return data[:n], nil
  3111. }
  3112. func (m *UpdateNodeResponse) MarshalTo(data []byte) (int, error) {
  3113. var i int
  3114. _ = i
  3115. var l int
  3116. _ = l
  3117. if m.Node != nil {
  3118. data[i] = 0xa
  3119. i++
  3120. i = encodeVarintControl(data, i, uint64(m.Node.Size()))
  3121. n5, err := m.Node.MarshalTo(data[i:])
  3122. if err != nil {
  3123. return 0, err
  3124. }
  3125. i += n5
  3126. }
  3127. return i, nil
  3128. }
  3129. func (m *RemoveNodeRequest) Marshal() (data []byte, err error) {
  3130. size := m.Size()
  3131. data = make([]byte, size)
  3132. n, err := m.MarshalTo(data)
  3133. if err != nil {
  3134. return nil, err
  3135. }
  3136. return data[:n], nil
  3137. }
  3138. func (m *RemoveNodeRequest) MarshalTo(data []byte) (int, error) {
  3139. var i int
  3140. _ = i
  3141. var l int
  3142. _ = l
  3143. if len(m.NodeID) > 0 {
  3144. data[i] = 0xa
  3145. i++
  3146. i = encodeVarintControl(data, i, uint64(len(m.NodeID)))
  3147. i += copy(data[i:], m.NodeID)
  3148. }
  3149. if m.Force {
  3150. data[i] = 0x10
  3151. i++
  3152. if m.Force {
  3153. data[i] = 1
  3154. } else {
  3155. data[i] = 0
  3156. }
  3157. i++
  3158. }
  3159. return i, nil
  3160. }
  3161. func (m *RemoveNodeResponse) Marshal() (data []byte, err error) {
  3162. size := m.Size()
  3163. data = make([]byte, size)
  3164. n, err := m.MarshalTo(data)
  3165. if err != nil {
  3166. return nil, err
  3167. }
  3168. return data[:n], nil
  3169. }
  3170. func (m *RemoveNodeResponse) MarshalTo(data []byte) (int, error) {
  3171. var i int
  3172. _ = i
  3173. var l int
  3174. _ = l
  3175. return i, nil
  3176. }
  3177. func (m *GetTaskRequest) Marshal() (data []byte, err error) {
  3178. size := m.Size()
  3179. data = make([]byte, size)
  3180. n, err := m.MarshalTo(data)
  3181. if err != nil {
  3182. return nil, err
  3183. }
  3184. return data[:n], nil
  3185. }
  3186. func (m *GetTaskRequest) MarshalTo(data []byte) (int, error) {
  3187. var i int
  3188. _ = i
  3189. var l int
  3190. _ = l
  3191. if len(m.TaskID) > 0 {
  3192. data[i] = 0xa
  3193. i++
  3194. i = encodeVarintControl(data, i, uint64(len(m.TaskID)))
  3195. i += copy(data[i:], m.TaskID)
  3196. }
  3197. return i, nil
  3198. }
  3199. func (m *GetTaskResponse) Marshal() (data []byte, err error) {
  3200. size := m.Size()
  3201. data = make([]byte, size)
  3202. n, err := m.MarshalTo(data)
  3203. if err != nil {
  3204. return nil, err
  3205. }
  3206. return data[:n], nil
  3207. }
  3208. func (m *GetTaskResponse) MarshalTo(data []byte) (int, error) {
  3209. var i int
  3210. _ = i
  3211. var l int
  3212. _ = l
  3213. if m.Task != nil {
  3214. data[i] = 0xa
  3215. i++
  3216. i = encodeVarintControl(data, i, uint64(m.Task.Size()))
  3217. n6, err := m.Task.MarshalTo(data[i:])
  3218. if err != nil {
  3219. return 0, err
  3220. }
  3221. i += n6
  3222. }
  3223. return i, nil
  3224. }
  3225. func (m *RemoveTaskRequest) Marshal() (data []byte, err error) {
  3226. size := m.Size()
  3227. data = make([]byte, size)
  3228. n, err := m.MarshalTo(data)
  3229. if err != nil {
  3230. return nil, err
  3231. }
  3232. return data[:n], nil
  3233. }
  3234. func (m *RemoveTaskRequest) MarshalTo(data []byte) (int, error) {
  3235. var i int
  3236. _ = i
  3237. var l int
  3238. _ = l
  3239. if len(m.TaskID) > 0 {
  3240. data[i] = 0xa
  3241. i++
  3242. i = encodeVarintControl(data, i, uint64(len(m.TaskID)))
  3243. i += copy(data[i:], m.TaskID)
  3244. }
  3245. return i, nil
  3246. }
  3247. func (m *RemoveTaskResponse) Marshal() (data []byte, err error) {
  3248. size := m.Size()
  3249. data = make([]byte, size)
  3250. n, err := m.MarshalTo(data)
  3251. if err != nil {
  3252. return nil, err
  3253. }
  3254. return data[:n], nil
  3255. }
  3256. func (m *RemoveTaskResponse) MarshalTo(data []byte) (int, error) {
  3257. var i int
  3258. _ = i
  3259. var l int
  3260. _ = l
  3261. return i, nil
  3262. }
  3263. func (m *ListTasksRequest) Marshal() (data []byte, err error) {
  3264. size := m.Size()
  3265. data = make([]byte, size)
  3266. n, err := m.MarshalTo(data)
  3267. if err != nil {
  3268. return nil, err
  3269. }
  3270. return data[:n], nil
  3271. }
  3272. func (m *ListTasksRequest) MarshalTo(data []byte) (int, error) {
  3273. var i int
  3274. _ = i
  3275. var l int
  3276. _ = l
  3277. if m.Filters != nil {
  3278. data[i] = 0xa
  3279. i++
  3280. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  3281. n7, err := m.Filters.MarshalTo(data[i:])
  3282. if err != nil {
  3283. return 0, err
  3284. }
  3285. i += n7
  3286. }
  3287. return i, nil
  3288. }
  3289. func (m *ListTasksRequest_Filters) Marshal() (data []byte, err error) {
  3290. size := m.Size()
  3291. data = make([]byte, size)
  3292. n, err := m.MarshalTo(data)
  3293. if err != nil {
  3294. return nil, err
  3295. }
  3296. return data[:n], nil
  3297. }
  3298. func (m *ListTasksRequest_Filters) MarshalTo(data []byte) (int, error) {
  3299. var i int
  3300. _ = i
  3301. var l int
  3302. _ = l
  3303. if len(m.Names) > 0 {
  3304. for _, s := range m.Names {
  3305. data[i] = 0xa
  3306. i++
  3307. l = len(s)
  3308. for l >= 1<<7 {
  3309. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3310. l >>= 7
  3311. i++
  3312. }
  3313. data[i] = uint8(l)
  3314. i++
  3315. i += copy(data[i:], s)
  3316. }
  3317. }
  3318. if len(m.IDPrefixes) > 0 {
  3319. for _, s := range m.IDPrefixes {
  3320. data[i] = 0x12
  3321. i++
  3322. l = len(s)
  3323. for l >= 1<<7 {
  3324. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3325. l >>= 7
  3326. i++
  3327. }
  3328. data[i] = uint8(l)
  3329. i++
  3330. i += copy(data[i:], s)
  3331. }
  3332. }
  3333. if len(m.Labels) > 0 {
  3334. for k, _ := range m.Labels {
  3335. data[i] = 0x1a
  3336. i++
  3337. v := m.Labels[k]
  3338. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  3339. i = encodeVarintControl(data, i, uint64(mapSize))
  3340. data[i] = 0xa
  3341. i++
  3342. i = encodeVarintControl(data, i, uint64(len(k)))
  3343. i += copy(data[i:], k)
  3344. data[i] = 0x12
  3345. i++
  3346. i = encodeVarintControl(data, i, uint64(len(v)))
  3347. i += copy(data[i:], v)
  3348. }
  3349. }
  3350. if len(m.ServiceIDs) > 0 {
  3351. for _, s := range m.ServiceIDs {
  3352. data[i] = 0x22
  3353. i++
  3354. l = len(s)
  3355. for l >= 1<<7 {
  3356. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3357. l >>= 7
  3358. i++
  3359. }
  3360. data[i] = uint8(l)
  3361. i++
  3362. i += copy(data[i:], s)
  3363. }
  3364. }
  3365. if len(m.NodeIDs) > 0 {
  3366. for _, s := range m.NodeIDs {
  3367. data[i] = 0x2a
  3368. i++
  3369. l = len(s)
  3370. for l >= 1<<7 {
  3371. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3372. l >>= 7
  3373. i++
  3374. }
  3375. data[i] = uint8(l)
  3376. i++
  3377. i += copy(data[i:], s)
  3378. }
  3379. }
  3380. if len(m.DesiredStates) > 0 {
  3381. for _, num := range m.DesiredStates {
  3382. data[i] = 0x30
  3383. i++
  3384. i = encodeVarintControl(data, i, uint64(num))
  3385. }
  3386. }
  3387. if len(m.NamePrefixes) > 0 {
  3388. for _, s := range m.NamePrefixes {
  3389. data[i] = 0x3a
  3390. i++
  3391. l = len(s)
  3392. for l >= 1<<7 {
  3393. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3394. l >>= 7
  3395. i++
  3396. }
  3397. data[i] = uint8(l)
  3398. i++
  3399. i += copy(data[i:], s)
  3400. }
  3401. }
  3402. return i, nil
  3403. }
  3404. func (m *ListTasksResponse) Marshal() (data []byte, err error) {
  3405. size := m.Size()
  3406. data = make([]byte, size)
  3407. n, err := m.MarshalTo(data)
  3408. if err != nil {
  3409. return nil, err
  3410. }
  3411. return data[:n], nil
  3412. }
  3413. func (m *ListTasksResponse) MarshalTo(data []byte) (int, error) {
  3414. var i int
  3415. _ = i
  3416. var l int
  3417. _ = l
  3418. if len(m.Tasks) > 0 {
  3419. for _, msg := range m.Tasks {
  3420. data[i] = 0xa
  3421. i++
  3422. i = encodeVarintControl(data, i, uint64(msg.Size()))
  3423. n, err := msg.MarshalTo(data[i:])
  3424. if err != nil {
  3425. return 0, err
  3426. }
  3427. i += n
  3428. }
  3429. }
  3430. return i, nil
  3431. }
  3432. func (m *CreateServiceRequest) Marshal() (data []byte, err error) {
  3433. size := m.Size()
  3434. data = make([]byte, size)
  3435. n, err := m.MarshalTo(data)
  3436. if err != nil {
  3437. return nil, err
  3438. }
  3439. return data[:n], nil
  3440. }
  3441. func (m *CreateServiceRequest) MarshalTo(data []byte) (int, error) {
  3442. var i int
  3443. _ = i
  3444. var l int
  3445. _ = l
  3446. if m.Spec != nil {
  3447. data[i] = 0xa
  3448. i++
  3449. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  3450. n8, err := m.Spec.MarshalTo(data[i:])
  3451. if err != nil {
  3452. return 0, err
  3453. }
  3454. i += n8
  3455. }
  3456. return i, nil
  3457. }
  3458. func (m *CreateServiceResponse) Marshal() (data []byte, err error) {
  3459. size := m.Size()
  3460. data = make([]byte, size)
  3461. n, err := m.MarshalTo(data)
  3462. if err != nil {
  3463. return nil, err
  3464. }
  3465. return data[:n], nil
  3466. }
  3467. func (m *CreateServiceResponse) MarshalTo(data []byte) (int, error) {
  3468. var i int
  3469. _ = i
  3470. var l int
  3471. _ = l
  3472. if m.Service != nil {
  3473. data[i] = 0xa
  3474. i++
  3475. i = encodeVarintControl(data, i, uint64(m.Service.Size()))
  3476. n9, err := m.Service.MarshalTo(data[i:])
  3477. if err != nil {
  3478. return 0, err
  3479. }
  3480. i += n9
  3481. }
  3482. return i, nil
  3483. }
  3484. func (m *GetServiceRequest) Marshal() (data []byte, err error) {
  3485. size := m.Size()
  3486. data = make([]byte, size)
  3487. n, err := m.MarshalTo(data)
  3488. if err != nil {
  3489. return nil, err
  3490. }
  3491. return data[:n], nil
  3492. }
  3493. func (m *GetServiceRequest) MarshalTo(data []byte) (int, error) {
  3494. var i int
  3495. _ = i
  3496. var l int
  3497. _ = l
  3498. if len(m.ServiceID) > 0 {
  3499. data[i] = 0xa
  3500. i++
  3501. i = encodeVarintControl(data, i, uint64(len(m.ServiceID)))
  3502. i += copy(data[i:], m.ServiceID)
  3503. }
  3504. return i, nil
  3505. }
  3506. func (m *GetServiceResponse) Marshal() (data []byte, err error) {
  3507. size := m.Size()
  3508. data = make([]byte, size)
  3509. n, err := m.MarshalTo(data)
  3510. if err != nil {
  3511. return nil, err
  3512. }
  3513. return data[:n], nil
  3514. }
  3515. func (m *GetServiceResponse) MarshalTo(data []byte) (int, error) {
  3516. var i int
  3517. _ = i
  3518. var l int
  3519. _ = l
  3520. if m.Service != nil {
  3521. data[i] = 0xa
  3522. i++
  3523. i = encodeVarintControl(data, i, uint64(m.Service.Size()))
  3524. n10, err := m.Service.MarshalTo(data[i:])
  3525. if err != nil {
  3526. return 0, err
  3527. }
  3528. i += n10
  3529. }
  3530. return i, nil
  3531. }
  3532. func (m *UpdateServiceRequest) Marshal() (data []byte, err error) {
  3533. size := m.Size()
  3534. data = make([]byte, size)
  3535. n, err := m.MarshalTo(data)
  3536. if err != nil {
  3537. return nil, err
  3538. }
  3539. return data[:n], nil
  3540. }
  3541. func (m *UpdateServiceRequest) MarshalTo(data []byte) (int, error) {
  3542. var i int
  3543. _ = i
  3544. var l int
  3545. _ = l
  3546. if len(m.ServiceID) > 0 {
  3547. data[i] = 0xa
  3548. i++
  3549. i = encodeVarintControl(data, i, uint64(len(m.ServiceID)))
  3550. i += copy(data[i:], m.ServiceID)
  3551. }
  3552. if m.ServiceVersion != nil {
  3553. data[i] = 0x12
  3554. i++
  3555. i = encodeVarintControl(data, i, uint64(m.ServiceVersion.Size()))
  3556. n11, err := m.ServiceVersion.MarshalTo(data[i:])
  3557. if err != nil {
  3558. return 0, err
  3559. }
  3560. i += n11
  3561. }
  3562. if m.Spec != nil {
  3563. data[i] = 0x1a
  3564. i++
  3565. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  3566. n12, err := m.Spec.MarshalTo(data[i:])
  3567. if err != nil {
  3568. return 0, err
  3569. }
  3570. i += n12
  3571. }
  3572. return i, nil
  3573. }
  3574. func (m *UpdateServiceResponse) Marshal() (data []byte, err error) {
  3575. size := m.Size()
  3576. data = make([]byte, size)
  3577. n, err := m.MarshalTo(data)
  3578. if err != nil {
  3579. return nil, err
  3580. }
  3581. return data[:n], nil
  3582. }
  3583. func (m *UpdateServiceResponse) MarshalTo(data []byte) (int, error) {
  3584. var i int
  3585. _ = i
  3586. var l int
  3587. _ = l
  3588. if m.Service != nil {
  3589. data[i] = 0xa
  3590. i++
  3591. i = encodeVarintControl(data, i, uint64(m.Service.Size()))
  3592. n13, err := m.Service.MarshalTo(data[i:])
  3593. if err != nil {
  3594. return 0, err
  3595. }
  3596. i += n13
  3597. }
  3598. return i, nil
  3599. }
  3600. func (m *RemoveServiceRequest) Marshal() (data []byte, err error) {
  3601. size := m.Size()
  3602. data = make([]byte, size)
  3603. n, err := m.MarshalTo(data)
  3604. if err != nil {
  3605. return nil, err
  3606. }
  3607. return data[:n], nil
  3608. }
  3609. func (m *RemoveServiceRequest) MarshalTo(data []byte) (int, error) {
  3610. var i int
  3611. _ = i
  3612. var l int
  3613. _ = l
  3614. if len(m.ServiceID) > 0 {
  3615. data[i] = 0xa
  3616. i++
  3617. i = encodeVarintControl(data, i, uint64(len(m.ServiceID)))
  3618. i += copy(data[i:], m.ServiceID)
  3619. }
  3620. return i, nil
  3621. }
  3622. func (m *RemoveServiceResponse) Marshal() (data []byte, err error) {
  3623. size := m.Size()
  3624. data = make([]byte, size)
  3625. n, err := m.MarshalTo(data)
  3626. if err != nil {
  3627. return nil, err
  3628. }
  3629. return data[:n], nil
  3630. }
  3631. func (m *RemoveServiceResponse) MarshalTo(data []byte) (int, error) {
  3632. var i int
  3633. _ = i
  3634. var l int
  3635. _ = l
  3636. return i, nil
  3637. }
  3638. func (m *ListServicesRequest) Marshal() (data []byte, err error) {
  3639. size := m.Size()
  3640. data = make([]byte, size)
  3641. n, err := m.MarshalTo(data)
  3642. if err != nil {
  3643. return nil, err
  3644. }
  3645. return data[:n], nil
  3646. }
  3647. func (m *ListServicesRequest) MarshalTo(data []byte) (int, error) {
  3648. var i int
  3649. _ = i
  3650. var l int
  3651. _ = l
  3652. if m.Filters != nil {
  3653. data[i] = 0xa
  3654. i++
  3655. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  3656. n14, err := m.Filters.MarshalTo(data[i:])
  3657. if err != nil {
  3658. return 0, err
  3659. }
  3660. i += n14
  3661. }
  3662. return i, nil
  3663. }
  3664. func (m *ListServicesRequest_Filters) Marshal() (data []byte, err error) {
  3665. size := m.Size()
  3666. data = make([]byte, size)
  3667. n, err := m.MarshalTo(data)
  3668. if err != nil {
  3669. return nil, err
  3670. }
  3671. return data[:n], nil
  3672. }
  3673. func (m *ListServicesRequest_Filters) MarshalTo(data []byte) (int, error) {
  3674. var i int
  3675. _ = i
  3676. var l int
  3677. _ = l
  3678. if len(m.Names) > 0 {
  3679. for _, s := range m.Names {
  3680. data[i] = 0xa
  3681. i++
  3682. l = len(s)
  3683. for l >= 1<<7 {
  3684. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3685. l >>= 7
  3686. i++
  3687. }
  3688. data[i] = uint8(l)
  3689. i++
  3690. i += copy(data[i:], s)
  3691. }
  3692. }
  3693. if len(m.IDPrefixes) > 0 {
  3694. for _, s := range m.IDPrefixes {
  3695. data[i] = 0x12
  3696. i++
  3697. l = len(s)
  3698. for l >= 1<<7 {
  3699. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3700. l >>= 7
  3701. i++
  3702. }
  3703. data[i] = uint8(l)
  3704. i++
  3705. i += copy(data[i:], s)
  3706. }
  3707. }
  3708. if len(m.Labels) > 0 {
  3709. for k, _ := range m.Labels {
  3710. data[i] = 0x1a
  3711. i++
  3712. v := m.Labels[k]
  3713. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  3714. i = encodeVarintControl(data, i, uint64(mapSize))
  3715. data[i] = 0xa
  3716. i++
  3717. i = encodeVarintControl(data, i, uint64(len(k)))
  3718. i += copy(data[i:], k)
  3719. data[i] = 0x12
  3720. i++
  3721. i = encodeVarintControl(data, i, uint64(len(v)))
  3722. i += copy(data[i:], v)
  3723. }
  3724. }
  3725. if len(m.NamePrefixes) > 0 {
  3726. for _, s := range m.NamePrefixes {
  3727. data[i] = 0x22
  3728. i++
  3729. l = len(s)
  3730. for l >= 1<<7 {
  3731. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3732. l >>= 7
  3733. i++
  3734. }
  3735. data[i] = uint8(l)
  3736. i++
  3737. i += copy(data[i:], s)
  3738. }
  3739. }
  3740. return i, nil
  3741. }
  3742. func (m *ListServicesResponse) Marshal() (data []byte, err error) {
  3743. size := m.Size()
  3744. data = make([]byte, size)
  3745. n, err := m.MarshalTo(data)
  3746. if err != nil {
  3747. return nil, err
  3748. }
  3749. return data[:n], nil
  3750. }
  3751. func (m *ListServicesResponse) MarshalTo(data []byte) (int, error) {
  3752. var i int
  3753. _ = i
  3754. var l int
  3755. _ = l
  3756. if len(m.Services) > 0 {
  3757. for _, msg := range m.Services {
  3758. data[i] = 0xa
  3759. i++
  3760. i = encodeVarintControl(data, i, uint64(msg.Size()))
  3761. n, err := msg.MarshalTo(data[i:])
  3762. if err != nil {
  3763. return 0, err
  3764. }
  3765. i += n
  3766. }
  3767. }
  3768. return i, nil
  3769. }
  3770. func (m *CreateNetworkRequest) Marshal() (data []byte, err error) {
  3771. size := m.Size()
  3772. data = make([]byte, size)
  3773. n, err := m.MarshalTo(data)
  3774. if err != nil {
  3775. return nil, err
  3776. }
  3777. return data[:n], nil
  3778. }
  3779. func (m *CreateNetworkRequest) MarshalTo(data []byte) (int, error) {
  3780. var i int
  3781. _ = i
  3782. var l int
  3783. _ = l
  3784. if m.Spec != nil {
  3785. data[i] = 0xa
  3786. i++
  3787. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  3788. n15, err := m.Spec.MarshalTo(data[i:])
  3789. if err != nil {
  3790. return 0, err
  3791. }
  3792. i += n15
  3793. }
  3794. return i, nil
  3795. }
  3796. func (m *CreateNetworkResponse) Marshal() (data []byte, err error) {
  3797. size := m.Size()
  3798. data = make([]byte, size)
  3799. n, err := m.MarshalTo(data)
  3800. if err != nil {
  3801. return nil, err
  3802. }
  3803. return data[:n], nil
  3804. }
  3805. func (m *CreateNetworkResponse) MarshalTo(data []byte) (int, error) {
  3806. var i int
  3807. _ = i
  3808. var l int
  3809. _ = l
  3810. if m.Network != nil {
  3811. data[i] = 0xa
  3812. i++
  3813. i = encodeVarintControl(data, i, uint64(m.Network.Size()))
  3814. n16, err := m.Network.MarshalTo(data[i:])
  3815. if err != nil {
  3816. return 0, err
  3817. }
  3818. i += n16
  3819. }
  3820. return i, nil
  3821. }
  3822. func (m *GetNetworkRequest) Marshal() (data []byte, err error) {
  3823. size := m.Size()
  3824. data = make([]byte, size)
  3825. n, err := m.MarshalTo(data)
  3826. if err != nil {
  3827. return nil, err
  3828. }
  3829. return data[:n], nil
  3830. }
  3831. func (m *GetNetworkRequest) MarshalTo(data []byte) (int, error) {
  3832. var i int
  3833. _ = i
  3834. var l int
  3835. _ = l
  3836. if len(m.Name) > 0 {
  3837. data[i] = 0xa
  3838. i++
  3839. i = encodeVarintControl(data, i, uint64(len(m.Name)))
  3840. i += copy(data[i:], m.Name)
  3841. }
  3842. if len(m.NetworkID) > 0 {
  3843. data[i] = 0x12
  3844. i++
  3845. i = encodeVarintControl(data, i, uint64(len(m.NetworkID)))
  3846. i += copy(data[i:], m.NetworkID)
  3847. }
  3848. return i, nil
  3849. }
  3850. func (m *GetNetworkResponse) Marshal() (data []byte, err error) {
  3851. size := m.Size()
  3852. data = make([]byte, size)
  3853. n, err := m.MarshalTo(data)
  3854. if err != nil {
  3855. return nil, err
  3856. }
  3857. return data[:n], nil
  3858. }
  3859. func (m *GetNetworkResponse) MarshalTo(data []byte) (int, error) {
  3860. var i int
  3861. _ = i
  3862. var l int
  3863. _ = l
  3864. if m.Network != nil {
  3865. data[i] = 0xa
  3866. i++
  3867. i = encodeVarintControl(data, i, uint64(m.Network.Size()))
  3868. n17, err := m.Network.MarshalTo(data[i:])
  3869. if err != nil {
  3870. return 0, err
  3871. }
  3872. i += n17
  3873. }
  3874. return i, nil
  3875. }
  3876. func (m *RemoveNetworkRequest) Marshal() (data []byte, err error) {
  3877. size := m.Size()
  3878. data = make([]byte, size)
  3879. n, err := m.MarshalTo(data)
  3880. if err != nil {
  3881. return nil, err
  3882. }
  3883. return data[:n], nil
  3884. }
  3885. func (m *RemoveNetworkRequest) MarshalTo(data []byte) (int, error) {
  3886. var i int
  3887. _ = i
  3888. var l int
  3889. _ = l
  3890. if len(m.Name) > 0 {
  3891. data[i] = 0xa
  3892. i++
  3893. i = encodeVarintControl(data, i, uint64(len(m.Name)))
  3894. i += copy(data[i:], m.Name)
  3895. }
  3896. if len(m.NetworkID) > 0 {
  3897. data[i] = 0x12
  3898. i++
  3899. i = encodeVarintControl(data, i, uint64(len(m.NetworkID)))
  3900. i += copy(data[i:], m.NetworkID)
  3901. }
  3902. return i, nil
  3903. }
  3904. func (m *RemoveNetworkResponse) Marshal() (data []byte, err error) {
  3905. size := m.Size()
  3906. data = make([]byte, size)
  3907. n, err := m.MarshalTo(data)
  3908. if err != nil {
  3909. return nil, err
  3910. }
  3911. return data[:n], nil
  3912. }
  3913. func (m *RemoveNetworkResponse) MarshalTo(data []byte) (int, error) {
  3914. var i int
  3915. _ = i
  3916. var l int
  3917. _ = l
  3918. return i, nil
  3919. }
  3920. func (m *ListNetworksRequest) Marshal() (data []byte, err error) {
  3921. size := m.Size()
  3922. data = make([]byte, size)
  3923. n, err := m.MarshalTo(data)
  3924. if err != nil {
  3925. return nil, err
  3926. }
  3927. return data[:n], nil
  3928. }
  3929. func (m *ListNetworksRequest) MarshalTo(data []byte) (int, error) {
  3930. var i int
  3931. _ = i
  3932. var l int
  3933. _ = l
  3934. if m.Filters != nil {
  3935. data[i] = 0xa
  3936. i++
  3937. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  3938. n18, err := m.Filters.MarshalTo(data[i:])
  3939. if err != nil {
  3940. return 0, err
  3941. }
  3942. i += n18
  3943. }
  3944. return i, nil
  3945. }
  3946. func (m *ListNetworksRequest_Filters) Marshal() (data []byte, err error) {
  3947. size := m.Size()
  3948. data = make([]byte, size)
  3949. n, err := m.MarshalTo(data)
  3950. if err != nil {
  3951. return nil, err
  3952. }
  3953. return data[:n], nil
  3954. }
  3955. func (m *ListNetworksRequest_Filters) MarshalTo(data []byte) (int, error) {
  3956. var i int
  3957. _ = i
  3958. var l int
  3959. _ = l
  3960. if len(m.Names) > 0 {
  3961. for _, s := range m.Names {
  3962. data[i] = 0xa
  3963. i++
  3964. l = len(s)
  3965. for l >= 1<<7 {
  3966. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3967. l >>= 7
  3968. i++
  3969. }
  3970. data[i] = uint8(l)
  3971. i++
  3972. i += copy(data[i:], s)
  3973. }
  3974. }
  3975. if len(m.IDPrefixes) > 0 {
  3976. for _, s := range m.IDPrefixes {
  3977. data[i] = 0x12
  3978. i++
  3979. l = len(s)
  3980. for l >= 1<<7 {
  3981. data[i] = uint8(uint64(l)&0x7f | 0x80)
  3982. l >>= 7
  3983. i++
  3984. }
  3985. data[i] = uint8(l)
  3986. i++
  3987. i += copy(data[i:], s)
  3988. }
  3989. }
  3990. if len(m.Labels) > 0 {
  3991. for k, _ := range m.Labels {
  3992. data[i] = 0x1a
  3993. i++
  3994. v := m.Labels[k]
  3995. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  3996. i = encodeVarintControl(data, i, uint64(mapSize))
  3997. data[i] = 0xa
  3998. i++
  3999. i = encodeVarintControl(data, i, uint64(len(k)))
  4000. i += copy(data[i:], k)
  4001. data[i] = 0x12
  4002. i++
  4003. i = encodeVarintControl(data, i, uint64(len(v)))
  4004. i += copy(data[i:], v)
  4005. }
  4006. }
  4007. if len(m.NamePrefixes) > 0 {
  4008. for _, s := range m.NamePrefixes {
  4009. data[i] = 0x22
  4010. i++
  4011. l = len(s)
  4012. for l >= 1<<7 {
  4013. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4014. l >>= 7
  4015. i++
  4016. }
  4017. data[i] = uint8(l)
  4018. i++
  4019. i += copy(data[i:], s)
  4020. }
  4021. }
  4022. return i, nil
  4023. }
  4024. func (m *ListNetworksResponse) Marshal() (data []byte, err error) {
  4025. size := m.Size()
  4026. data = make([]byte, size)
  4027. n, err := m.MarshalTo(data)
  4028. if err != nil {
  4029. return nil, err
  4030. }
  4031. return data[:n], nil
  4032. }
  4033. func (m *ListNetworksResponse) MarshalTo(data []byte) (int, error) {
  4034. var i int
  4035. _ = i
  4036. var l int
  4037. _ = l
  4038. if len(m.Networks) > 0 {
  4039. for _, msg := range m.Networks {
  4040. data[i] = 0xa
  4041. i++
  4042. i = encodeVarintControl(data, i, uint64(msg.Size()))
  4043. n, err := msg.MarshalTo(data[i:])
  4044. if err != nil {
  4045. return 0, err
  4046. }
  4047. i += n
  4048. }
  4049. }
  4050. return i, nil
  4051. }
  4052. func (m *GetClusterRequest) Marshal() (data []byte, err error) {
  4053. size := m.Size()
  4054. data = make([]byte, size)
  4055. n, err := m.MarshalTo(data)
  4056. if err != nil {
  4057. return nil, err
  4058. }
  4059. return data[:n], nil
  4060. }
  4061. func (m *GetClusterRequest) MarshalTo(data []byte) (int, error) {
  4062. var i int
  4063. _ = i
  4064. var l int
  4065. _ = l
  4066. if len(m.ClusterID) > 0 {
  4067. data[i] = 0xa
  4068. i++
  4069. i = encodeVarintControl(data, i, uint64(len(m.ClusterID)))
  4070. i += copy(data[i:], m.ClusterID)
  4071. }
  4072. return i, nil
  4073. }
  4074. func (m *GetClusterResponse) Marshal() (data []byte, err error) {
  4075. size := m.Size()
  4076. data = make([]byte, size)
  4077. n, err := m.MarshalTo(data)
  4078. if err != nil {
  4079. return nil, err
  4080. }
  4081. return data[:n], nil
  4082. }
  4083. func (m *GetClusterResponse) MarshalTo(data []byte) (int, error) {
  4084. var i int
  4085. _ = i
  4086. var l int
  4087. _ = l
  4088. if m.Cluster != nil {
  4089. data[i] = 0xa
  4090. i++
  4091. i = encodeVarintControl(data, i, uint64(m.Cluster.Size()))
  4092. n19, err := m.Cluster.MarshalTo(data[i:])
  4093. if err != nil {
  4094. return 0, err
  4095. }
  4096. i += n19
  4097. }
  4098. return i, nil
  4099. }
  4100. func (m *ListClustersRequest) Marshal() (data []byte, err error) {
  4101. size := m.Size()
  4102. data = make([]byte, size)
  4103. n, err := m.MarshalTo(data)
  4104. if err != nil {
  4105. return nil, err
  4106. }
  4107. return data[:n], nil
  4108. }
  4109. func (m *ListClustersRequest) MarshalTo(data []byte) (int, error) {
  4110. var i int
  4111. _ = i
  4112. var l int
  4113. _ = l
  4114. if m.Filters != nil {
  4115. data[i] = 0xa
  4116. i++
  4117. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  4118. n20, err := m.Filters.MarshalTo(data[i:])
  4119. if err != nil {
  4120. return 0, err
  4121. }
  4122. i += n20
  4123. }
  4124. return i, nil
  4125. }
  4126. func (m *ListClustersRequest_Filters) Marshal() (data []byte, err error) {
  4127. size := m.Size()
  4128. data = make([]byte, size)
  4129. n, err := m.MarshalTo(data)
  4130. if err != nil {
  4131. return nil, err
  4132. }
  4133. return data[:n], nil
  4134. }
  4135. func (m *ListClustersRequest_Filters) MarshalTo(data []byte) (int, error) {
  4136. var i int
  4137. _ = i
  4138. var l int
  4139. _ = l
  4140. if len(m.Names) > 0 {
  4141. for _, s := range m.Names {
  4142. data[i] = 0xa
  4143. i++
  4144. l = len(s)
  4145. for l >= 1<<7 {
  4146. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4147. l >>= 7
  4148. i++
  4149. }
  4150. data[i] = uint8(l)
  4151. i++
  4152. i += copy(data[i:], s)
  4153. }
  4154. }
  4155. if len(m.IDPrefixes) > 0 {
  4156. for _, s := range m.IDPrefixes {
  4157. data[i] = 0x12
  4158. i++
  4159. l = len(s)
  4160. for l >= 1<<7 {
  4161. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4162. l >>= 7
  4163. i++
  4164. }
  4165. data[i] = uint8(l)
  4166. i++
  4167. i += copy(data[i:], s)
  4168. }
  4169. }
  4170. if len(m.Labels) > 0 {
  4171. for k, _ := range m.Labels {
  4172. data[i] = 0x1a
  4173. i++
  4174. v := m.Labels[k]
  4175. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  4176. i = encodeVarintControl(data, i, uint64(mapSize))
  4177. data[i] = 0xa
  4178. i++
  4179. i = encodeVarintControl(data, i, uint64(len(k)))
  4180. i += copy(data[i:], k)
  4181. data[i] = 0x12
  4182. i++
  4183. i = encodeVarintControl(data, i, uint64(len(v)))
  4184. i += copy(data[i:], v)
  4185. }
  4186. }
  4187. if len(m.NamePrefixes) > 0 {
  4188. for _, s := range m.NamePrefixes {
  4189. data[i] = 0x22
  4190. i++
  4191. l = len(s)
  4192. for l >= 1<<7 {
  4193. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4194. l >>= 7
  4195. i++
  4196. }
  4197. data[i] = uint8(l)
  4198. i++
  4199. i += copy(data[i:], s)
  4200. }
  4201. }
  4202. return i, nil
  4203. }
  4204. func (m *ListClustersResponse) Marshal() (data []byte, err error) {
  4205. size := m.Size()
  4206. data = make([]byte, size)
  4207. n, err := m.MarshalTo(data)
  4208. if err != nil {
  4209. return nil, err
  4210. }
  4211. return data[:n], nil
  4212. }
  4213. func (m *ListClustersResponse) MarshalTo(data []byte) (int, error) {
  4214. var i int
  4215. _ = i
  4216. var l int
  4217. _ = l
  4218. if len(m.Clusters) > 0 {
  4219. for _, msg := range m.Clusters {
  4220. data[i] = 0xa
  4221. i++
  4222. i = encodeVarintControl(data, i, uint64(msg.Size()))
  4223. n, err := msg.MarshalTo(data[i:])
  4224. if err != nil {
  4225. return 0, err
  4226. }
  4227. i += n
  4228. }
  4229. }
  4230. return i, nil
  4231. }
  4232. func (m *KeyRotation) Marshal() (data []byte, err error) {
  4233. size := m.Size()
  4234. data = make([]byte, size)
  4235. n, err := m.MarshalTo(data)
  4236. if err != nil {
  4237. return nil, err
  4238. }
  4239. return data[:n], nil
  4240. }
  4241. func (m *KeyRotation) MarshalTo(data []byte) (int, error) {
  4242. var i int
  4243. _ = i
  4244. var l int
  4245. _ = l
  4246. if m.WorkerJoinToken {
  4247. data[i] = 0x8
  4248. i++
  4249. if m.WorkerJoinToken {
  4250. data[i] = 1
  4251. } else {
  4252. data[i] = 0
  4253. }
  4254. i++
  4255. }
  4256. if m.ManagerJoinToken {
  4257. data[i] = 0x10
  4258. i++
  4259. if m.ManagerJoinToken {
  4260. data[i] = 1
  4261. } else {
  4262. data[i] = 0
  4263. }
  4264. i++
  4265. }
  4266. if m.ManagerUnlockKey {
  4267. data[i] = 0x18
  4268. i++
  4269. if m.ManagerUnlockKey {
  4270. data[i] = 1
  4271. } else {
  4272. data[i] = 0
  4273. }
  4274. i++
  4275. }
  4276. return i, nil
  4277. }
  4278. func (m *UpdateClusterRequest) Marshal() (data []byte, err error) {
  4279. size := m.Size()
  4280. data = make([]byte, size)
  4281. n, err := m.MarshalTo(data)
  4282. if err != nil {
  4283. return nil, err
  4284. }
  4285. return data[:n], nil
  4286. }
  4287. func (m *UpdateClusterRequest) MarshalTo(data []byte) (int, error) {
  4288. var i int
  4289. _ = i
  4290. var l int
  4291. _ = l
  4292. if len(m.ClusterID) > 0 {
  4293. data[i] = 0xa
  4294. i++
  4295. i = encodeVarintControl(data, i, uint64(len(m.ClusterID)))
  4296. i += copy(data[i:], m.ClusterID)
  4297. }
  4298. if m.ClusterVersion != nil {
  4299. data[i] = 0x12
  4300. i++
  4301. i = encodeVarintControl(data, i, uint64(m.ClusterVersion.Size()))
  4302. n21, err := m.ClusterVersion.MarshalTo(data[i:])
  4303. if err != nil {
  4304. return 0, err
  4305. }
  4306. i += n21
  4307. }
  4308. if m.Spec != nil {
  4309. data[i] = 0x1a
  4310. i++
  4311. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  4312. n22, err := m.Spec.MarshalTo(data[i:])
  4313. if err != nil {
  4314. return 0, err
  4315. }
  4316. i += n22
  4317. }
  4318. data[i] = 0x22
  4319. i++
  4320. i = encodeVarintControl(data, i, uint64(m.Rotation.Size()))
  4321. n23, err := m.Rotation.MarshalTo(data[i:])
  4322. if err != nil {
  4323. return 0, err
  4324. }
  4325. i += n23
  4326. return i, nil
  4327. }
  4328. func (m *UpdateClusterResponse) Marshal() (data []byte, err error) {
  4329. size := m.Size()
  4330. data = make([]byte, size)
  4331. n, err := m.MarshalTo(data)
  4332. if err != nil {
  4333. return nil, err
  4334. }
  4335. return data[:n], nil
  4336. }
  4337. func (m *UpdateClusterResponse) MarshalTo(data []byte) (int, error) {
  4338. var i int
  4339. _ = i
  4340. var l int
  4341. _ = l
  4342. if m.Cluster != nil {
  4343. data[i] = 0xa
  4344. i++
  4345. i = encodeVarintControl(data, i, uint64(m.Cluster.Size()))
  4346. n24, err := m.Cluster.MarshalTo(data[i:])
  4347. if err != nil {
  4348. return 0, err
  4349. }
  4350. i += n24
  4351. }
  4352. return i, nil
  4353. }
  4354. func (m *GetSecretRequest) Marshal() (data []byte, err error) {
  4355. size := m.Size()
  4356. data = make([]byte, size)
  4357. n, err := m.MarshalTo(data)
  4358. if err != nil {
  4359. return nil, err
  4360. }
  4361. return data[:n], nil
  4362. }
  4363. func (m *GetSecretRequest) MarshalTo(data []byte) (int, error) {
  4364. var i int
  4365. _ = i
  4366. var l int
  4367. _ = l
  4368. if len(m.SecretID) > 0 {
  4369. data[i] = 0xa
  4370. i++
  4371. i = encodeVarintControl(data, i, uint64(len(m.SecretID)))
  4372. i += copy(data[i:], m.SecretID)
  4373. }
  4374. return i, nil
  4375. }
  4376. func (m *GetSecretResponse) Marshal() (data []byte, err error) {
  4377. size := m.Size()
  4378. data = make([]byte, size)
  4379. n, err := m.MarshalTo(data)
  4380. if err != nil {
  4381. return nil, err
  4382. }
  4383. return data[:n], nil
  4384. }
  4385. func (m *GetSecretResponse) MarshalTo(data []byte) (int, error) {
  4386. var i int
  4387. _ = i
  4388. var l int
  4389. _ = l
  4390. if m.Secret != nil {
  4391. data[i] = 0xa
  4392. i++
  4393. i = encodeVarintControl(data, i, uint64(m.Secret.Size()))
  4394. n25, err := m.Secret.MarshalTo(data[i:])
  4395. if err != nil {
  4396. return 0, err
  4397. }
  4398. i += n25
  4399. }
  4400. return i, nil
  4401. }
  4402. func (m *UpdateSecretRequest) Marshal() (data []byte, err error) {
  4403. size := m.Size()
  4404. data = make([]byte, size)
  4405. n, err := m.MarshalTo(data)
  4406. if err != nil {
  4407. return nil, err
  4408. }
  4409. return data[:n], nil
  4410. }
  4411. func (m *UpdateSecretRequest) MarshalTo(data []byte) (int, error) {
  4412. var i int
  4413. _ = i
  4414. var l int
  4415. _ = l
  4416. if len(m.SecretID) > 0 {
  4417. data[i] = 0xa
  4418. i++
  4419. i = encodeVarintControl(data, i, uint64(len(m.SecretID)))
  4420. i += copy(data[i:], m.SecretID)
  4421. }
  4422. if m.SecretVersion != nil {
  4423. data[i] = 0x12
  4424. i++
  4425. i = encodeVarintControl(data, i, uint64(m.SecretVersion.Size()))
  4426. n26, err := m.SecretVersion.MarshalTo(data[i:])
  4427. if err != nil {
  4428. return 0, err
  4429. }
  4430. i += n26
  4431. }
  4432. if m.Spec != nil {
  4433. data[i] = 0x1a
  4434. i++
  4435. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  4436. n27, err := m.Spec.MarshalTo(data[i:])
  4437. if err != nil {
  4438. return 0, err
  4439. }
  4440. i += n27
  4441. }
  4442. return i, nil
  4443. }
  4444. func (m *UpdateSecretResponse) Marshal() (data []byte, err error) {
  4445. size := m.Size()
  4446. data = make([]byte, size)
  4447. n, err := m.MarshalTo(data)
  4448. if err != nil {
  4449. return nil, err
  4450. }
  4451. return data[:n], nil
  4452. }
  4453. func (m *UpdateSecretResponse) MarshalTo(data []byte) (int, error) {
  4454. var i int
  4455. _ = i
  4456. var l int
  4457. _ = l
  4458. if m.Secret != nil {
  4459. data[i] = 0xa
  4460. i++
  4461. i = encodeVarintControl(data, i, uint64(m.Secret.Size()))
  4462. n28, err := m.Secret.MarshalTo(data[i:])
  4463. if err != nil {
  4464. return 0, err
  4465. }
  4466. i += n28
  4467. }
  4468. return i, nil
  4469. }
  4470. func (m *ListSecretsRequest) Marshal() (data []byte, err error) {
  4471. size := m.Size()
  4472. data = make([]byte, size)
  4473. n, err := m.MarshalTo(data)
  4474. if err != nil {
  4475. return nil, err
  4476. }
  4477. return data[:n], nil
  4478. }
  4479. func (m *ListSecretsRequest) MarshalTo(data []byte) (int, error) {
  4480. var i int
  4481. _ = i
  4482. var l int
  4483. _ = l
  4484. if m.Filters != nil {
  4485. data[i] = 0xa
  4486. i++
  4487. i = encodeVarintControl(data, i, uint64(m.Filters.Size()))
  4488. n29, err := m.Filters.MarshalTo(data[i:])
  4489. if err != nil {
  4490. return 0, err
  4491. }
  4492. i += n29
  4493. }
  4494. return i, nil
  4495. }
  4496. func (m *ListSecretsRequest_Filters) Marshal() (data []byte, err error) {
  4497. size := m.Size()
  4498. data = make([]byte, size)
  4499. n, err := m.MarshalTo(data)
  4500. if err != nil {
  4501. return nil, err
  4502. }
  4503. return data[:n], nil
  4504. }
  4505. func (m *ListSecretsRequest_Filters) MarshalTo(data []byte) (int, error) {
  4506. var i int
  4507. _ = i
  4508. var l int
  4509. _ = l
  4510. if len(m.Names) > 0 {
  4511. for _, s := range m.Names {
  4512. data[i] = 0xa
  4513. i++
  4514. l = len(s)
  4515. for l >= 1<<7 {
  4516. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4517. l >>= 7
  4518. i++
  4519. }
  4520. data[i] = uint8(l)
  4521. i++
  4522. i += copy(data[i:], s)
  4523. }
  4524. }
  4525. if len(m.IDPrefixes) > 0 {
  4526. for _, s := range m.IDPrefixes {
  4527. data[i] = 0x12
  4528. i++
  4529. l = len(s)
  4530. for l >= 1<<7 {
  4531. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4532. l >>= 7
  4533. i++
  4534. }
  4535. data[i] = uint8(l)
  4536. i++
  4537. i += copy(data[i:], s)
  4538. }
  4539. }
  4540. if len(m.Labels) > 0 {
  4541. for k, _ := range m.Labels {
  4542. data[i] = 0x1a
  4543. i++
  4544. v := m.Labels[k]
  4545. mapSize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  4546. i = encodeVarintControl(data, i, uint64(mapSize))
  4547. data[i] = 0xa
  4548. i++
  4549. i = encodeVarintControl(data, i, uint64(len(k)))
  4550. i += copy(data[i:], k)
  4551. data[i] = 0x12
  4552. i++
  4553. i = encodeVarintControl(data, i, uint64(len(v)))
  4554. i += copy(data[i:], v)
  4555. }
  4556. }
  4557. if len(m.NamePrefixes) > 0 {
  4558. for _, s := range m.NamePrefixes {
  4559. data[i] = 0x22
  4560. i++
  4561. l = len(s)
  4562. for l >= 1<<7 {
  4563. data[i] = uint8(uint64(l)&0x7f | 0x80)
  4564. l >>= 7
  4565. i++
  4566. }
  4567. data[i] = uint8(l)
  4568. i++
  4569. i += copy(data[i:], s)
  4570. }
  4571. }
  4572. return i, nil
  4573. }
  4574. func (m *ListSecretsResponse) Marshal() (data []byte, err error) {
  4575. size := m.Size()
  4576. data = make([]byte, size)
  4577. n, err := m.MarshalTo(data)
  4578. if err != nil {
  4579. return nil, err
  4580. }
  4581. return data[:n], nil
  4582. }
  4583. func (m *ListSecretsResponse) MarshalTo(data []byte) (int, error) {
  4584. var i int
  4585. _ = i
  4586. var l int
  4587. _ = l
  4588. if len(m.Secrets) > 0 {
  4589. for _, msg := range m.Secrets {
  4590. data[i] = 0xa
  4591. i++
  4592. i = encodeVarintControl(data, i, uint64(msg.Size()))
  4593. n, err := msg.MarshalTo(data[i:])
  4594. if err != nil {
  4595. return 0, err
  4596. }
  4597. i += n
  4598. }
  4599. }
  4600. return i, nil
  4601. }
  4602. func (m *CreateSecretRequest) Marshal() (data []byte, err error) {
  4603. size := m.Size()
  4604. data = make([]byte, size)
  4605. n, err := m.MarshalTo(data)
  4606. if err != nil {
  4607. return nil, err
  4608. }
  4609. return data[:n], nil
  4610. }
  4611. func (m *CreateSecretRequest) MarshalTo(data []byte) (int, error) {
  4612. var i int
  4613. _ = i
  4614. var l int
  4615. _ = l
  4616. if m.Spec != nil {
  4617. data[i] = 0xa
  4618. i++
  4619. i = encodeVarintControl(data, i, uint64(m.Spec.Size()))
  4620. n30, err := m.Spec.MarshalTo(data[i:])
  4621. if err != nil {
  4622. return 0, err
  4623. }
  4624. i += n30
  4625. }
  4626. return i, nil
  4627. }
  4628. func (m *CreateSecretResponse) Marshal() (data []byte, err error) {
  4629. size := m.Size()
  4630. data = make([]byte, size)
  4631. n, err := m.MarshalTo(data)
  4632. if err != nil {
  4633. return nil, err
  4634. }
  4635. return data[:n], nil
  4636. }
  4637. func (m *CreateSecretResponse) MarshalTo(data []byte) (int, error) {
  4638. var i int
  4639. _ = i
  4640. var l int
  4641. _ = l
  4642. if m.Secret != nil {
  4643. data[i] = 0xa
  4644. i++
  4645. i = encodeVarintControl(data, i, uint64(m.Secret.Size()))
  4646. n31, err := m.Secret.MarshalTo(data[i:])
  4647. if err != nil {
  4648. return 0, err
  4649. }
  4650. i += n31
  4651. }
  4652. return i, nil
  4653. }
  4654. func (m *RemoveSecretRequest) Marshal() (data []byte, err error) {
  4655. size := m.Size()
  4656. data = make([]byte, size)
  4657. n, err := m.MarshalTo(data)
  4658. if err != nil {
  4659. return nil, err
  4660. }
  4661. return data[:n], nil
  4662. }
  4663. func (m *RemoveSecretRequest) MarshalTo(data []byte) (int, error) {
  4664. var i int
  4665. _ = i
  4666. var l int
  4667. _ = l
  4668. if len(m.SecretID) > 0 {
  4669. data[i] = 0xa
  4670. i++
  4671. i = encodeVarintControl(data, i, uint64(len(m.SecretID)))
  4672. i += copy(data[i:], m.SecretID)
  4673. }
  4674. return i, nil
  4675. }
  4676. func (m *RemoveSecretResponse) Marshal() (data []byte, err error) {
  4677. size := m.Size()
  4678. data = make([]byte, size)
  4679. n, err := m.MarshalTo(data)
  4680. if err != nil {
  4681. return nil, err
  4682. }
  4683. return data[:n], nil
  4684. }
  4685. func (m *RemoveSecretResponse) MarshalTo(data []byte) (int, error) {
  4686. var i int
  4687. _ = i
  4688. var l int
  4689. _ = l
  4690. return i, nil
  4691. }
  4692. func encodeFixed64Control(data []byte, offset int, v uint64) int {
  4693. data[offset] = uint8(v)
  4694. data[offset+1] = uint8(v >> 8)
  4695. data[offset+2] = uint8(v >> 16)
  4696. data[offset+3] = uint8(v >> 24)
  4697. data[offset+4] = uint8(v >> 32)
  4698. data[offset+5] = uint8(v >> 40)
  4699. data[offset+6] = uint8(v >> 48)
  4700. data[offset+7] = uint8(v >> 56)
  4701. return offset + 8
  4702. }
  4703. func encodeFixed32Control(data []byte, offset int, v uint32) int {
  4704. data[offset] = uint8(v)
  4705. data[offset+1] = uint8(v >> 8)
  4706. data[offset+2] = uint8(v >> 16)
  4707. data[offset+3] = uint8(v >> 24)
  4708. return offset + 4
  4709. }
  4710. func encodeVarintControl(data []byte, offset int, v uint64) int {
  4711. for v >= 1<<7 {
  4712. data[offset] = uint8(v&0x7f | 0x80)
  4713. v >>= 7
  4714. offset++
  4715. }
  4716. data[offset] = uint8(v)
  4717. return offset + 1
  4718. }
  4719. type raftProxyControlServer struct {
  4720. local ControlServer
  4721. connSelector raftselector.ConnProvider
  4722. localCtxMods, remoteCtxMods []func(context.Context) (context.Context, error)
  4723. }
  4724. func NewRaftProxyControlServer(local ControlServer, connSelector raftselector.ConnProvider, localCtxMod, remoteCtxMod func(context.Context) (context.Context, error)) ControlServer {
  4725. redirectChecker := func(ctx context.Context) (context.Context, error) {
  4726. s, ok := transport.StreamFromContext(ctx)
  4727. if !ok {
  4728. return ctx, grpc.Errorf(codes.InvalidArgument, "remote addr is not found in context")
  4729. }
  4730. addr := s.ServerTransport().RemoteAddr().String()
  4731. md, ok := metadata.FromContext(ctx)
  4732. if ok && len(md["redirect"]) != 0 {
  4733. return ctx, grpc.Errorf(codes.ResourceExhausted, "more than one redirect to leader from: %s", md["redirect"])
  4734. }
  4735. if !ok {
  4736. md = metadata.New(map[string]string{})
  4737. }
  4738. md["redirect"] = append(md["redirect"], addr)
  4739. return metadata.NewContext(ctx, md), nil
  4740. }
  4741. remoteMods := []func(context.Context) (context.Context, error){redirectChecker}
  4742. remoteMods = append(remoteMods, remoteCtxMod)
  4743. var localMods []func(context.Context) (context.Context, error)
  4744. if localCtxMod != nil {
  4745. localMods = []func(context.Context) (context.Context, error){localCtxMod}
  4746. }
  4747. return &raftProxyControlServer{
  4748. local: local,
  4749. connSelector: connSelector,
  4750. localCtxMods: localMods,
  4751. remoteCtxMods: remoteMods,
  4752. }
  4753. }
  4754. func (p *raftProxyControlServer) runCtxMods(ctx context.Context, ctxMods []func(context.Context) (context.Context, error)) (context.Context, error) {
  4755. var err error
  4756. for _, mod := range ctxMods {
  4757. ctx, err = mod(ctx)
  4758. if err != nil {
  4759. return ctx, err
  4760. }
  4761. }
  4762. return ctx, nil
  4763. }
  4764. func (p *raftProxyControlServer) pollNewLeaderConn(ctx context.Context) (*grpc.ClientConn, error) {
  4765. ticker := time.NewTicker(500 * time.Millisecond)
  4766. defer ticker.Stop()
  4767. for {
  4768. select {
  4769. case <-ticker.C:
  4770. conn, err := p.connSelector.LeaderConn(ctx)
  4771. if err != nil {
  4772. return nil, err
  4773. }
  4774. client := NewHealthClient(conn)
  4775. resp, err := client.Check(ctx, &HealthCheckRequest{Service: "Raft"})
  4776. if err != nil || resp.Status != HealthCheckResponse_SERVING {
  4777. continue
  4778. }
  4779. return conn, nil
  4780. case <-ctx.Done():
  4781. return nil, ctx.Err()
  4782. }
  4783. }
  4784. }
  4785. func (p *raftProxyControlServer) GetNode(ctx context.Context, r *GetNodeRequest) (*GetNodeResponse, error) {
  4786. conn, err := p.connSelector.LeaderConn(ctx)
  4787. if err != nil {
  4788. if err == raftselector.ErrIsLeader {
  4789. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4790. if err != nil {
  4791. return nil, err
  4792. }
  4793. return p.local.GetNode(ctx, r)
  4794. }
  4795. return nil, err
  4796. }
  4797. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4798. if err != nil {
  4799. return nil, err
  4800. }
  4801. resp, err := NewControlClient(conn).GetNode(modCtx, r)
  4802. if err != nil {
  4803. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4804. return resp, err
  4805. }
  4806. conn, err := p.pollNewLeaderConn(ctx)
  4807. if err != nil {
  4808. if err == raftselector.ErrIsLeader {
  4809. return p.local.GetNode(ctx, r)
  4810. }
  4811. return nil, err
  4812. }
  4813. return NewControlClient(conn).GetNode(modCtx, r)
  4814. }
  4815. return resp, err
  4816. }
  4817. func (p *raftProxyControlServer) ListNodes(ctx context.Context, r *ListNodesRequest) (*ListNodesResponse, error) {
  4818. conn, err := p.connSelector.LeaderConn(ctx)
  4819. if err != nil {
  4820. if err == raftselector.ErrIsLeader {
  4821. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4822. if err != nil {
  4823. return nil, err
  4824. }
  4825. return p.local.ListNodes(ctx, r)
  4826. }
  4827. return nil, err
  4828. }
  4829. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4830. if err != nil {
  4831. return nil, err
  4832. }
  4833. resp, err := NewControlClient(conn).ListNodes(modCtx, r)
  4834. if err != nil {
  4835. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4836. return resp, err
  4837. }
  4838. conn, err := p.pollNewLeaderConn(ctx)
  4839. if err != nil {
  4840. if err == raftselector.ErrIsLeader {
  4841. return p.local.ListNodes(ctx, r)
  4842. }
  4843. return nil, err
  4844. }
  4845. return NewControlClient(conn).ListNodes(modCtx, r)
  4846. }
  4847. return resp, err
  4848. }
  4849. func (p *raftProxyControlServer) UpdateNode(ctx context.Context, r *UpdateNodeRequest) (*UpdateNodeResponse, error) {
  4850. conn, err := p.connSelector.LeaderConn(ctx)
  4851. if err != nil {
  4852. if err == raftselector.ErrIsLeader {
  4853. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4854. if err != nil {
  4855. return nil, err
  4856. }
  4857. return p.local.UpdateNode(ctx, r)
  4858. }
  4859. return nil, err
  4860. }
  4861. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4862. if err != nil {
  4863. return nil, err
  4864. }
  4865. resp, err := NewControlClient(conn).UpdateNode(modCtx, r)
  4866. if err != nil {
  4867. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4868. return resp, err
  4869. }
  4870. conn, err := p.pollNewLeaderConn(ctx)
  4871. if err != nil {
  4872. if err == raftselector.ErrIsLeader {
  4873. return p.local.UpdateNode(ctx, r)
  4874. }
  4875. return nil, err
  4876. }
  4877. return NewControlClient(conn).UpdateNode(modCtx, r)
  4878. }
  4879. return resp, err
  4880. }
  4881. func (p *raftProxyControlServer) RemoveNode(ctx context.Context, r *RemoveNodeRequest) (*RemoveNodeResponse, error) {
  4882. conn, err := p.connSelector.LeaderConn(ctx)
  4883. if err != nil {
  4884. if err == raftselector.ErrIsLeader {
  4885. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4886. if err != nil {
  4887. return nil, err
  4888. }
  4889. return p.local.RemoveNode(ctx, r)
  4890. }
  4891. return nil, err
  4892. }
  4893. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4894. if err != nil {
  4895. return nil, err
  4896. }
  4897. resp, err := NewControlClient(conn).RemoveNode(modCtx, r)
  4898. if err != nil {
  4899. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4900. return resp, err
  4901. }
  4902. conn, err := p.pollNewLeaderConn(ctx)
  4903. if err != nil {
  4904. if err == raftselector.ErrIsLeader {
  4905. return p.local.RemoveNode(ctx, r)
  4906. }
  4907. return nil, err
  4908. }
  4909. return NewControlClient(conn).RemoveNode(modCtx, r)
  4910. }
  4911. return resp, err
  4912. }
  4913. func (p *raftProxyControlServer) GetTask(ctx context.Context, r *GetTaskRequest) (*GetTaskResponse, error) {
  4914. conn, err := p.connSelector.LeaderConn(ctx)
  4915. if err != nil {
  4916. if err == raftselector.ErrIsLeader {
  4917. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4918. if err != nil {
  4919. return nil, err
  4920. }
  4921. return p.local.GetTask(ctx, r)
  4922. }
  4923. return nil, err
  4924. }
  4925. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4926. if err != nil {
  4927. return nil, err
  4928. }
  4929. resp, err := NewControlClient(conn).GetTask(modCtx, r)
  4930. if err != nil {
  4931. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4932. return resp, err
  4933. }
  4934. conn, err := p.pollNewLeaderConn(ctx)
  4935. if err != nil {
  4936. if err == raftselector.ErrIsLeader {
  4937. return p.local.GetTask(ctx, r)
  4938. }
  4939. return nil, err
  4940. }
  4941. return NewControlClient(conn).GetTask(modCtx, r)
  4942. }
  4943. return resp, err
  4944. }
  4945. func (p *raftProxyControlServer) ListTasks(ctx context.Context, r *ListTasksRequest) (*ListTasksResponse, error) {
  4946. conn, err := p.connSelector.LeaderConn(ctx)
  4947. if err != nil {
  4948. if err == raftselector.ErrIsLeader {
  4949. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4950. if err != nil {
  4951. return nil, err
  4952. }
  4953. return p.local.ListTasks(ctx, r)
  4954. }
  4955. return nil, err
  4956. }
  4957. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4958. if err != nil {
  4959. return nil, err
  4960. }
  4961. resp, err := NewControlClient(conn).ListTasks(modCtx, r)
  4962. if err != nil {
  4963. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4964. return resp, err
  4965. }
  4966. conn, err := p.pollNewLeaderConn(ctx)
  4967. if err != nil {
  4968. if err == raftselector.ErrIsLeader {
  4969. return p.local.ListTasks(ctx, r)
  4970. }
  4971. return nil, err
  4972. }
  4973. return NewControlClient(conn).ListTasks(modCtx, r)
  4974. }
  4975. return resp, err
  4976. }
  4977. func (p *raftProxyControlServer) RemoveTask(ctx context.Context, r *RemoveTaskRequest) (*RemoveTaskResponse, error) {
  4978. conn, err := p.connSelector.LeaderConn(ctx)
  4979. if err != nil {
  4980. if err == raftselector.ErrIsLeader {
  4981. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  4982. if err != nil {
  4983. return nil, err
  4984. }
  4985. return p.local.RemoveTask(ctx, r)
  4986. }
  4987. return nil, err
  4988. }
  4989. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  4990. if err != nil {
  4991. return nil, err
  4992. }
  4993. resp, err := NewControlClient(conn).RemoveTask(modCtx, r)
  4994. if err != nil {
  4995. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  4996. return resp, err
  4997. }
  4998. conn, err := p.pollNewLeaderConn(ctx)
  4999. if err != nil {
  5000. if err == raftselector.ErrIsLeader {
  5001. return p.local.RemoveTask(ctx, r)
  5002. }
  5003. return nil, err
  5004. }
  5005. return NewControlClient(conn).RemoveTask(modCtx, r)
  5006. }
  5007. return resp, err
  5008. }
  5009. func (p *raftProxyControlServer) GetService(ctx context.Context, r *GetServiceRequest) (*GetServiceResponse, error) {
  5010. conn, err := p.connSelector.LeaderConn(ctx)
  5011. if err != nil {
  5012. if err == raftselector.ErrIsLeader {
  5013. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5014. if err != nil {
  5015. return nil, err
  5016. }
  5017. return p.local.GetService(ctx, r)
  5018. }
  5019. return nil, err
  5020. }
  5021. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5022. if err != nil {
  5023. return nil, err
  5024. }
  5025. resp, err := NewControlClient(conn).GetService(modCtx, r)
  5026. if err != nil {
  5027. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5028. return resp, err
  5029. }
  5030. conn, err := p.pollNewLeaderConn(ctx)
  5031. if err != nil {
  5032. if err == raftselector.ErrIsLeader {
  5033. return p.local.GetService(ctx, r)
  5034. }
  5035. return nil, err
  5036. }
  5037. return NewControlClient(conn).GetService(modCtx, r)
  5038. }
  5039. return resp, err
  5040. }
  5041. func (p *raftProxyControlServer) ListServices(ctx context.Context, r *ListServicesRequest) (*ListServicesResponse, error) {
  5042. conn, err := p.connSelector.LeaderConn(ctx)
  5043. if err != nil {
  5044. if err == raftselector.ErrIsLeader {
  5045. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5046. if err != nil {
  5047. return nil, err
  5048. }
  5049. return p.local.ListServices(ctx, r)
  5050. }
  5051. return nil, err
  5052. }
  5053. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5054. if err != nil {
  5055. return nil, err
  5056. }
  5057. resp, err := NewControlClient(conn).ListServices(modCtx, r)
  5058. if err != nil {
  5059. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5060. return resp, err
  5061. }
  5062. conn, err := p.pollNewLeaderConn(ctx)
  5063. if err != nil {
  5064. if err == raftselector.ErrIsLeader {
  5065. return p.local.ListServices(ctx, r)
  5066. }
  5067. return nil, err
  5068. }
  5069. return NewControlClient(conn).ListServices(modCtx, r)
  5070. }
  5071. return resp, err
  5072. }
  5073. func (p *raftProxyControlServer) CreateService(ctx context.Context, r *CreateServiceRequest) (*CreateServiceResponse, error) {
  5074. conn, err := p.connSelector.LeaderConn(ctx)
  5075. if err != nil {
  5076. if err == raftselector.ErrIsLeader {
  5077. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5078. if err != nil {
  5079. return nil, err
  5080. }
  5081. return p.local.CreateService(ctx, r)
  5082. }
  5083. return nil, err
  5084. }
  5085. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5086. if err != nil {
  5087. return nil, err
  5088. }
  5089. resp, err := NewControlClient(conn).CreateService(modCtx, r)
  5090. if err != nil {
  5091. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5092. return resp, err
  5093. }
  5094. conn, err := p.pollNewLeaderConn(ctx)
  5095. if err != nil {
  5096. if err == raftselector.ErrIsLeader {
  5097. return p.local.CreateService(ctx, r)
  5098. }
  5099. return nil, err
  5100. }
  5101. return NewControlClient(conn).CreateService(modCtx, r)
  5102. }
  5103. return resp, err
  5104. }
  5105. func (p *raftProxyControlServer) UpdateService(ctx context.Context, r *UpdateServiceRequest) (*UpdateServiceResponse, error) {
  5106. conn, err := p.connSelector.LeaderConn(ctx)
  5107. if err != nil {
  5108. if err == raftselector.ErrIsLeader {
  5109. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5110. if err != nil {
  5111. return nil, err
  5112. }
  5113. return p.local.UpdateService(ctx, r)
  5114. }
  5115. return nil, err
  5116. }
  5117. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5118. if err != nil {
  5119. return nil, err
  5120. }
  5121. resp, err := NewControlClient(conn).UpdateService(modCtx, r)
  5122. if err != nil {
  5123. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5124. return resp, err
  5125. }
  5126. conn, err := p.pollNewLeaderConn(ctx)
  5127. if err != nil {
  5128. if err == raftselector.ErrIsLeader {
  5129. return p.local.UpdateService(ctx, r)
  5130. }
  5131. return nil, err
  5132. }
  5133. return NewControlClient(conn).UpdateService(modCtx, r)
  5134. }
  5135. return resp, err
  5136. }
  5137. func (p *raftProxyControlServer) RemoveService(ctx context.Context, r *RemoveServiceRequest) (*RemoveServiceResponse, error) {
  5138. conn, err := p.connSelector.LeaderConn(ctx)
  5139. if err != nil {
  5140. if err == raftselector.ErrIsLeader {
  5141. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5142. if err != nil {
  5143. return nil, err
  5144. }
  5145. return p.local.RemoveService(ctx, r)
  5146. }
  5147. return nil, err
  5148. }
  5149. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5150. if err != nil {
  5151. return nil, err
  5152. }
  5153. resp, err := NewControlClient(conn).RemoveService(modCtx, r)
  5154. if err != nil {
  5155. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5156. return resp, err
  5157. }
  5158. conn, err := p.pollNewLeaderConn(ctx)
  5159. if err != nil {
  5160. if err == raftselector.ErrIsLeader {
  5161. return p.local.RemoveService(ctx, r)
  5162. }
  5163. return nil, err
  5164. }
  5165. return NewControlClient(conn).RemoveService(modCtx, r)
  5166. }
  5167. return resp, err
  5168. }
  5169. func (p *raftProxyControlServer) GetNetwork(ctx context.Context, r *GetNetworkRequest) (*GetNetworkResponse, error) {
  5170. conn, err := p.connSelector.LeaderConn(ctx)
  5171. if err != nil {
  5172. if err == raftselector.ErrIsLeader {
  5173. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5174. if err != nil {
  5175. return nil, err
  5176. }
  5177. return p.local.GetNetwork(ctx, r)
  5178. }
  5179. return nil, err
  5180. }
  5181. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5182. if err != nil {
  5183. return nil, err
  5184. }
  5185. resp, err := NewControlClient(conn).GetNetwork(modCtx, r)
  5186. if err != nil {
  5187. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5188. return resp, err
  5189. }
  5190. conn, err := p.pollNewLeaderConn(ctx)
  5191. if err != nil {
  5192. if err == raftselector.ErrIsLeader {
  5193. return p.local.GetNetwork(ctx, r)
  5194. }
  5195. return nil, err
  5196. }
  5197. return NewControlClient(conn).GetNetwork(modCtx, r)
  5198. }
  5199. return resp, err
  5200. }
  5201. func (p *raftProxyControlServer) ListNetworks(ctx context.Context, r *ListNetworksRequest) (*ListNetworksResponse, error) {
  5202. conn, err := p.connSelector.LeaderConn(ctx)
  5203. if err != nil {
  5204. if err == raftselector.ErrIsLeader {
  5205. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5206. if err != nil {
  5207. return nil, err
  5208. }
  5209. return p.local.ListNetworks(ctx, r)
  5210. }
  5211. return nil, err
  5212. }
  5213. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5214. if err != nil {
  5215. return nil, err
  5216. }
  5217. resp, err := NewControlClient(conn).ListNetworks(modCtx, r)
  5218. if err != nil {
  5219. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5220. return resp, err
  5221. }
  5222. conn, err := p.pollNewLeaderConn(ctx)
  5223. if err != nil {
  5224. if err == raftselector.ErrIsLeader {
  5225. return p.local.ListNetworks(ctx, r)
  5226. }
  5227. return nil, err
  5228. }
  5229. return NewControlClient(conn).ListNetworks(modCtx, r)
  5230. }
  5231. return resp, err
  5232. }
  5233. func (p *raftProxyControlServer) CreateNetwork(ctx context.Context, r *CreateNetworkRequest) (*CreateNetworkResponse, error) {
  5234. conn, err := p.connSelector.LeaderConn(ctx)
  5235. if err != nil {
  5236. if err == raftselector.ErrIsLeader {
  5237. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5238. if err != nil {
  5239. return nil, err
  5240. }
  5241. return p.local.CreateNetwork(ctx, r)
  5242. }
  5243. return nil, err
  5244. }
  5245. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5246. if err != nil {
  5247. return nil, err
  5248. }
  5249. resp, err := NewControlClient(conn).CreateNetwork(modCtx, r)
  5250. if err != nil {
  5251. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5252. return resp, err
  5253. }
  5254. conn, err := p.pollNewLeaderConn(ctx)
  5255. if err != nil {
  5256. if err == raftselector.ErrIsLeader {
  5257. return p.local.CreateNetwork(ctx, r)
  5258. }
  5259. return nil, err
  5260. }
  5261. return NewControlClient(conn).CreateNetwork(modCtx, r)
  5262. }
  5263. return resp, err
  5264. }
  5265. func (p *raftProxyControlServer) RemoveNetwork(ctx context.Context, r *RemoveNetworkRequest) (*RemoveNetworkResponse, error) {
  5266. conn, err := p.connSelector.LeaderConn(ctx)
  5267. if err != nil {
  5268. if err == raftselector.ErrIsLeader {
  5269. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5270. if err != nil {
  5271. return nil, err
  5272. }
  5273. return p.local.RemoveNetwork(ctx, r)
  5274. }
  5275. return nil, err
  5276. }
  5277. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5278. if err != nil {
  5279. return nil, err
  5280. }
  5281. resp, err := NewControlClient(conn).RemoveNetwork(modCtx, r)
  5282. if err != nil {
  5283. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5284. return resp, err
  5285. }
  5286. conn, err := p.pollNewLeaderConn(ctx)
  5287. if err != nil {
  5288. if err == raftselector.ErrIsLeader {
  5289. return p.local.RemoveNetwork(ctx, r)
  5290. }
  5291. return nil, err
  5292. }
  5293. return NewControlClient(conn).RemoveNetwork(modCtx, r)
  5294. }
  5295. return resp, err
  5296. }
  5297. func (p *raftProxyControlServer) GetCluster(ctx context.Context, r *GetClusterRequest) (*GetClusterResponse, error) {
  5298. conn, err := p.connSelector.LeaderConn(ctx)
  5299. if err != nil {
  5300. if err == raftselector.ErrIsLeader {
  5301. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5302. if err != nil {
  5303. return nil, err
  5304. }
  5305. return p.local.GetCluster(ctx, r)
  5306. }
  5307. return nil, err
  5308. }
  5309. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5310. if err != nil {
  5311. return nil, err
  5312. }
  5313. resp, err := NewControlClient(conn).GetCluster(modCtx, r)
  5314. if err != nil {
  5315. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5316. return resp, err
  5317. }
  5318. conn, err := p.pollNewLeaderConn(ctx)
  5319. if err != nil {
  5320. if err == raftselector.ErrIsLeader {
  5321. return p.local.GetCluster(ctx, r)
  5322. }
  5323. return nil, err
  5324. }
  5325. return NewControlClient(conn).GetCluster(modCtx, r)
  5326. }
  5327. return resp, err
  5328. }
  5329. func (p *raftProxyControlServer) ListClusters(ctx context.Context, r *ListClustersRequest) (*ListClustersResponse, error) {
  5330. conn, err := p.connSelector.LeaderConn(ctx)
  5331. if err != nil {
  5332. if err == raftselector.ErrIsLeader {
  5333. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5334. if err != nil {
  5335. return nil, err
  5336. }
  5337. return p.local.ListClusters(ctx, r)
  5338. }
  5339. return nil, err
  5340. }
  5341. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5342. if err != nil {
  5343. return nil, err
  5344. }
  5345. resp, err := NewControlClient(conn).ListClusters(modCtx, r)
  5346. if err != nil {
  5347. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5348. return resp, err
  5349. }
  5350. conn, err := p.pollNewLeaderConn(ctx)
  5351. if err != nil {
  5352. if err == raftselector.ErrIsLeader {
  5353. return p.local.ListClusters(ctx, r)
  5354. }
  5355. return nil, err
  5356. }
  5357. return NewControlClient(conn).ListClusters(modCtx, r)
  5358. }
  5359. return resp, err
  5360. }
  5361. func (p *raftProxyControlServer) UpdateCluster(ctx context.Context, r *UpdateClusterRequest) (*UpdateClusterResponse, error) {
  5362. conn, err := p.connSelector.LeaderConn(ctx)
  5363. if err != nil {
  5364. if err == raftselector.ErrIsLeader {
  5365. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5366. if err != nil {
  5367. return nil, err
  5368. }
  5369. return p.local.UpdateCluster(ctx, r)
  5370. }
  5371. return nil, err
  5372. }
  5373. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5374. if err != nil {
  5375. return nil, err
  5376. }
  5377. resp, err := NewControlClient(conn).UpdateCluster(modCtx, r)
  5378. if err != nil {
  5379. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5380. return resp, err
  5381. }
  5382. conn, err := p.pollNewLeaderConn(ctx)
  5383. if err != nil {
  5384. if err == raftselector.ErrIsLeader {
  5385. return p.local.UpdateCluster(ctx, r)
  5386. }
  5387. return nil, err
  5388. }
  5389. return NewControlClient(conn).UpdateCluster(modCtx, r)
  5390. }
  5391. return resp, err
  5392. }
  5393. func (p *raftProxyControlServer) GetSecret(ctx context.Context, r *GetSecretRequest) (*GetSecretResponse, error) {
  5394. conn, err := p.connSelector.LeaderConn(ctx)
  5395. if err != nil {
  5396. if err == raftselector.ErrIsLeader {
  5397. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5398. if err != nil {
  5399. return nil, err
  5400. }
  5401. return p.local.GetSecret(ctx, r)
  5402. }
  5403. return nil, err
  5404. }
  5405. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5406. if err != nil {
  5407. return nil, err
  5408. }
  5409. resp, err := NewControlClient(conn).GetSecret(modCtx, r)
  5410. if err != nil {
  5411. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5412. return resp, err
  5413. }
  5414. conn, err := p.pollNewLeaderConn(ctx)
  5415. if err != nil {
  5416. if err == raftselector.ErrIsLeader {
  5417. return p.local.GetSecret(ctx, r)
  5418. }
  5419. return nil, err
  5420. }
  5421. return NewControlClient(conn).GetSecret(modCtx, r)
  5422. }
  5423. return resp, err
  5424. }
  5425. func (p *raftProxyControlServer) UpdateSecret(ctx context.Context, r *UpdateSecretRequest) (*UpdateSecretResponse, error) {
  5426. conn, err := p.connSelector.LeaderConn(ctx)
  5427. if err != nil {
  5428. if err == raftselector.ErrIsLeader {
  5429. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5430. if err != nil {
  5431. return nil, err
  5432. }
  5433. return p.local.UpdateSecret(ctx, r)
  5434. }
  5435. return nil, err
  5436. }
  5437. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5438. if err != nil {
  5439. return nil, err
  5440. }
  5441. resp, err := NewControlClient(conn).UpdateSecret(modCtx, r)
  5442. if err != nil {
  5443. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5444. return resp, err
  5445. }
  5446. conn, err := p.pollNewLeaderConn(ctx)
  5447. if err != nil {
  5448. if err == raftselector.ErrIsLeader {
  5449. return p.local.UpdateSecret(ctx, r)
  5450. }
  5451. return nil, err
  5452. }
  5453. return NewControlClient(conn).UpdateSecret(modCtx, r)
  5454. }
  5455. return resp, err
  5456. }
  5457. func (p *raftProxyControlServer) ListSecrets(ctx context.Context, r *ListSecretsRequest) (*ListSecretsResponse, error) {
  5458. conn, err := p.connSelector.LeaderConn(ctx)
  5459. if err != nil {
  5460. if err == raftselector.ErrIsLeader {
  5461. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5462. if err != nil {
  5463. return nil, err
  5464. }
  5465. return p.local.ListSecrets(ctx, r)
  5466. }
  5467. return nil, err
  5468. }
  5469. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5470. if err != nil {
  5471. return nil, err
  5472. }
  5473. resp, err := NewControlClient(conn).ListSecrets(modCtx, r)
  5474. if err != nil {
  5475. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5476. return resp, err
  5477. }
  5478. conn, err := p.pollNewLeaderConn(ctx)
  5479. if err != nil {
  5480. if err == raftselector.ErrIsLeader {
  5481. return p.local.ListSecrets(ctx, r)
  5482. }
  5483. return nil, err
  5484. }
  5485. return NewControlClient(conn).ListSecrets(modCtx, r)
  5486. }
  5487. return resp, err
  5488. }
  5489. func (p *raftProxyControlServer) CreateSecret(ctx context.Context, r *CreateSecretRequest) (*CreateSecretResponse, error) {
  5490. conn, err := p.connSelector.LeaderConn(ctx)
  5491. if err != nil {
  5492. if err == raftselector.ErrIsLeader {
  5493. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5494. if err != nil {
  5495. return nil, err
  5496. }
  5497. return p.local.CreateSecret(ctx, r)
  5498. }
  5499. return nil, err
  5500. }
  5501. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5502. if err != nil {
  5503. return nil, err
  5504. }
  5505. resp, err := NewControlClient(conn).CreateSecret(modCtx, r)
  5506. if err != nil {
  5507. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5508. return resp, err
  5509. }
  5510. conn, err := p.pollNewLeaderConn(ctx)
  5511. if err != nil {
  5512. if err == raftselector.ErrIsLeader {
  5513. return p.local.CreateSecret(ctx, r)
  5514. }
  5515. return nil, err
  5516. }
  5517. return NewControlClient(conn).CreateSecret(modCtx, r)
  5518. }
  5519. return resp, err
  5520. }
  5521. func (p *raftProxyControlServer) RemoveSecret(ctx context.Context, r *RemoveSecretRequest) (*RemoveSecretResponse, error) {
  5522. conn, err := p.connSelector.LeaderConn(ctx)
  5523. if err != nil {
  5524. if err == raftselector.ErrIsLeader {
  5525. ctx, err = p.runCtxMods(ctx, p.localCtxMods)
  5526. if err != nil {
  5527. return nil, err
  5528. }
  5529. return p.local.RemoveSecret(ctx, r)
  5530. }
  5531. return nil, err
  5532. }
  5533. modCtx, err := p.runCtxMods(ctx, p.remoteCtxMods)
  5534. if err != nil {
  5535. return nil, err
  5536. }
  5537. resp, err := NewControlClient(conn).RemoveSecret(modCtx, r)
  5538. if err != nil {
  5539. if !strings.Contains(err.Error(), "is closing") && !strings.Contains(err.Error(), "the connection is unavailable") && !strings.Contains(err.Error(), "connection error") {
  5540. return resp, err
  5541. }
  5542. conn, err := p.pollNewLeaderConn(ctx)
  5543. if err != nil {
  5544. if err == raftselector.ErrIsLeader {
  5545. return p.local.RemoveSecret(ctx, r)
  5546. }
  5547. return nil, err
  5548. }
  5549. return NewControlClient(conn).RemoveSecret(modCtx, r)
  5550. }
  5551. return resp, err
  5552. }
  5553. func (m *GetNodeRequest) Size() (n int) {
  5554. var l int
  5555. _ = l
  5556. l = len(m.NodeID)
  5557. if l > 0 {
  5558. n += 1 + l + sovControl(uint64(l))
  5559. }
  5560. return n
  5561. }
  5562. func (m *GetNodeResponse) Size() (n int) {
  5563. var l int
  5564. _ = l
  5565. if m.Node != nil {
  5566. l = m.Node.Size()
  5567. n += 1 + l + sovControl(uint64(l))
  5568. }
  5569. return n
  5570. }
  5571. func (m *ListNodesRequest) Size() (n int) {
  5572. var l int
  5573. _ = l
  5574. if m.Filters != nil {
  5575. l = m.Filters.Size()
  5576. n += 1 + l + sovControl(uint64(l))
  5577. }
  5578. return n
  5579. }
  5580. func (m *ListNodesRequest_Filters) Size() (n int) {
  5581. var l int
  5582. _ = l
  5583. if len(m.Names) > 0 {
  5584. for _, s := range m.Names {
  5585. l = len(s)
  5586. n += 1 + l + sovControl(uint64(l))
  5587. }
  5588. }
  5589. if len(m.IDPrefixes) > 0 {
  5590. for _, s := range m.IDPrefixes {
  5591. l = len(s)
  5592. n += 1 + l + sovControl(uint64(l))
  5593. }
  5594. }
  5595. if len(m.Labels) > 0 {
  5596. for k, v := range m.Labels {
  5597. _ = k
  5598. _ = v
  5599. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  5600. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  5601. }
  5602. }
  5603. if len(m.Memberships) > 0 {
  5604. for _, e := range m.Memberships {
  5605. n += 1 + sovControl(uint64(e))
  5606. }
  5607. }
  5608. if len(m.Roles) > 0 {
  5609. for _, e := range m.Roles {
  5610. n += 1 + sovControl(uint64(e))
  5611. }
  5612. }
  5613. if len(m.NamePrefixes) > 0 {
  5614. for _, s := range m.NamePrefixes {
  5615. l = len(s)
  5616. n += 1 + l + sovControl(uint64(l))
  5617. }
  5618. }
  5619. return n
  5620. }
  5621. func (m *ListNodesResponse) Size() (n int) {
  5622. var l int
  5623. _ = l
  5624. if len(m.Nodes) > 0 {
  5625. for _, e := range m.Nodes {
  5626. l = e.Size()
  5627. n += 1 + l + sovControl(uint64(l))
  5628. }
  5629. }
  5630. return n
  5631. }
  5632. func (m *UpdateNodeRequest) Size() (n int) {
  5633. var l int
  5634. _ = l
  5635. l = len(m.NodeID)
  5636. if l > 0 {
  5637. n += 1 + l + sovControl(uint64(l))
  5638. }
  5639. if m.NodeVersion != nil {
  5640. l = m.NodeVersion.Size()
  5641. n += 1 + l + sovControl(uint64(l))
  5642. }
  5643. if m.Spec != nil {
  5644. l = m.Spec.Size()
  5645. n += 1 + l + sovControl(uint64(l))
  5646. }
  5647. return n
  5648. }
  5649. func (m *UpdateNodeResponse) Size() (n int) {
  5650. var l int
  5651. _ = l
  5652. if m.Node != nil {
  5653. l = m.Node.Size()
  5654. n += 1 + l + sovControl(uint64(l))
  5655. }
  5656. return n
  5657. }
  5658. func (m *RemoveNodeRequest) Size() (n int) {
  5659. var l int
  5660. _ = l
  5661. l = len(m.NodeID)
  5662. if l > 0 {
  5663. n += 1 + l + sovControl(uint64(l))
  5664. }
  5665. if m.Force {
  5666. n += 2
  5667. }
  5668. return n
  5669. }
  5670. func (m *RemoveNodeResponse) Size() (n int) {
  5671. var l int
  5672. _ = l
  5673. return n
  5674. }
  5675. func (m *GetTaskRequest) Size() (n int) {
  5676. var l int
  5677. _ = l
  5678. l = len(m.TaskID)
  5679. if l > 0 {
  5680. n += 1 + l + sovControl(uint64(l))
  5681. }
  5682. return n
  5683. }
  5684. func (m *GetTaskResponse) Size() (n int) {
  5685. var l int
  5686. _ = l
  5687. if m.Task != nil {
  5688. l = m.Task.Size()
  5689. n += 1 + l + sovControl(uint64(l))
  5690. }
  5691. return n
  5692. }
  5693. func (m *RemoveTaskRequest) Size() (n int) {
  5694. var l int
  5695. _ = l
  5696. l = len(m.TaskID)
  5697. if l > 0 {
  5698. n += 1 + l + sovControl(uint64(l))
  5699. }
  5700. return n
  5701. }
  5702. func (m *RemoveTaskResponse) Size() (n int) {
  5703. var l int
  5704. _ = l
  5705. return n
  5706. }
  5707. func (m *ListTasksRequest) Size() (n int) {
  5708. var l int
  5709. _ = l
  5710. if m.Filters != nil {
  5711. l = m.Filters.Size()
  5712. n += 1 + l + sovControl(uint64(l))
  5713. }
  5714. return n
  5715. }
  5716. func (m *ListTasksRequest_Filters) Size() (n int) {
  5717. var l int
  5718. _ = l
  5719. if len(m.Names) > 0 {
  5720. for _, s := range m.Names {
  5721. l = len(s)
  5722. n += 1 + l + sovControl(uint64(l))
  5723. }
  5724. }
  5725. if len(m.IDPrefixes) > 0 {
  5726. for _, s := range m.IDPrefixes {
  5727. l = len(s)
  5728. n += 1 + l + sovControl(uint64(l))
  5729. }
  5730. }
  5731. if len(m.Labels) > 0 {
  5732. for k, v := range m.Labels {
  5733. _ = k
  5734. _ = v
  5735. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  5736. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  5737. }
  5738. }
  5739. if len(m.ServiceIDs) > 0 {
  5740. for _, s := range m.ServiceIDs {
  5741. l = len(s)
  5742. n += 1 + l + sovControl(uint64(l))
  5743. }
  5744. }
  5745. if len(m.NodeIDs) > 0 {
  5746. for _, s := range m.NodeIDs {
  5747. l = len(s)
  5748. n += 1 + l + sovControl(uint64(l))
  5749. }
  5750. }
  5751. if len(m.DesiredStates) > 0 {
  5752. for _, e := range m.DesiredStates {
  5753. n += 1 + sovControl(uint64(e))
  5754. }
  5755. }
  5756. if len(m.NamePrefixes) > 0 {
  5757. for _, s := range m.NamePrefixes {
  5758. l = len(s)
  5759. n += 1 + l + sovControl(uint64(l))
  5760. }
  5761. }
  5762. return n
  5763. }
  5764. func (m *ListTasksResponse) Size() (n int) {
  5765. var l int
  5766. _ = l
  5767. if len(m.Tasks) > 0 {
  5768. for _, e := range m.Tasks {
  5769. l = e.Size()
  5770. n += 1 + l + sovControl(uint64(l))
  5771. }
  5772. }
  5773. return n
  5774. }
  5775. func (m *CreateServiceRequest) Size() (n int) {
  5776. var l int
  5777. _ = l
  5778. if m.Spec != nil {
  5779. l = m.Spec.Size()
  5780. n += 1 + l + sovControl(uint64(l))
  5781. }
  5782. return n
  5783. }
  5784. func (m *CreateServiceResponse) Size() (n int) {
  5785. var l int
  5786. _ = l
  5787. if m.Service != nil {
  5788. l = m.Service.Size()
  5789. n += 1 + l + sovControl(uint64(l))
  5790. }
  5791. return n
  5792. }
  5793. func (m *GetServiceRequest) Size() (n int) {
  5794. var l int
  5795. _ = l
  5796. l = len(m.ServiceID)
  5797. if l > 0 {
  5798. n += 1 + l + sovControl(uint64(l))
  5799. }
  5800. return n
  5801. }
  5802. func (m *GetServiceResponse) Size() (n int) {
  5803. var l int
  5804. _ = l
  5805. if m.Service != nil {
  5806. l = m.Service.Size()
  5807. n += 1 + l + sovControl(uint64(l))
  5808. }
  5809. return n
  5810. }
  5811. func (m *UpdateServiceRequest) Size() (n int) {
  5812. var l int
  5813. _ = l
  5814. l = len(m.ServiceID)
  5815. if l > 0 {
  5816. n += 1 + l + sovControl(uint64(l))
  5817. }
  5818. if m.ServiceVersion != nil {
  5819. l = m.ServiceVersion.Size()
  5820. n += 1 + l + sovControl(uint64(l))
  5821. }
  5822. if m.Spec != nil {
  5823. l = m.Spec.Size()
  5824. n += 1 + l + sovControl(uint64(l))
  5825. }
  5826. return n
  5827. }
  5828. func (m *UpdateServiceResponse) Size() (n int) {
  5829. var l int
  5830. _ = l
  5831. if m.Service != nil {
  5832. l = m.Service.Size()
  5833. n += 1 + l + sovControl(uint64(l))
  5834. }
  5835. return n
  5836. }
  5837. func (m *RemoveServiceRequest) Size() (n int) {
  5838. var l int
  5839. _ = l
  5840. l = len(m.ServiceID)
  5841. if l > 0 {
  5842. n += 1 + l + sovControl(uint64(l))
  5843. }
  5844. return n
  5845. }
  5846. func (m *RemoveServiceResponse) Size() (n int) {
  5847. var l int
  5848. _ = l
  5849. return n
  5850. }
  5851. func (m *ListServicesRequest) Size() (n int) {
  5852. var l int
  5853. _ = l
  5854. if m.Filters != nil {
  5855. l = m.Filters.Size()
  5856. n += 1 + l + sovControl(uint64(l))
  5857. }
  5858. return n
  5859. }
  5860. func (m *ListServicesRequest_Filters) Size() (n int) {
  5861. var l int
  5862. _ = l
  5863. if len(m.Names) > 0 {
  5864. for _, s := range m.Names {
  5865. l = len(s)
  5866. n += 1 + l + sovControl(uint64(l))
  5867. }
  5868. }
  5869. if len(m.IDPrefixes) > 0 {
  5870. for _, s := range m.IDPrefixes {
  5871. l = len(s)
  5872. n += 1 + l + sovControl(uint64(l))
  5873. }
  5874. }
  5875. if len(m.Labels) > 0 {
  5876. for k, v := range m.Labels {
  5877. _ = k
  5878. _ = v
  5879. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  5880. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  5881. }
  5882. }
  5883. if len(m.NamePrefixes) > 0 {
  5884. for _, s := range m.NamePrefixes {
  5885. l = len(s)
  5886. n += 1 + l + sovControl(uint64(l))
  5887. }
  5888. }
  5889. return n
  5890. }
  5891. func (m *ListServicesResponse) Size() (n int) {
  5892. var l int
  5893. _ = l
  5894. if len(m.Services) > 0 {
  5895. for _, e := range m.Services {
  5896. l = e.Size()
  5897. n += 1 + l + sovControl(uint64(l))
  5898. }
  5899. }
  5900. return n
  5901. }
  5902. func (m *CreateNetworkRequest) Size() (n int) {
  5903. var l int
  5904. _ = l
  5905. if m.Spec != nil {
  5906. l = m.Spec.Size()
  5907. n += 1 + l + sovControl(uint64(l))
  5908. }
  5909. return n
  5910. }
  5911. func (m *CreateNetworkResponse) Size() (n int) {
  5912. var l int
  5913. _ = l
  5914. if m.Network != nil {
  5915. l = m.Network.Size()
  5916. n += 1 + l + sovControl(uint64(l))
  5917. }
  5918. return n
  5919. }
  5920. func (m *GetNetworkRequest) Size() (n int) {
  5921. var l int
  5922. _ = l
  5923. l = len(m.Name)
  5924. if l > 0 {
  5925. n += 1 + l + sovControl(uint64(l))
  5926. }
  5927. l = len(m.NetworkID)
  5928. if l > 0 {
  5929. n += 1 + l + sovControl(uint64(l))
  5930. }
  5931. return n
  5932. }
  5933. func (m *GetNetworkResponse) Size() (n int) {
  5934. var l int
  5935. _ = l
  5936. if m.Network != nil {
  5937. l = m.Network.Size()
  5938. n += 1 + l + sovControl(uint64(l))
  5939. }
  5940. return n
  5941. }
  5942. func (m *RemoveNetworkRequest) Size() (n int) {
  5943. var l int
  5944. _ = l
  5945. l = len(m.Name)
  5946. if l > 0 {
  5947. n += 1 + l + sovControl(uint64(l))
  5948. }
  5949. l = len(m.NetworkID)
  5950. if l > 0 {
  5951. n += 1 + l + sovControl(uint64(l))
  5952. }
  5953. return n
  5954. }
  5955. func (m *RemoveNetworkResponse) Size() (n int) {
  5956. var l int
  5957. _ = l
  5958. return n
  5959. }
  5960. func (m *ListNetworksRequest) Size() (n int) {
  5961. var l int
  5962. _ = l
  5963. if m.Filters != nil {
  5964. l = m.Filters.Size()
  5965. n += 1 + l + sovControl(uint64(l))
  5966. }
  5967. return n
  5968. }
  5969. func (m *ListNetworksRequest_Filters) Size() (n int) {
  5970. var l int
  5971. _ = l
  5972. if len(m.Names) > 0 {
  5973. for _, s := range m.Names {
  5974. l = len(s)
  5975. n += 1 + l + sovControl(uint64(l))
  5976. }
  5977. }
  5978. if len(m.IDPrefixes) > 0 {
  5979. for _, s := range m.IDPrefixes {
  5980. l = len(s)
  5981. n += 1 + l + sovControl(uint64(l))
  5982. }
  5983. }
  5984. if len(m.Labels) > 0 {
  5985. for k, v := range m.Labels {
  5986. _ = k
  5987. _ = v
  5988. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  5989. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  5990. }
  5991. }
  5992. if len(m.NamePrefixes) > 0 {
  5993. for _, s := range m.NamePrefixes {
  5994. l = len(s)
  5995. n += 1 + l + sovControl(uint64(l))
  5996. }
  5997. }
  5998. return n
  5999. }
  6000. func (m *ListNetworksResponse) Size() (n int) {
  6001. var l int
  6002. _ = l
  6003. if len(m.Networks) > 0 {
  6004. for _, e := range m.Networks {
  6005. l = e.Size()
  6006. n += 1 + l + sovControl(uint64(l))
  6007. }
  6008. }
  6009. return n
  6010. }
  6011. func (m *GetClusterRequest) Size() (n int) {
  6012. var l int
  6013. _ = l
  6014. l = len(m.ClusterID)
  6015. if l > 0 {
  6016. n += 1 + l + sovControl(uint64(l))
  6017. }
  6018. return n
  6019. }
  6020. func (m *GetClusterResponse) Size() (n int) {
  6021. var l int
  6022. _ = l
  6023. if m.Cluster != nil {
  6024. l = m.Cluster.Size()
  6025. n += 1 + l + sovControl(uint64(l))
  6026. }
  6027. return n
  6028. }
  6029. func (m *ListClustersRequest) Size() (n int) {
  6030. var l int
  6031. _ = l
  6032. if m.Filters != nil {
  6033. l = m.Filters.Size()
  6034. n += 1 + l + sovControl(uint64(l))
  6035. }
  6036. return n
  6037. }
  6038. func (m *ListClustersRequest_Filters) Size() (n int) {
  6039. var l int
  6040. _ = l
  6041. if len(m.Names) > 0 {
  6042. for _, s := range m.Names {
  6043. l = len(s)
  6044. n += 1 + l + sovControl(uint64(l))
  6045. }
  6046. }
  6047. if len(m.IDPrefixes) > 0 {
  6048. for _, s := range m.IDPrefixes {
  6049. l = len(s)
  6050. n += 1 + l + sovControl(uint64(l))
  6051. }
  6052. }
  6053. if len(m.Labels) > 0 {
  6054. for k, v := range m.Labels {
  6055. _ = k
  6056. _ = v
  6057. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  6058. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  6059. }
  6060. }
  6061. if len(m.NamePrefixes) > 0 {
  6062. for _, s := range m.NamePrefixes {
  6063. l = len(s)
  6064. n += 1 + l + sovControl(uint64(l))
  6065. }
  6066. }
  6067. return n
  6068. }
  6069. func (m *ListClustersResponse) Size() (n int) {
  6070. var l int
  6071. _ = l
  6072. if len(m.Clusters) > 0 {
  6073. for _, e := range m.Clusters {
  6074. l = e.Size()
  6075. n += 1 + l + sovControl(uint64(l))
  6076. }
  6077. }
  6078. return n
  6079. }
  6080. func (m *KeyRotation) Size() (n int) {
  6081. var l int
  6082. _ = l
  6083. if m.WorkerJoinToken {
  6084. n += 2
  6085. }
  6086. if m.ManagerJoinToken {
  6087. n += 2
  6088. }
  6089. if m.ManagerUnlockKey {
  6090. n += 2
  6091. }
  6092. return n
  6093. }
  6094. func (m *UpdateClusterRequest) Size() (n int) {
  6095. var l int
  6096. _ = l
  6097. l = len(m.ClusterID)
  6098. if l > 0 {
  6099. n += 1 + l + sovControl(uint64(l))
  6100. }
  6101. if m.ClusterVersion != nil {
  6102. l = m.ClusterVersion.Size()
  6103. n += 1 + l + sovControl(uint64(l))
  6104. }
  6105. if m.Spec != nil {
  6106. l = m.Spec.Size()
  6107. n += 1 + l + sovControl(uint64(l))
  6108. }
  6109. l = m.Rotation.Size()
  6110. n += 1 + l + sovControl(uint64(l))
  6111. return n
  6112. }
  6113. func (m *UpdateClusterResponse) Size() (n int) {
  6114. var l int
  6115. _ = l
  6116. if m.Cluster != nil {
  6117. l = m.Cluster.Size()
  6118. n += 1 + l + sovControl(uint64(l))
  6119. }
  6120. return n
  6121. }
  6122. func (m *GetSecretRequest) Size() (n int) {
  6123. var l int
  6124. _ = l
  6125. l = len(m.SecretID)
  6126. if l > 0 {
  6127. n += 1 + l + sovControl(uint64(l))
  6128. }
  6129. return n
  6130. }
  6131. func (m *GetSecretResponse) Size() (n int) {
  6132. var l int
  6133. _ = l
  6134. if m.Secret != nil {
  6135. l = m.Secret.Size()
  6136. n += 1 + l + sovControl(uint64(l))
  6137. }
  6138. return n
  6139. }
  6140. func (m *UpdateSecretRequest) Size() (n int) {
  6141. var l int
  6142. _ = l
  6143. l = len(m.SecretID)
  6144. if l > 0 {
  6145. n += 1 + l + sovControl(uint64(l))
  6146. }
  6147. if m.SecretVersion != nil {
  6148. l = m.SecretVersion.Size()
  6149. n += 1 + l + sovControl(uint64(l))
  6150. }
  6151. if m.Spec != nil {
  6152. l = m.Spec.Size()
  6153. n += 1 + l + sovControl(uint64(l))
  6154. }
  6155. return n
  6156. }
  6157. func (m *UpdateSecretResponse) Size() (n int) {
  6158. var l int
  6159. _ = l
  6160. if m.Secret != nil {
  6161. l = m.Secret.Size()
  6162. n += 1 + l + sovControl(uint64(l))
  6163. }
  6164. return n
  6165. }
  6166. func (m *ListSecretsRequest) Size() (n int) {
  6167. var l int
  6168. _ = l
  6169. if m.Filters != nil {
  6170. l = m.Filters.Size()
  6171. n += 1 + l + sovControl(uint64(l))
  6172. }
  6173. return n
  6174. }
  6175. func (m *ListSecretsRequest_Filters) Size() (n int) {
  6176. var l int
  6177. _ = l
  6178. if len(m.Names) > 0 {
  6179. for _, s := range m.Names {
  6180. l = len(s)
  6181. n += 1 + l + sovControl(uint64(l))
  6182. }
  6183. }
  6184. if len(m.IDPrefixes) > 0 {
  6185. for _, s := range m.IDPrefixes {
  6186. l = len(s)
  6187. n += 1 + l + sovControl(uint64(l))
  6188. }
  6189. }
  6190. if len(m.Labels) > 0 {
  6191. for k, v := range m.Labels {
  6192. _ = k
  6193. _ = v
  6194. mapEntrySize := 1 + len(k) + sovControl(uint64(len(k))) + 1 + len(v) + sovControl(uint64(len(v)))
  6195. n += mapEntrySize + 1 + sovControl(uint64(mapEntrySize))
  6196. }
  6197. }
  6198. if len(m.NamePrefixes) > 0 {
  6199. for _, s := range m.NamePrefixes {
  6200. l = len(s)
  6201. n += 1 + l + sovControl(uint64(l))
  6202. }
  6203. }
  6204. return n
  6205. }
  6206. func (m *ListSecretsResponse) Size() (n int) {
  6207. var l int
  6208. _ = l
  6209. if len(m.Secrets) > 0 {
  6210. for _, e := range m.Secrets {
  6211. l = e.Size()
  6212. n += 1 + l + sovControl(uint64(l))
  6213. }
  6214. }
  6215. return n
  6216. }
  6217. func (m *CreateSecretRequest) Size() (n int) {
  6218. var l int
  6219. _ = l
  6220. if m.Spec != nil {
  6221. l = m.Spec.Size()
  6222. n += 1 + l + sovControl(uint64(l))
  6223. }
  6224. return n
  6225. }
  6226. func (m *CreateSecretResponse) Size() (n int) {
  6227. var l int
  6228. _ = l
  6229. if m.Secret != nil {
  6230. l = m.Secret.Size()
  6231. n += 1 + l + sovControl(uint64(l))
  6232. }
  6233. return n
  6234. }
  6235. func (m *RemoveSecretRequest) Size() (n int) {
  6236. var l int
  6237. _ = l
  6238. l = len(m.SecretID)
  6239. if l > 0 {
  6240. n += 1 + l + sovControl(uint64(l))
  6241. }
  6242. return n
  6243. }
  6244. func (m *RemoveSecretResponse) Size() (n int) {
  6245. var l int
  6246. _ = l
  6247. return n
  6248. }
  6249. func sovControl(x uint64) (n int) {
  6250. for {
  6251. n++
  6252. x >>= 7
  6253. if x == 0 {
  6254. break
  6255. }
  6256. }
  6257. return n
  6258. }
  6259. func sozControl(x uint64) (n int) {
  6260. return sovControl(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  6261. }
  6262. func (this *GetNodeRequest) String() string {
  6263. if this == nil {
  6264. return "nil"
  6265. }
  6266. s := strings.Join([]string{`&GetNodeRequest{`,
  6267. `NodeID:` + fmt.Sprintf("%v", this.NodeID) + `,`,
  6268. `}`,
  6269. }, "")
  6270. return s
  6271. }
  6272. func (this *GetNodeResponse) String() string {
  6273. if this == nil {
  6274. return "nil"
  6275. }
  6276. s := strings.Join([]string{`&GetNodeResponse{`,
  6277. `Node:` + strings.Replace(fmt.Sprintf("%v", this.Node), "Node", "Node", 1) + `,`,
  6278. `}`,
  6279. }, "")
  6280. return s
  6281. }
  6282. func (this *ListNodesRequest) String() string {
  6283. if this == nil {
  6284. return "nil"
  6285. }
  6286. s := strings.Join([]string{`&ListNodesRequest{`,
  6287. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListNodesRequest_Filters", "ListNodesRequest_Filters", 1) + `,`,
  6288. `}`,
  6289. }, "")
  6290. return s
  6291. }
  6292. func (this *ListNodesRequest_Filters) String() string {
  6293. if this == nil {
  6294. return "nil"
  6295. }
  6296. keysForLabels := make([]string, 0, len(this.Labels))
  6297. for k, _ := range this.Labels {
  6298. keysForLabels = append(keysForLabels, k)
  6299. }
  6300. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6301. mapStringForLabels := "map[string]string{"
  6302. for _, k := range keysForLabels {
  6303. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6304. }
  6305. mapStringForLabels += "}"
  6306. s := strings.Join([]string{`&ListNodesRequest_Filters{`,
  6307. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6308. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6309. `Labels:` + mapStringForLabels + `,`,
  6310. `Memberships:` + fmt.Sprintf("%v", this.Memberships) + `,`,
  6311. `Roles:` + fmt.Sprintf("%v", this.Roles) + `,`,
  6312. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6313. `}`,
  6314. }, "")
  6315. return s
  6316. }
  6317. func (this *ListNodesResponse) String() string {
  6318. if this == nil {
  6319. return "nil"
  6320. }
  6321. s := strings.Join([]string{`&ListNodesResponse{`,
  6322. `Nodes:` + strings.Replace(fmt.Sprintf("%v", this.Nodes), "Node", "Node", 1) + `,`,
  6323. `}`,
  6324. }, "")
  6325. return s
  6326. }
  6327. func (this *UpdateNodeRequest) String() string {
  6328. if this == nil {
  6329. return "nil"
  6330. }
  6331. s := strings.Join([]string{`&UpdateNodeRequest{`,
  6332. `NodeID:` + fmt.Sprintf("%v", this.NodeID) + `,`,
  6333. `NodeVersion:` + strings.Replace(fmt.Sprintf("%v", this.NodeVersion), "Version", "Version", 1) + `,`,
  6334. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "NodeSpec", "NodeSpec", 1) + `,`,
  6335. `}`,
  6336. }, "")
  6337. return s
  6338. }
  6339. func (this *UpdateNodeResponse) String() string {
  6340. if this == nil {
  6341. return "nil"
  6342. }
  6343. s := strings.Join([]string{`&UpdateNodeResponse{`,
  6344. `Node:` + strings.Replace(fmt.Sprintf("%v", this.Node), "Node", "Node", 1) + `,`,
  6345. `}`,
  6346. }, "")
  6347. return s
  6348. }
  6349. func (this *RemoveNodeRequest) String() string {
  6350. if this == nil {
  6351. return "nil"
  6352. }
  6353. s := strings.Join([]string{`&RemoveNodeRequest{`,
  6354. `NodeID:` + fmt.Sprintf("%v", this.NodeID) + `,`,
  6355. `Force:` + fmt.Sprintf("%v", this.Force) + `,`,
  6356. `}`,
  6357. }, "")
  6358. return s
  6359. }
  6360. func (this *RemoveNodeResponse) String() string {
  6361. if this == nil {
  6362. return "nil"
  6363. }
  6364. s := strings.Join([]string{`&RemoveNodeResponse{`,
  6365. `}`,
  6366. }, "")
  6367. return s
  6368. }
  6369. func (this *GetTaskRequest) String() string {
  6370. if this == nil {
  6371. return "nil"
  6372. }
  6373. s := strings.Join([]string{`&GetTaskRequest{`,
  6374. `TaskID:` + fmt.Sprintf("%v", this.TaskID) + `,`,
  6375. `}`,
  6376. }, "")
  6377. return s
  6378. }
  6379. func (this *GetTaskResponse) String() string {
  6380. if this == nil {
  6381. return "nil"
  6382. }
  6383. s := strings.Join([]string{`&GetTaskResponse{`,
  6384. `Task:` + strings.Replace(fmt.Sprintf("%v", this.Task), "Task", "Task", 1) + `,`,
  6385. `}`,
  6386. }, "")
  6387. return s
  6388. }
  6389. func (this *RemoveTaskRequest) String() string {
  6390. if this == nil {
  6391. return "nil"
  6392. }
  6393. s := strings.Join([]string{`&RemoveTaskRequest{`,
  6394. `TaskID:` + fmt.Sprintf("%v", this.TaskID) + `,`,
  6395. `}`,
  6396. }, "")
  6397. return s
  6398. }
  6399. func (this *RemoveTaskResponse) String() string {
  6400. if this == nil {
  6401. return "nil"
  6402. }
  6403. s := strings.Join([]string{`&RemoveTaskResponse{`,
  6404. `}`,
  6405. }, "")
  6406. return s
  6407. }
  6408. func (this *ListTasksRequest) String() string {
  6409. if this == nil {
  6410. return "nil"
  6411. }
  6412. s := strings.Join([]string{`&ListTasksRequest{`,
  6413. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListTasksRequest_Filters", "ListTasksRequest_Filters", 1) + `,`,
  6414. `}`,
  6415. }, "")
  6416. return s
  6417. }
  6418. func (this *ListTasksRequest_Filters) String() string {
  6419. if this == nil {
  6420. return "nil"
  6421. }
  6422. keysForLabels := make([]string, 0, len(this.Labels))
  6423. for k, _ := range this.Labels {
  6424. keysForLabels = append(keysForLabels, k)
  6425. }
  6426. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6427. mapStringForLabels := "map[string]string{"
  6428. for _, k := range keysForLabels {
  6429. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6430. }
  6431. mapStringForLabels += "}"
  6432. s := strings.Join([]string{`&ListTasksRequest_Filters{`,
  6433. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6434. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6435. `Labels:` + mapStringForLabels + `,`,
  6436. `ServiceIDs:` + fmt.Sprintf("%v", this.ServiceIDs) + `,`,
  6437. `NodeIDs:` + fmt.Sprintf("%v", this.NodeIDs) + `,`,
  6438. `DesiredStates:` + fmt.Sprintf("%v", this.DesiredStates) + `,`,
  6439. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6440. `}`,
  6441. }, "")
  6442. return s
  6443. }
  6444. func (this *ListTasksResponse) String() string {
  6445. if this == nil {
  6446. return "nil"
  6447. }
  6448. s := strings.Join([]string{`&ListTasksResponse{`,
  6449. `Tasks:` + strings.Replace(fmt.Sprintf("%v", this.Tasks), "Task", "Task", 1) + `,`,
  6450. `}`,
  6451. }, "")
  6452. return s
  6453. }
  6454. func (this *CreateServiceRequest) String() string {
  6455. if this == nil {
  6456. return "nil"
  6457. }
  6458. s := strings.Join([]string{`&CreateServiceRequest{`,
  6459. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "ServiceSpec", "ServiceSpec", 1) + `,`,
  6460. `}`,
  6461. }, "")
  6462. return s
  6463. }
  6464. func (this *CreateServiceResponse) String() string {
  6465. if this == nil {
  6466. return "nil"
  6467. }
  6468. s := strings.Join([]string{`&CreateServiceResponse{`,
  6469. `Service:` + strings.Replace(fmt.Sprintf("%v", this.Service), "Service", "Service", 1) + `,`,
  6470. `}`,
  6471. }, "")
  6472. return s
  6473. }
  6474. func (this *GetServiceRequest) String() string {
  6475. if this == nil {
  6476. return "nil"
  6477. }
  6478. s := strings.Join([]string{`&GetServiceRequest{`,
  6479. `ServiceID:` + fmt.Sprintf("%v", this.ServiceID) + `,`,
  6480. `}`,
  6481. }, "")
  6482. return s
  6483. }
  6484. func (this *GetServiceResponse) String() string {
  6485. if this == nil {
  6486. return "nil"
  6487. }
  6488. s := strings.Join([]string{`&GetServiceResponse{`,
  6489. `Service:` + strings.Replace(fmt.Sprintf("%v", this.Service), "Service", "Service", 1) + `,`,
  6490. `}`,
  6491. }, "")
  6492. return s
  6493. }
  6494. func (this *UpdateServiceRequest) String() string {
  6495. if this == nil {
  6496. return "nil"
  6497. }
  6498. s := strings.Join([]string{`&UpdateServiceRequest{`,
  6499. `ServiceID:` + fmt.Sprintf("%v", this.ServiceID) + `,`,
  6500. `ServiceVersion:` + strings.Replace(fmt.Sprintf("%v", this.ServiceVersion), "Version", "Version", 1) + `,`,
  6501. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "ServiceSpec", "ServiceSpec", 1) + `,`,
  6502. `}`,
  6503. }, "")
  6504. return s
  6505. }
  6506. func (this *UpdateServiceResponse) String() string {
  6507. if this == nil {
  6508. return "nil"
  6509. }
  6510. s := strings.Join([]string{`&UpdateServiceResponse{`,
  6511. `Service:` + strings.Replace(fmt.Sprintf("%v", this.Service), "Service", "Service", 1) + `,`,
  6512. `}`,
  6513. }, "")
  6514. return s
  6515. }
  6516. func (this *RemoveServiceRequest) String() string {
  6517. if this == nil {
  6518. return "nil"
  6519. }
  6520. s := strings.Join([]string{`&RemoveServiceRequest{`,
  6521. `ServiceID:` + fmt.Sprintf("%v", this.ServiceID) + `,`,
  6522. `}`,
  6523. }, "")
  6524. return s
  6525. }
  6526. func (this *RemoveServiceResponse) String() string {
  6527. if this == nil {
  6528. return "nil"
  6529. }
  6530. s := strings.Join([]string{`&RemoveServiceResponse{`,
  6531. `}`,
  6532. }, "")
  6533. return s
  6534. }
  6535. func (this *ListServicesRequest) String() string {
  6536. if this == nil {
  6537. return "nil"
  6538. }
  6539. s := strings.Join([]string{`&ListServicesRequest{`,
  6540. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListServicesRequest_Filters", "ListServicesRequest_Filters", 1) + `,`,
  6541. `}`,
  6542. }, "")
  6543. return s
  6544. }
  6545. func (this *ListServicesRequest_Filters) String() string {
  6546. if this == nil {
  6547. return "nil"
  6548. }
  6549. keysForLabels := make([]string, 0, len(this.Labels))
  6550. for k, _ := range this.Labels {
  6551. keysForLabels = append(keysForLabels, k)
  6552. }
  6553. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6554. mapStringForLabels := "map[string]string{"
  6555. for _, k := range keysForLabels {
  6556. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6557. }
  6558. mapStringForLabels += "}"
  6559. s := strings.Join([]string{`&ListServicesRequest_Filters{`,
  6560. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6561. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6562. `Labels:` + mapStringForLabels + `,`,
  6563. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6564. `}`,
  6565. }, "")
  6566. return s
  6567. }
  6568. func (this *ListServicesResponse) String() string {
  6569. if this == nil {
  6570. return "nil"
  6571. }
  6572. s := strings.Join([]string{`&ListServicesResponse{`,
  6573. `Services:` + strings.Replace(fmt.Sprintf("%v", this.Services), "Service", "Service", 1) + `,`,
  6574. `}`,
  6575. }, "")
  6576. return s
  6577. }
  6578. func (this *CreateNetworkRequest) String() string {
  6579. if this == nil {
  6580. return "nil"
  6581. }
  6582. s := strings.Join([]string{`&CreateNetworkRequest{`,
  6583. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "NetworkSpec", "NetworkSpec", 1) + `,`,
  6584. `}`,
  6585. }, "")
  6586. return s
  6587. }
  6588. func (this *CreateNetworkResponse) String() string {
  6589. if this == nil {
  6590. return "nil"
  6591. }
  6592. s := strings.Join([]string{`&CreateNetworkResponse{`,
  6593. `Network:` + strings.Replace(fmt.Sprintf("%v", this.Network), "Network", "Network", 1) + `,`,
  6594. `}`,
  6595. }, "")
  6596. return s
  6597. }
  6598. func (this *GetNetworkRequest) String() string {
  6599. if this == nil {
  6600. return "nil"
  6601. }
  6602. s := strings.Join([]string{`&GetNetworkRequest{`,
  6603. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  6604. `NetworkID:` + fmt.Sprintf("%v", this.NetworkID) + `,`,
  6605. `}`,
  6606. }, "")
  6607. return s
  6608. }
  6609. func (this *GetNetworkResponse) String() string {
  6610. if this == nil {
  6611. return "nil"
  6612. }
  6613. s := strings.Join([]string{`&GetNetworkResponse{`,
  6614. `Network:` + strings.Replace(fmt.Sprintf("%v", this.Network), "Network", "Network", 1) + `,`,
  6615. `}`,
  6616. }, "")
  6617. return s
  6618. }
  6619. func (this *RemoveNetworkRequest) String() string {
  6620. if this == nil {
  6621. return "nil"
  6622. }
  6623. s := strings.Join([]string{`&RemoveNetworkRequest{`,
  6624. `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
  6625. `NetworkID:` + fmt.Sprintf("%v", this.NetworkID) + `,`,
  6626. `}`,
  6627. }, "")
  6628. return s
  6629. }
  6630. func (this *RemoveNetworkResponse) String() string {
  6631. if this == nil {
  6632. return "nil"
  6633. }
  6634. s := strings.Join([]string{`&RemoveNetworkResponse{`,
  6635. `}`,
  6636. }, "")
  6637. return s
  6638. }
  6639. func (this *ListNetworksRequest) String() string {
  6640. if this == nil {
  6641. return "nil"
  6642. }
  6643. s := strings.Join([]string{`&ListNetworksRequest{`,
  6644. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListNetworksRequest_Filters", "ListNetworksRequest_Filters", 1) + `,`,
  6645. `}`,
  6646. }, "")
  6647. return s
  6648. }
  6649. func (this *ListNetworksRequest_Filters) String() string {
  6650. if this == nil {
  6651. return "nil"
  6652. }
  6653. keysForLabels := make([]string, 0, len(this.Labels))
  6654. for k, _ := range this.Labels {
  6655. keysForLabels = append(keysForLabels, k)
  6656. }
  6657. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6658. mapStringForLabels := "map[string]string{"
  6659. for _, k := range keysForLabels {
  6660. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6661. }
  6662. mapStringForLabels += "}"
  6663. s := strings.Join([]string{`&ListNetworksRequest_Filters{`,
  6664. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6665. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6666. `Labels:` + mapStringForLabels + `,`,
  6667. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6668. `}`,
  6669. }, "")
  6670. return s
  6671. }
  6672. func (this *ListNetworksResponse) String() string {
  6673. if this == nil {
  6674. return "nil"
  6675. }
  6676. s := strings.Join([]string{`&ListNetworksResponse{`,
  6677. `Networks:` + strings.Replace(fmt.Sprintf("%v", this.Networks), "Network", "Network", 1) + `,`,
  6678. `}`,
  6679. }, "")
  6680. return s
  6681. }
  6682. func (this *GetClusterRequest) String() string {
  6683. if this == nil {
  6684. return "nil"
  6685. }
  6686. s := strings.Join([]string{`&GetClusterRequest{`,
  6687. `ClusterID:` + fmt.Sprintf("%v", this.ClusterID) + `,`,
  6688. `}`,
  6689. }, "")
  6690. return s
  6691. }
  6692. func (this *GetClusterResponse) String() string {
  6693. if this == nil {
  6694. return "nil"
  6695. }
  6696. s := strings.Join([]string{`&GetClusterResponse{`,
  6697. `Cluster:` + strings.Replace(fmt.Sprintf("%v", this.Cluster), "Cluster", "Cluster", 1) + `,`,
  6698. `}`,
  6699. }, "")
  6700. return s
  6701. }
  6702. func (this *ListClustersRequest) String() string {
  6703. if this == nil {
  6704. return "nil"
  6705. }
  6706. s := strings.Join([]string{`&ListClustersRequest{`,
  6707. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListClustersRequest_Filters", "ListClustersRequest_Filters", 1) + `,`,
  6708. `}`,
  6709. }, "")
  6710. return s
  6711. }
  6712. func (this *ListClustersRequest_Filters) String() string {
  6713. if this == nil {
  6714. return "nil"
  6715. }
  6716. keysForLabels := make([]string, 0, len(this.Labels))
  6717. for k, _ := range this.Labels {
  6718. keysForLabels = append(keysForLabels, k)
  6719. }
  6720. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6721. mapStringForLabels := "map[string]string{"
  6722. for _, k := range keysForLabels {
  6723. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6724. }
  6725. mapStringForLabels += "}"
  6726. s := strings.Join([]string{`&ListClustersRequest_Filters{`,
  6727. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6728. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6729. `Labels:` + mapStringForLabels + `,`,
  6730. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6731. `}`,
  6732. }, "")
  6733. return s
  6734. }
  6735. func (this *ListClustersResponse) String() string {
  6736. if this == nil {
  6737. return "nil"
  6738. }
  6739. s := strings.Join([]string{`&ListClustersResponse{`,
  6740. `Clusters:` + strings.Replace(fmt.Sprintf("%v", this.Clusters), "Cluster", "Cluster", 1) + `,`,
  6741. `}`,
  6742. }, "")
  6743. return s
  6744. }
  6745. func (this *KeyRotation) String() string {
  6746. if this == nil {
  6747. return "nil"
  6748. }
  6749. s := strings.Join([]string{`&KeyRotation{`,
  6750. `WorkerJoinToken:` + fmt.Sprintf("%v", this.WorkerJoinToken) + `,`,
  6751. `ManagerJoinToken:` + fmt.Sprintf("%v", this.ManagerJoinToken) + `,`,
  6752. `ManagerUnlockKey:` + fmt.Sprintf("%v", this.ManagerUnlockKey) + `,`,
  6753. `}`,
  6754. }, "")
  6755. return s
  6756. }
  6757. func (this *UpdateClusterRequest) String() string {
  6758. if this == nil {
  6759. return "nil"
  6760. }
  6761. s := strings.Join([]string{`&UpdateClusterRequest{`,
  6762. `ClusterID:` + fmt.Sprintf("%v", this.ClusterID) + `,`,
  6763. `ClusterVersion:` + strings.Replace(fmt.Sprintf("%v", this.ClusterVersion), "Version", "Version", 1) + `,`,
  6764. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "ClusterSpec", "ClusterSpec", 1) + `,`,
  6765. `Rotation:` + strings.Replace(strings.Replace(this.Rotation.String(), "KeyRotation", "KeyRotation", 1), `&`, ``, 1) + `,`,
  6766. `}`,
  6767. }, "")
  6768. return s
  6769. }
  6770. func (this *UpdateClusterResponse) String() string {
  6771. if this == nil {
  6772. return "nil"
  6773. }
  6774. s := strings.Join([]string{`&UpdateClusterResponse{`,
  6775. `Cluster:` + strings.Replace(fmt.Sprintf("%v", this.Cluster), "Cluster", "Cluster", 1) + `,`,
  6776. `}`,
  6777. }, "")
  6778. return s
  6779. }
  6780. func (this *GetSecretRequest) String() string {
  6781. if this == nil {
  6782. return "nil"
  6783. }
  6784. s := strings.Join([]string{`&GetSecretRequest{`,
  6785. `SecretID:` + fmt.Sprintf("%v", this.SecretID) + `,`,
  6786. `}`,
  6787. }, "")
  6788. return s
  6789. }
  6790. func (this *GetSecretResponse) String() string {
  6791. if this == nil {
  6792. return "nil"
  6793. }
  6794. s := strings.Join([]string{`&GetSecretResponse{`,
  6795. `Secret:` + strings.Replace(fmt.Sprintf("%v", this.Secret), "Secret", "Secret", 1) + `,`,
  6796. `}`,
  6797. }, "")
  6798. return s
  6799. }
  6800. func (this *UpdateSecretRequest) String() string {
  6801. if this == nil {
  6802. return "nil"
  6803. }
  6804. s := strings.Join([]string{`&UpdateSecretRequest{`,
  6805. `SecretID:` + fmt.Sprintf("%v", this.SecretID) + `,`,
  6806. `SecretVersion:` + strings.Replace(fmt.Sprintf("%v", this.SecretVersion), "Version", "Version", 1) + `,`,
  6807. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "SecretSpec", "SecretSpec", 1) + `,`,
  6808. `}`,
  6809. }, "")
  6810. return s
  6811. }
  6812. func (this *UpdateSecretResponse) String() string {
  6813. if this == nil {
  6814. return "nil"
  6815. }
  6816. s := strings.Join([]string{`&UpdateSecretResponse{`,
  6817. `Secret:` + strings.Replace(fmt.Sprintf("%v", this.Secret), "Secret", "Secret", 1) + `,`,
  6818. `}`,
  6819. }, "")
  6820. return s
  6821. }
  6822. func (this *ListSecretsRequest) String() string {
  6823. if this == nil {
  6824. return "nil"
  6825. }
  6826. s := strings.Join([]string{`&ListSecretsRequest{`,
  6827. `Filters:` + strings.Replace(fmt.Sprintf("%v", this.Filters), "ListSecretsRequest_Filters", "ListSecretsRequest_Filters", 1) + `,`,
  6828. `}`,
  6829. }, "")
  6830. return s
  6831. }
  6832. func (this *ListSecretsRequest_Filters) String() string {
  6833. if this == nil {
  6834. return "nil"
  6835. }
  6836. keysForLabels := make([]string, 0, len(this.Labels))
  6837. for k, _ := range this.Labels {
  6838. keysForLabels = append(keysForLabels, k)
  6839. }
  6840. github_com_gogo_protobuf_sortkeys.Strings(keysForLabels)
  6841. mapStringForLabels := "map[string]string{"
  6842. for _, k := range keysForLabels {
  6843. mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k])
  6844. }
  6845. mapStringForLabels += "}"
  6846. s := strings.Join([]string{`&ListSecretsRequest_Filters{`,
  6847. `Names:` + fmt.Sprintf("%v", this.Names) + `,`,
  6848. `IDPrefixes:` + fmt.Sprintf("%v", this.IDPrefixes) + `,`,
  6849. `Labels:` + mapStringForLabels + `,`,
  6850. `NamePrefixes:` + fmt.Sprintf("%v", this.NamePrefixes) + `,`,
  6851. `}`,
  6852. }, "")
  6853. return s
  6854. }
  6855. func (this *ListSecretsResponse) String() string {
  6856. if this == nil {
  6857. return "nil"
  6858. }
  6859. s := strings.Join([]string{`&ListSecretsResponse{`,
  6860. `Secrets:` + strings.Replace(fmt.Sprintf("%v", this.Secrets), "Secret", "Secret", 1) + `,`,
  6861. `}`,
  6862. }, "")
  6863. return s
  6864. }
  6865. func (this *CreateSecretRequest) String() string {
  6866. if this == nil {
  6867. return "nil"
  6868. }
  6869. s := strings.Join([]string{`&CreateSecretRequest{`,
  6870. `Spec:` + strings.Replace(fmt.Sprintf("%v", this.Spec), "SecretSpec", "SecretSpec", 1) + `,`,
  6871. `}`,
  6872. }, "")
  6873. return s
  6874. }
  6875. func (this *CreateSecretResponse) String() string {
  6876. if this == nil {
  6877. return "nil"
  6878. }
  6879. s := strings.Join([]string{`&CreateSecretResponse{`,
  6880. `Secret:` + strings.Replace(fmt.Sprintf("%v", this.Secret), "Secret", "Secret", 1) + `,`,
  6881. `}`,
  6882. }, "")
  6883. return s
  6884. }
  6885. func (this *RemoveSecretRequest) String() string {
  6886. if this == nil {
  6887. return "nil"
  6888. }
  6889. s := strings.Join([]string{`&RemoveSecretRequest{`,
  6890. `SecretID:` + fmt.Sprintf("%v", this.SecretID) + `,`,
  6891. `}`,
  6892. }, "")
  6893. return s
  6894. }
  6895. func (this *RemoveSecretResponse) String() string {
  6896. if this == nil {
  6897. return "nil"
  6898. }
  6899. s := strings.Join([]string{`&RemoveSecretResponse{`,
  6900. `}`,
  6901. }, "")
  6902. return s
  6903. }
  6904. func valueToStringControl(v interface{}) string {
  6905. rv := reflect.ValueOf(v)
  6906. if rv.IsNil() {
  6907. return "nil"
  6908. }
  6909. pv := reflect.Indirect(rv).Interface()
  6910. return fmt.Sprintf("*%v", pv)
  6911. }
  6912. func (m *GetNodeRequest) Unmarshal(data []byte) error {
  6913. l := len(data)
  6914. iNdEx := 0
  6915. for iNdEx < l {
  6916. preIndex := iNdEx
  6917. var wire uint64
  6918. for shift := uint(0); ; shift += 7 {
  6919. if shift >= 64 {
  6920. return ErrIntOverflowControl
  6921. }
  6922. if iNdEx >= l {
  6923. return io.ErrUnexpectedEOF
  6924. }
  6925. b := data[iNdEx]
  6926. iNdEx++
  6927. wire |= (uint64(b) & 0x7F) << shift
  6928. if b < 0x80 {
  6929. break
  6930. }
  6931. }
  6932. fieldNum := int32(wire >> 3)
  6933. wireType := int(wire & 0x7)
  6934. if wireType == 4 {
  6935. return fmt.Errorf("proto: GetNodeRequest: wiretype end group for non-group")
  6936. }
  6937. if fieldNum <= 0 {
  6938. return fmt.Errorf("proto: GetNodeRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  6939. }
  6940. switch fieldNum {
  6941. case 1:
  6942. if wireType != 2 {
  6943. return fmt.Errorf("proto: wrong wireType = %d for field NodeID", wireType)
  6944. }
  6945. var stringLen uint64
  6946. for shift := uint(0); ; shift += 7 {
  6947. if shift >= 64 {
  6948. return ErrIntOverflowControl
  6949. }
  6950. if iNdEx >= l {
  6951. return io.ErrUnexpectedEOF
  6952. }
  6953. b := data[iNdEx]
  6954. iNdEx++
  6955. stringLen |= (uint64(b) & 0x7F) << shift
  6956. if b < 0x80 {
  6957. break
  6958. }
  6959. }
  6960. intStringLen := int(stringLen)
  6961. if intStringLen < 0 {
  6962. return ErrInvalidLengthControl
  6963. }
  6964. postIndex := iNdEx + intStringLen
  6965. if postIndex > l {
  6966. return io.ErrUnexpectedEOF
  6967. }
  6968. m.NodeID = string(data[iNdEx:postIndex])
  6969. iNdEx = postIndex
  6970. default:
  6971. iNdEx = preIndex
  6972. skippy, err := skipControl(data[iNdEx:])
  6973. if err != nil {
  6974. return err
  6975. }
  6976. if skippy < 0 {
  6977. return ErrInvalidLengthControl
  6978. }
  6979. if (iNdEx + skippy) > l {
  6980. return io.ErrUnexpectedEOF
  6981. }
  6982. iNdEx += skippy
  6983. }
  6984. }
  6985. if iNdEx > l {
  6986. return io.ErrUnexpectedEOF
  6987. }
  6988. return nil
  6989. }
  6990. func (m *GetNodeResponse) Unmarshal(data []byte) error {
  6991. l := len(data)
  6992. iNdEx := 0
  6993. for iNdEx < l {
  6994. preIndex := iNdEx
  6995. var wire uint64
  6996. for shift := uint(0); ; shift += 7 {
  6997. if shift >= 64 {
  6998. return ErrIntOverflowControl
  6999. }
  7000. if iNdEx >= l {
  7001. return io.ErrUnexpectedEOF
  7002. }
  7003. b := data[iNdEx]
  7004. iNdEx++
  7005. wire |= (uint64(b) & 0x7F) << shift
  7006. if b < 0x80 {
  7007. break
  7008. }
  7009. }
  7010. fieldNum := int32(wire >> 3)
  7011. wireType := int(wire & 0x7)
  7012. if wireType == 4 {
  7013. return fmt.Errorf("proto: GetNodeResponse: wiretype end group for non-group")
  7014. }
  7015. if fieldNum <= 0 {
  7016. return fmt.Errorf("proto: GetNodeResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  7017. }
  7018. switch fieldNum {
  7019. case 1:
  7020. if wireType != 2 {
  7021. return fmt.Errorf("proto: wrong wireType = %d for field Node", wireType)
  7022. }
  7023. var msglen int
  7024. for shift := uint(0); ; shift += 7 {
  7025. if shift >= 64 {
  7026. return ErrIntOverflowControl
  7027. }
  7028. if iNdEx >= l {
  7029. return io.ErrUnexpectedEOF
  7030. }
  7031. b := data[iNdEx]
  7032. iNdEx++
  7033. msglen |= (int(b) & 0x7F) << shift
  7034. if b < 0x80 {
  7035. break
  7036. }
  7037. }
  7038. if msglen < 0 {
  7039. return ErrInvalidLengthControl
  7040. }
  7041. postIndex := iNdEx + msglen
  7042. if postIndex > l {
  7043. return io.ErrUnexpectedEOF
  7044. }
  7045. if m.Node == nil {
  7046. m.Node = &Node{}
  7047. }
  7048. if err := m.Node.Unmarshal(data[iNdEx:postIndex]); err != nil {
  7049. return err
  7050. }
  7051. iNdEx = postIndex
  7052. default:
  7053. iNdEx = preIndex
  7054. skippy, err := skipControl(data[iNdEx:])
  7055. if err != nil {
  7056. return err
  7057. }
  7058. if skippy < 0 {
  7059. return ErrInvalidLengthControl
  7060. }
  7061. if (iNdEx + skippy) > l {
  7062. return io.ErrUnexpectedEOF
  7063. }
  7064. iNdEx += skippy
  7065. }
  7066. }
  7067. if iNdEx > l {
  7068. return io.ErrUnexpectedEOF
  7069. }
  7070. return nil
  7071. }
  7072. func (m *ListNodesRequest) Unmarshal(data []byte) error {
  7073. l := len(data)
  7074. iNdEx := 0
  7075. for iNdEx < l {
  7076. preIndex := iNdEx
  7077. var wire uint64
  7078. for shift := uint(0); ; shift += 7 {
  7079. if shift >= 64 {
  7080. return ErrIntOverflowControl
  7081. }
  7082. if iNdEx >= l {
  7083. return io.ErrUnexpectedEOF
  7084. }
  7085. b := data[iNdEx]
  7086. iNdEx++
  7087. wire |= (uint64(b) & 0x7F) << shift
  7088. if b < 0x80 {
  7089. break
  7090. }
  7091. }
  7092. fieldNum := int32(wire >> 3)
  7093. wireType := int(wire & 0x7)
  7094. if wireType == 4 {
  7095. return fmt.Errorf("proto: ListNodesRequest: wiretype end group for non-group")
  7096. }
  7097. if fieldNum <= 0 {
  7098. return fmt.Errorf("proto: ListNodesRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  7099. }
  7100. switch fieldNum {
  7101. case 1:
  7102. if wireType != 2 {
  7103. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  7104. }
  7105. var msglen int
  7106. for shift := uint(0); ; shift += 7 {
  7107. if shift >= 64 {
  7108. return ErrIntOverflowControl
  7109. }
  7110. if iNdEx >= l {
  7111. return io.ErrUnexpectedEOF
  7112. }
  7113. b := data[iNdEx]
  7114. iNdEx++
  7115. msglen |= (int(b) & 0x7F) << shift
  7116. if b < 0x80 {
  7117. break
  7118. }
  7119. }
  7120. if msglen < 0 {
  7121. return ErrInvalidLengthControl
  7122. }
  7123. postIndex := iNdEx + msglen
  7124. if postIndex > l {
  7125. return io.ErrUnexpectedEOF
  7126. }
  7127. if m.Filters == nil {
  7128. m.Filters = &ListNodesRequest_Filters{}
  7129. }
  7130. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  7131. return err
  7132. }
  7133. iNdEx = postIndex
  7134. default:
  7135. iNdEx = preIndex
  7136. skippy, err := skipControl(data[iNdEx:])
  7137. if err != nil {
  7138. return err
  7139. }
  7140. if skippy < 0 {
  7141. return ErrInvalidLengthControl
  7142. }
  7143. if (iNdEx + skippy) > l {
  7144. return io.ErrUnexpectedEOF
  7145. }
  7146. iNdEx += skippy
  7147. }
  7148. }
  7149. if iNdEx > l {
  7150. return io.ErrUnexpectedEOF
  7151. }
  7152. return nil
  7153. }
  7154. func (m *ListNodesRequest_Filters) Unmarshal(data []byte) error {
  7155. l := len(data)
  7156. iNdEx := 0
  7157. for iNdEx < l {
  7158. preIndex := iNdEx
  7159. var wire uint64
  7160. for shift := uint(0); ; shift += 7 {
  7161. if shift >= 64 {
  7162. return ErrIntOverflowControl
  7163. }
  7164. if iNdEx >= l {
  7165. return io.ErrUnexpectedEOF
  7166. }
  7167. b := data[iNdEx]
  7168. iNdEx++
  7169. wire |= (uint64(b) & 0x7F) << shift
  7170. if b < 0x80 {
  7171. break
  7172. }
  7173. }
  7174. fieldNum := int32(wire >> 3)
  7175. wireType := int(wire & 0x7)
  7176. if wireType == 4 {
  7177. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  7178. }
  7179. if fieldNum <= 0 {
  7180. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  7181. }
  7182. switch fieldNum {
  7183. case 1:
  7184. if wireType != 2 {
  7185. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  7186. }
  7187. var stringLen uint64
  7188. for shift := uint(0); ; shift += 7 {
  7189. if shift >= 64 {
  7190. return ErrIntOverflowControl
  7191. }
  7192. if iNdEx >= l {
  7193. return io.ErrUnexpectedEOF
  7194. }
  7195. b := data[iNdEx]
  7196. iNdEx++
  7197. stringLen |= (uint64(b) & 0x7F) << shift
  7198. if b < 0x80 {
  7199. break
  7200. }
  7201. }
  7202. intStringLen := int(stringLen)
  7203. if intStringLen < 0 {
  7204. return ErrInvalidLengthControl
  7205. }
  7206. postIndex := iNdEx + intStringLen
  7207. if postIndex > l {
  7208. return io.ErrUnexpectedEOF
  7209. }
  7210. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  7211. iNdEx = postIndex
  7212. case 2:
  7213. if wireType != 2 {
  7214. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  7215. }
  7216. var stringLen uint64
  7217. for shift := uint(0); ; shift += 7 {
  7218. if shift >= 64 {
  7219. return ErrIntOverflowControl
  7220. }
  7221. if iNdEx >= l {
  7222. return io.ErrUnexpectedEOF
  7223. }
  7224. b := data[iNdEx]
  7225. iNdEx++
  7226. stringLen |= (uint64(b) & 0x7F) << shift
  7227. if b < 0x80 {
  7228. break
  7229. }
  7230. }
  7231. intStringLen := int(stringLen)
  7232. if intStringLen < 0 {
  7233. return ErrInvalidLengthControl
  7234. }
  7235. postIndex := iNdEx + intStringLen
  7236. if postIndex > l {
  7237. return io.ErrUnexpectedEOF
  7238. }
  7239. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  7240. iNdEx = postIndex
  7241. case 3:
  7242. if wireType != 2 {
  7243. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  7244. }
  7245. var msglen int
  7246. for shift := uint(0); ; shift += 7 {
  7247. if shift >= 64 {
  7248. return ErrIntOverflowControl
  7249. }
  7250. if iNdEx >= l {
  7251. return io.ErrUnexpectedEOF
  7252. }
  7253. b := data[iNdEx]
  7254. iNdEx++
  7255. msglen |= (int(b) & 0x7F) << shift
  7256. if b < 0x80 {
  7257. break
  7258. }
  7259. }
  7260. if msglen < 0 {
  7261. return ErrInvalidLengthControl
  7262. }
  7263. postIndex := iNdEx + msglen
  7264. if postIndex > l {
  7265. return io.ErrUnexpectedEOF
  7266. }
  7267. var keykey uint64
  7268. for shift := uint(0); ; shift += 7 {
  7269. if shift >= 64 {
  7270. return ErrIntOverflowControl
  7271. }
  7272. if iNdEx >= l {
  7273. return io.ErrUnexpectedEOF
  7274. }
  7275. b := data[iNdEx]
  7276. iNdEx++
  7277. keykey |= (uint64(b) & 0x7F) << shift
  7278. if b < 0x80 {
  7279. break
  7280. }
  7281. }
  7282. var stringLenmapkey uint64
  7283. for shift := uint(0); ; shift += 7 {
  7284. if shift >= 64 {
  7285. return ErrIntOverflowControl
  7286. }
  7287. if iNdEx >= l {
  7288. return io.ErrUnexpectedEOF
  7289. }
  7290. b := data[iNdEx]
  7291. iNdEx++
  7292. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  7293. if b < 0x80 {
  7294. break
  7295. }
  7296. }
  7297. intStringLenmapkey := int(stringLenmapkey)
  7298. if intStringLenmapkey < 0 {
  7299. return ErrInvalidLengthControl
  7300. }
  7301. postStringIndexmapkey := iNdEx + intStringLenmapkey
  7302. if postStringIndexmapkey > l {
  7303. return io.ErrUnexpectedEOF
  7304. }
  7305. mapkey := string(data[iNdEx:postStringIndexmapkey])
  7306. iNdEx = postStringIndexmapkey
  7307. if m.Labels == nil {
  7308. m.Labels = make(map[string]string)
  7309. }
  7310. if iNdEx < postIndex {
  7311. var valuekey uint64
  7312. for shift := uint(0); ; shift += 7 {
  7313. if shift >= 64 {
  7314. return ErrIntOverflowControl
  7315. }
  7316. if iNdEx >= l {
  7317. return io.ErrUnexpectedEOF
  7318. }
  7319. b := data[iNdEx]
  7320. iNdEx++
  7321. valuekey |= (uint64(b) & 0x7F) << shift
  7322. if b < 0x80 {
  7323. break
  7324. }
  7325. }
  7326. var stringLenmapvalue uint64
  7327. for shift := uint(0); ; shift += 7 {
  7328. if shift >= 64 {
  7329. return ErrIntOverflowControl
  7330. }
  7331. if iNdEx >= l {
  7332. return io.ErrUnexpectedEOF
  7333. }
  7334. b := data[iNdEx]
  7335. iNdEx++
  7336. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  7337. if b < 0x80 {
  7338. break
  7339. }
  7340. }
  7341. intStringLenmapvalue := int(stringLenmapvalue)
  7342. if intStringLenmapvalue < 0 {
  7343. return ErrInvalidLengthControl
  7344. }
  7345. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  7346. if postStringIndexmapvalue > l {
  7347. return io.ErrUnexpectedEOF
  7348. }
  7349. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  7350. iNdEx = postStringIndexmapvalue
  7351. m.Labels[mapkey] = mapvalue
  7352. } else {
  7353. var mapvalue string
  7354. m.Labels[mapkey] = mapvalue
  7355. }
  7356. iNdEx = postIndex
  7357. case 4:
  7358. if wireType != 0 {
  7359. return fmt.Errorf("proto: wrong wireType = %d for field Memberships", wireType)
  7360. }
  7361. var v NodeSpec_Membership
  7362. for shift := uint(0); ; shift += 7 {
  7363. if shift >= 64 {
  7364. return ErrIntOverflowControl
  7365. }
  7366. if iNdEx >= l {
  7367. return io.ErrUnexpectedEOF
  7368. }
  7369. b := data[iNdEx]
  7370. iNdEx++
  7371. v |= (NodeSpec_Membership(b) & 0x7F) << shift
  7372. if b < 0x80 {
  7373. break
  7374. }
  7375. }
  7376. m.Memberships = append(m.Memberships, v)
  7377. case 5:
  7378. if wireType != 0 {
  7379. return fmt.Errorf("proto: wrong wireType = %d for field Roles", wireType)
  7380. }
  7381. var v NodeRole
  7382. for shift := uint(0); ; shift += 7 {
  7383. if shift >= 64 {
  7384. return ErrIntOverflowControl
  7385. }
  7386. if iNdEx >= l {
  7387. return io.ErrUnexpectedEOF
  7388. }
  7389. b := data[iNdEx]
  7390. iNdEx++
  7391. v |= (NodeRole(b) & 0x7F) << shift
  7392. if b < 0x80 {
  7393. break
  7394. }
  7395. }
  7396. m.Roles = append(m.Roles, v)
  7397. case 6:
  7398. if wireType != 2 {
  7399. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  7400. }
  7401. var stringLen uint64
  7402. for shift := uint(0); ; shift += 7 {
  7403. if shift >= 64 {
  7404. return ErrIntOverflowControl
  7405. }
  7406. if iNdEx >= l {
  7407. return io.ErrUnexpectedEOF
  7408. }
  7409. b := data[iNdEx]
  7410. iNdEx++
  7411. stringLen |= (uint64(b) & 0x7F) << shift
  7412. if b < 0x80 {
  7413. break
  7414. }
  7415. }
  7416. intStringLen := int(stringLen)
  7417. if intStringLen < 0 {
  7418. return ErrInvalidLengthControl
  7419. }
  7420. postIndex := iNdEx + intStringLen
  7421. if postIndex > l {
  7422. return io.ErrUnexpectedEOF
  7423. }
  7424. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  7425. iNdEx = postIndex
  7426. default:
  7427. iNdEx = preIndex
  7428. skippy, err := skipControl(data[iNdEx:])
  7429. if err != nil {
  7430. return err
  7431. }
  7432. if skippy < 0 {
  7433. return ErrInvalidLengthControl
  7434. }
  7435. if (iNdEx + skippy) > l {
  7436. return io.ErrUnexpectedEOF
  7437. }
  7438. iNdEx += skippy
  7439. }
  7440. }
  7441. if iNdEx > l {
  7442. return io.ErrUnexpectedEOF
  7443. }
  7444. return nil
  7445. }
  7446. func (m *ListNodesResponse) Unmarshal(data []byte) error {
  7447. l := len(data)
  7448. iNdEx := 0
  7449. for iNdEx < l {
  7450. preIndex := iNdEx
  7451. var wire uint64
  7452. for shift := uint(0); ; shift += 7 {
  7453. if shift >= 64 {
  7454. return ErrIntOverflowControl
  7455. }
  7456. if iNdEx >= l {
  7457. return io.ErrUnexpectedEOF
  7458. }
  7459. b := data[iNdEx]
  7460. iNdEx++
  7461. wire |= (uint64(b) & 0x7F) << shift
  7462. if b < 0x80 {
  7463. break
  7464. }
  7465. }
  7466. fieldNum := int32(wire >> 3)
  7467. wireType := int(wire & 0x7)
  7468. if wireType == 4 {
  7469. return fmt.Errorf("proto: ListNodesResponse: wiretype end group for non-group")
  7470. }
  7471. if fieldNum <= 0 {
  7472. return fmt.Errorf("proto: ListNodesResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  7473. }
  7474. switch fieldNum {
  7475. case 1:
  7476. if wireType != 2 {
  7477. return fmt.Errorf("proto: wrong wireType = %d for field Nodes", wireType)
  7478. }
  7479. var msglen int
  7480. for shift := uint(0); ; shift += 7 {
  7481. if shift >= 64 {
  7482. return ErrIntOverflowControl
  7483. }
  7484. if iNdEx >= l {
  7485. return io.ErrUnexpectedEOF
  7486. }
  7487. b := data[iNdEx]
  7488. iNdEx++
  7489. msglen |= (int(b) & 0x7F) << shift
  7490. if b < 0x80 {
  7491. break
  7492. }
  7493. }
  7494. if msglen < 0 {
  7495. return ErrInvalidLengthControl
  7496. }
  7497. postIndex := iNdEx + msglen
  7498. if postIndex > l {
  7499. return io.ErrUnexpectedEOF
  7500. }
  7501. m.Nodes = append(m.Nodes, &Node{})
  7502. if err := m.Nodes[len(m.Nodes)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  7503. return err
  7504. }
  7505. iNdEx = postIndex
  7506. default:
  7507. iNdEx = preIndex
  7508. skippy, err := skipControl(data[iNdEx:])
  7509. if err != nil {
  7510. return err
  7511. }
  7512. if skippy < 0 {
  7513. return ErrInvalidLengthControl
  7514. }
  7515. if (iNdEx + skippy) > l {
  7516. return io.ErrUnexpectedEOF
  7517. }
  7518. iNdEx += skippy
  7519. }
  7520. }
  7521. if iNdEx > l {
  7522. return io.ErrUnexpectedEOF
  7523. }
  7524. return nil
  7525. }
  7526. func (m *UpdateNodeRequest) Unmarshal(data []byte) error {
  7527. l := len(data)
  7528. iNdEx := 0
  7529. for iNdEx < l {
  7530. preIndex := iNdEx
  7531. var wire uint64
  7532. for shift := uint(0); ; shift += 7 {
  7533. if shift >= 64 {
  7534. return ErrIntOverflowControl
  7535. }
  7536. if iNdEx >= l {
  7537. return io.ErrUnexpectedEOF
  7538. }
  7539. b := data[iNdEx]
  7540. iNdEx++
  7541. wire |= (uint64(b) & 0x7F) << shift
  7542. if b < 0x80 {
  7543. break
  7544. }
  7545. }
  7546. fieldNum := int32(wire >> 3)
  7547. wireType := int(wire & 0x7)
  7548. if wireType == 4 {
  7549. return fmt.Errorf("proto: UpdateNodeRequest: wiretype end group for non-group")
  7550. }
  7551. if fieldNum <= 0 {
  7552. return fmt.Errorf("proto: UpdateNodeRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  7553. }
  7554. switch fieldNum {
  7555. case 1:
  7556. if wireType != 2 {
  7557. return fmt.Errorf("proto: wrong wireType = %d for field NodeID", wireType)
  7558. }
  7559. var stringLen uint64
  7560. for shift := uint(0); ; shift += 7 {
  7561. if shift >= 64 {
  7562. return ErrIntOverflowControl
  7563. }
  7564. if iNdEx >= l {
  7565. return io.ErrUnexpectedEOF
  7566. }
  7567. b := data[iNdEx]
  7568. iNdEx++
  7569. stringLen |= (uint64(b) & 0x7F) << shift
  7570. if b < 0x80 {
  7571. break
  7572. }
  7573. }
  7574. intStringLen := int(stringLen)
  7575. if intStringLen < 0 {
  7576. return ErrInvalidLengthControl
  7577. }
  7578. postIndex := iNdEx + intStringLen
  7579. if postIndex > l {
  7580. return io.ErrUnexpectedEOF
  7581. }
  7582. m.NodeID = string(data[iNdEx:postIndex])
  7583. iNdEx = postIndex
  7584. case 2:
  7585. if wireType != 2 {
  7586. return fmt.Errorf("proto: wrong wireType = %d for field NodeVersion", wireType)
  7587. }
  7588. var msglen int
  7589. for shift := uint(0); ; shift += 7 {
  7590. if shift >= 64 {
  7591. return ErrIntOverflowControl
  7592. }
  7593. if iNdEx >= l {
  7594. return io.ErrUnexpectedEOF
  7595. }
  7596. b := data[iNdEx]
  7597. iNdEx++
  7598. msglen |= (int(b) & 0x7F) << shift
  7599. if b < 0x80 {
  7600. break
  7601. }
  7602. }
  7603. if msglen < 0 {
  7604. return ErrInvalidLengthControl
  7605. }
  7606. postIndex := iNdEx + msglen
  7607. if postIndex > l {
  7608. return io.ErrUnexpectedEOF
  7609. }
  7610. if m.NodeVersion == nil {
  7611. m.NodeVersion = &Version{}
  7612. }
  7613. if err := m.NodeVersion.Unmarshal(data[iNdEx:postIndex]); err != nil {
  7614. return err
  7615. }
  7616. iNdEx = postIndex
  7617. case 3:
  7618. if wireType != 2 {
  7619. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  7620. }
  7621. var msglen int
  7622. for shift := uint(0); ; shift += 7 {
  7623. if shift >= 64 {
  7624. return ErrIntOverflowControl
  7625. }
  7626. if iNdEx >= l {
  7627. return io.ErrUnexpectedEOF
  7628. }
  7629. b := data[iNdEx]
  7630. iNdEx++
  7631. msglen |= (int(b) & 0x7F) << shift
  7632. if b < 0x80 {
  7633. break
  7634. }
  7635. }
  7636. if msglen < 0 {
  7637. return ErrInvalidLengthControl
  7638. }
  7639. postIndex := iNdEx + msglen
  7640. if postIndex > l {
  7641. return io.ErrUnexpectedEOF
  7642. }
  7643. if m.Spec == nil {
  7644. m.Spec = &NodeSpec{}
  7645. }
  7646. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  7647. return err
  7648. }
  7649. iNdEx = postIndex
  7650. default:
  7651. iNdEx = preIndex
  7652. skippy, err := skipControl(data[iNdEx:])
  7653. if err != nil {
  7654. return err
  7655. }
  7656. if skippy < 0 {
  7657. return ErrInvalidLengthControl
  7658. }
  7659. if (iNdEx + skippy) > l {
  7660. return io.ErrUnexpectedEOF
  7661. }
  7662. iNdEx += skippy
  7663. }
  7664. }
  7665. if iNdEx > l {
  7666. return io.ErrUnexpectedEOF
  7667. }
  7668. return nil
  7669. }
  7670. func (m *UpdateNodeResponse) Unmarshal(data []byte) error {
  7671. l := len(data)
  7672. iNdEx := 0
  7673. for iNdEx < l {
  7674. preIndex := iNdEx
  7675. var wire uint64
  7676. for shift := uint(0); ; shift += 7 {
  7677. if shift >= 64 {
  7678. return ErrIntOverflowControl
  7679. }
  7680. if iNdEx >= l {
  7681. return io.ErrUnexpectedEOF
  7682. }
  7683. b := data[iNdEx]
  7684. iNdEx++
  7685. wire |= (uint64(b) & 0x7F) << shift
  7686. if b < 0x80 {
  7687. break
  7688. }
  7689. }
  7690. fieldNum := int32(wire >> 3)
  7691. wireType := int(wire & 0x7)
  7692. if wireType == 4 {
  7693. return fmt.Errorf("proto: UpdateNodeResponse: wiretype end group for non-group")
  7694. }
  7695. if fieldNum <= 0 {
  7696. return fmt.Errorf("proto: UpdateNodeResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  7697. }
  7698. switch fieldNum {
  7699. case 1:
  7700. if wireType != 2 {
  7701. return fmt.Errorf("proto: wrong wireType = %d for field Node", wireType)
  7702. }
  7703. var msglen int
  7704. for shift := uint(0); ; shift += 7 {
  7705. if shift >= 64 {
  7706. return ErrIntOverflowControl
  7707. }
  7708. if iNdEx >= l {
  7709. return io.ErrUnexpectedEOF
  7710. }
  7711. b := data[iNdEx]
  7712. iNdEx++
  7713. msglen |= (int(b) & 0x7F) << shift
  7714. if b < 0x80 {
  7715. break
  7716. }
  7717. }
  7718. if msglen < 0 {
  7719. return ErrInvalidLengthControl
  7720. }
  7721. postIndex := iNdEx + msglen
  7722. if postIndex > l {
  7723. return io.ErrUnexpectedEOF
  7724. }
  7725. if m.Node == nil {
  7726. m.Node = &Node{}
  7727. }
  7728. if err := m.Node.Unmarshal(data[iNdEx:postIndex]); err != nil {
  7729. return err
  7730. }
  7731. iNdEx = postIndex
  7732. default:
  7733. iNdEx = preIndex
  7734. skippy, err := skipControl(data[iNdEx:])
  7735. if err != nil {
  7736. return err
  7737. }
  7738. if skippy < 0 {
  7739. return ErrInvalidLengthControl
  7740. }
  7741. if (iNdEx + skippy) > l {
  7742. return io.ErrUnexpectedEOF
  7743. }
  7744. iNdEx += skippy
  7745. }
  7746. }
  7747. if iNdEx > l {
  7748. return io.ErrUnexpectedEOF
  7749. }
  7750. return nil
  7751. }
  7752. func (m *RemoveNodeRequest) Unmarshal(data []byte) error {
  7753. l := len(data)
  7754. iNdEx := 0
  7755. for iNdEx < l {
  7756. preIndex := iNdEx
  7757. var wire uint64
  7758. for shift := uint(0); ; shift += 7 {
  7759. if shift >= 64 {
  7760. return ErrIntOverflowControl
  7761. }
  7762. if iNdEx >= l {
  7763. return io.ErrUnexpectedEOF
  7764. }
  7765. b := data[iNdEx]
  7766. iNdEx++
  7767. wire |= (uint64(b) & 0x7F) << shift
  7768. if b < 0x80 {
  7769. break
  7770. }
  7771. }
  7772. fieldNum := int32(wire >> 3)
  7773. wireType := int(wire & 0x7)
  7774. if wireType == 4 {
  7775. return fmt.Errorf("proto: RemoveNodeRequest: wiretype end group for non-group")
  7776. }
  7777. if fieldNum <= 0 {
  7778. return fmt.Errorf("proto: RemoveNodeRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  7779. }
  7780. switch fieldNum {
  7781. case 1:
  7782. if wireType != 2 {
  7783. return fmt.Errorf("proto: wrong wireType = %d for field NodeID", wireType)
  7784. }
  7785. var stringLen uint64
  7786. for shift := uint(0); ; shift += 7 {
  7787. if shift >= 64 {
  7788. return ErrIntOverflowControl
  7789. }
  7790. if iNdEx >= l {
  7791. return io.ErrUnexpectedEOF
  7792. }
  7793. b := data[iNdEx]
  7794. iNdEx++
  7795. stringLen |= (uint64(b) & 0x7F) << shift
  7796. if b < 0x80 {
  7797. break
  7798. }
  7799. }
  7800. intStringLen := int(stringLen)
  7801. if intStringLen < 0 {
  7802. return ErrInvalidLengthControl
  7803. }
  7804. postIndex := iNdEx + intStringLen
  7805. if postIndex > l {
  7806. return io.ErrUnexpectedEOF
  7807. }
  7808. m.NodeID = string(data[iNdEx:postIndex])
  7809. iNdEx = postIndex
  7810. case 2:
  7811. if wireType != 0 {
  7812. return fmt.Errorf("proto: wrong wireType = %d for field Force", wireType)
  7813. }
  7814. var v int
  7815. for shift := uint(0); ; shift += 7 {
  7816. if shift >= 64 {
  7817. return ErrIntOverflowControl
  7818. }
  7819. if iNdEx >= l {
  7820. return io.ErrUnexpectedEOF
  7821. }
  7822. b := data[iNdEx]
  7823. iNdEx++
  7824. v |= (int(b) & 0x7F) << shift
  7825. if b < 0x80 {
  7826. break
  7827. }
  7828. }
  7829. m.Force = bool(v != 0)
  7830. default:
  7831. iNdEx = preIndex
  7832. skippy, err := skipControl(data[iNdEx:])
  7833. if err != nil {
  7834. return err
  7835. }
  7836. if skippy < 0 {
  7837. return ErrInvalidLengthControl
  7838. }
  7839. if (iNdEx + skippy) > l {
  7840. return io.ErrUnexpectedEOF
  7841. }
  7842. iNdEx += skippy
  7843. }
  7844. }
  7845. if iNdEx > l {
  7846. return io.ErrUnexpectedEOF
  7847. }
  7848. return nil
  7849. }
  7850. func (m *RemoveNodeResponse) Unmarshal(data []byte) error {
  7851. l := len(data)
  7852. iNdEx := 0
  7853. for iNdEx < l {
  7854. preIndex := iNdEx
  7855. var wire uint64
  7856. for shift := uint(0); ; shift += 7 {
  7857. if shift >= 64 {
  7858. return ErrIntOverflowControl
  7859. }
  7860. if iNdEx >= l {
  7861. return io.ErrUnexpectedEOF
  7862. }
  7863. b := data[iNdEx]
  7864. iNdEx++
  7865. wire |= (uint64(b) & 0x7F) << shift
  7866. if b < 0x80 {
  7867. break
  7868. }
  7869. }
  7870. fieldNum := int32(wire >> 3)
  7871. wireType := int(wire & 0x7)
  7872. if wireType == 4 {
  7873. return fmt.Errorf("proto: RemoveNodeResponse: wiretype end group for non-group")
  7874. }
  7875. if fieldNum <= 0 {
  7876. return fmt.Errorf("proto: RemoveNodeResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  7877. }
  7878. switch fieldNum {
  7879. default:
  7880. iNdEx = preIndex
  7881. skippy, err := skipControl(data[iNdEx:])
  7882. if err != nil {
  7883. return err
  7884. }
  7885. if skippy < 0 {
  7886. return ErrInvalidLengthControl
  7887. }
  7888. if (iNdEx + skippy) > l {
  7889. return io.ErrUnexpectedEOF
  7890. }
  7891. iNdEx += skippy
  7892. }
  7893. }
  7894. if iNdEx > l {
  7895. return io.ErrUnexpectedEOF
  7896. }
  7897. return nil
  7898. }
  7899. func (m *GetTaskRequest) Unmarshal(data []byte) error {
  7900. l := len(data)
  7901. iNdEx := 0
  7902. for iNdEx < l {
  7903. preIndex := iNdEx
  7904. var wire uint64
  7905. for shift := uint(0); ; shift += 7 {
  7906. if shift >= 64 {
  7907. return ErrIntOverflowControl
  7908. }
  7909. if iNdEx >= l {
  7910. return io.ErrUnexpectedEOF
  7911. }
  7912. b := data[iNdEx]
  7913. iNdEx++
  7914. wire |= (uint64(b) & 0x7F) << shift
  7915. if b < 0x80 {
  7916. break
  7917. }
  7918. }
  7919. fieldNum := int32(wire >> 3)
  7920. wireType := int(wire & 0x7)
  7921. if wireType == 4 {
  7922. return fmt.Errorf("proto: GetTaskRequest: wiretype end group for non-group")
  7923. }
  7924. if fieldNum <= 0 {
  7925. return fmt.Errorf("proto: GetTaskRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  7926. }
  7927. switch fieldNum {
  7928. case 1:
  7929. if wireType != 2 {
  7930. return fmt.Errorf("proto: wrong wireType = %d for field TaskID", wireType)
  7931. }
  7932. var stringLen uint64
  7933. for shift := uint(0); ; shift += 7 {
  7934. if shift >= 64 {
  7935. return ErrIntOverflowControl
  7936. }
  7937. if iNdEx >= l {
  7938. return io.ErrUnexpectedEOF
  7939. }
  7940. b := data[iNdEx]
  7941. iNdEx++
  7942. stringLen |= (uint64(b) & 0x7F) << shift
  7943. if b < 0x80 {
  7944. break
  7945. }
  7946. }
  7947. intStringLen := int(stringLen)
  7948. if intStringLen < 0 {
  7949. return ErrInvalidLengthControl
  7950. }
  7951. postIndex := iNdEx + intStringLen
  7952. if postIndex > l {
  7953. return io.ErrUnexpectedEOF
  7954. }
  7955. m.TaskID = string(data[iNdEx:postIndex])
  7956. iNdEx = postIndex
  7957. default:
  7958. iNdEx = preIndex
  7959. skippy, err := skipControl(data[iNdEx:])
  7960. if err != nil {
  7961. return err
  7962. }
  7963. if skippy < 0 {
  7964. return ErrInvalidLengthControl
  7965. }
  7966. if (iNdEx + skippy) > l {
  7967. return io.ErrUnexpectedEOF
  7968. }
  7969. iNdEx += skippy
  7970. }
  7971. }
  7972. if iNdEx > l {
  7973. return io.ErrUnexpectedEOF
  7974. }
  7975. return nil
  7976. }
  7977. func (m *GetTaskResponse) Unmarshal(data []byte) error {
  7978. l := len(data)
  7979. iNdEx := 0
  7980. for iNdEx < l {
  7981. preIndex := iNdEx
  7982. var wire uint64
  7983. for shift := uint(0); ; shift += 7 {
  7984. if shift >= 64 {
  7985. return ErrIntOverflowControl
  7986. }
  7987. if iNdEx >= l {
  7988. return io.ErrUnexpectedEOF
  7989. }
  7990. b := data[iNdEx]
  7991. iNdEx++
  7992. wire |= (uint64(b) & 0x7F) << shift
  7993. if b < 0x80 {
  7994. break
  7995. }
  7996. }
  7997. fieldNum := int32(wire >> 3)
  7998. wireType := int(wire & 0x7)
  7999. if wireType == 4 {
  8000. return fmt.Errorf("proto: GetTaskResponse: wiretype end group for non-group")
  8001. }
  8002. if fieldNum <= 0 {
  8003. return fmt.Errorf("proto: GetTaskResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  8004. }
  8005. switch fieldNum {
  8006. case 1:
  8007. if wireType != 2 {
  8008. return fmt.Errorf("proto: wrong wireType = %d for field Task", wireType)
  8009. }
  8010. var msglen int
  8011. for shift := uint(0); ; shift += 7 {
  8012. if shift >= 64 {
  8013. return ErrIntOverflowControl
  8014. }
  8015. if iNdEx >= l {
  8016. return io.ErrUnexpectedEOF
  8017. }
  8018. b := data[iNdEx]
  8019. iNdEx++
  8020. msglen |= (int(b) & 0x7F) << shift
  8021. if b < 0x80 {
  8022. break
  8023. }
  8024. }
  8025. if msglen < 0 {
  8026. return ErrInvalidLengthControl
  8027. }
  8028. postIndex := iNdEx + msglen
  8029. if postIndex > l {
  8030. return io.ErrUnexpectedEOF
  8031. }
  8032. if m.Task == nil {
  8033. m.Task = &Task{}
  8034. }
  8035. if err := m.Task.Unmarshal(data[iNdEx:postIndex]); err != nil {
  8036. return err
  8037. }
  8038. iNdEx = postIndex
  8039. default:
  8040. iNdEx = preIndex
  8041. skippy, err := skipControl(data[iNdEx:])
  8042. if err != nil {
  8043. return err
  8044. }
  8045. if skippy < 0 {
  8046. return ErrInvalidLengthControl
  8047. }
  8048. if (iNdEx + skippy) > l {
  8049. return io.ErrUnexpectedEOF
  8050. }
  8051. iNdEx += skippy
  8052. }
  8053. }
  8054. if iNdEx > l {
  8055. return io.ErrUnexpectedEOF
  8056. }
  8057. return nil
  8058. }
  8059. func (m *RemoveTaskRequest) Unmarshal(data []byte) error {
  8060. l := len(data)
  8061. iNdEx := 0
  8062. for iNdEx < l {
  8063. preIndex := iNdEx
  8064. var wire uint64
  8065. for shift := uint(0); ; shift += 7 {
  8066. if shift >= 64 {
  8067. return ErrIntOverflowControl
  8068. }
  8069. if iNdEx >= l {
  8070. return io.ErrUnexpectedEOF
  8071. }
  8072. b := data[iNdEx]
  8073. iNdEx++
  8074. wire |= (uint64(b) & 0x7F) << shift
  8075. if b < 0x80 {
  8076. break
  8077. }
  8078. }
  8079. fieldNum := int32(wire >> 3)
  8080. wireType := int(wire & 0x7)
  8081. if wireType == 4 {
  8082. return fmt.Errorf("proto: RemoveTaskRequest: wiretype end group for non-group")
  8083. }
  8084. if fieldNum <= 0 {
  8085. return fmt.Errorf("proto: RemoveTaskRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  8086. }
  8087. switch fieldNum {
  8088. case 1:
  8089. if wireType != 2 {
  8090. return fmt.Errorf("proto: wrong wireType = %d for field TaskID", wireType)
  8091. }
  8092. var stringLen uint64
  8093. for shift := uint(0); ; shift += 7 {
  8094. if shift >= 64 {
  8095. return ErrIntOverflowControl
  8096. }
  8097. if iNdEx >= l {
  8098. return io.ErrUnexpectedEOF
  8099. }
  8100. b := data[iNdEx]
  8101. iNdEx++
  8102. stringLen |= (uint64(b) & 0x7F) << shift
  8103. if b < 0x80 {
  8104. break
  8105. }
  8106. }
  8107. intStringLen := int(stringLen)
  8108. if intStringLen < 0 {
  8109. return ErrInvalidLengthControl
  8110. }
  8111. postIndex := iNdEx + intStringLen
  8112. if postIndex > l {
  8113. return io.ErrUnexpectedEOF
  8114. }
  8115. m.TaskID = string(data[iNdEx:postIndex])
  8116. iNdEx = postIndex
  8117. default:
  8118. iNdEx = preIndex
  8119. skippy, err := skipControl(data[iNdEx:])
  8120. if err != nil {
  8121. return err
  8122. }
  8123. if skippy < 0 {
  8124. return ErrInvalidLengthControl
  8125. }
  8126. if (iNdEx + skippy) > l {
  8127. return io.ErrUnexpectedEOF
  8128. }
  8129. iNdEx += skippy
  8130. }
  8131. }
  8132. if iNdEx > l {
  8133. return io.ErrUnexpectedEOF
  8134. }
  8135. return nil
  8136. }
  8137. func (m *RemoveTaskResponse) Unmarshal(data []byte) error {
  8138. l := len(data)
  8139. iNdEx := 0
  8140. for iNdEx < l {
  8141. preIndex := iNdEx
  8142. var wire uint64
  8143. for shift := uint(0); ; shift += 7 {
  8144. if shift >= 64 {
  8145. return ErrIntOverflowControl
  8146. }
  8147. if iNdEx >= l {
  8148. return io.ErrUnexpectedEOF
  8149. }
  8150. b := data[iNdEx]
  8151. iNdEx++
  8152. wire |= (uint64(b) & 0x7F) << shift
  8153. if b < 0x80 {
  8154. break
  8155. }
  8156. }
  8157. fieldNum := int32(wire >> 3)
  8158. wireType := int(wire & 0x7)
  8159. if wireType == 4 {
  8160. return fmt.Errorf("proto: RemoveTaskResponse: wiretype end group for non-group")
  8161. }
  8162. if fieldNum <= 0 {
  8163. return fmt.Errorf("proto: RemoveTaskResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  8164. }
  8165. switch fieldNum {
  8166. default:
  8167. iNdEx = preIndex
  8168. skippy, err := skipControl(data[iNdEx:])
  8169. if err != nil {
  8170. return err
  8171. }
  8172. if skippy < 0 {
  8173. return ErrInvalidLengthControl
  8174. }
  8175. if (iNdEx + skippy) > l {
  8176. return io.ErrUnexpectedEOF
  8177. }
  8178. iNdEx += skippy
  8179. }
  8180. }
  8181. if iNdEx > l {
  8182. return io.ErrUnexpectedEOF
  8183. }
  8184. return nil
  8185. }
  8186. func (m *ListTasksRequest) Unmarshal(data []byte) error {
  8187. l := len(data)
  8188. iNdEx := 0
  8189. for iNdEx < l {
  8190. preIndex := iNdEx
  8191. var wire uint64
  8192. for shift := uint(0); ; shift += 7 {
  8193. if shift >= 64 {
  8194. return ErrIntOverflowControl
  8195. }
  8196. if iNdEx >= l {
  8197. return io.ErrUnexpectedEOF
  8198. }
  8199. b := data[iNdEx]
  8200. iNdEx++
  8201. wire |= (uint64(b) & 0x7F) << shift
  8202. if b < 0x80 {
  8203. break
  8204. }
  8205. }
  8206. fieldNum := int32(wire >> 3)
  8207. wireType := int(wire & 0x7)
  8208. if wireType == 4 {
  8209. return fmt.Errorf("proto: ListTasksRequest: wiretype end group for non-group")
  8210. }
  8211. if fieldNum <= 0 {
  8212. return fmt.Errorf("proto: ListTasksRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  8213. }
  8214. switch fieldNum {
  8215. case 1:
  8216. if wireType != 2 {
  8217. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  8218. }
  8219. var msglen int
  8220. for shift := uint(0); ; shift += 7 {
  8221. if shift >= 64 {
  8222. return ErrIntOverflowControl
  8223. }
  8224. if iNdEx >= l {
  8225. return io.ErrUnexpectedEOF
  8226. }
  8227. b := data[iNdEx]
  8228. iNdEx++
  8229. msglen |= (int(b) & 0x7F) << shift
  8230. if b < 0x80 {
  8231. break
  8232. }
  8233. }
  8234. if msglen < 0 {
  8235. return ErrInvalidLengthControl
  8236. }
  8237. postIndex := iNdEx + msglen
  8238. if postIndex > l {
  8239. return io.ErrUnexpectedEOF
  8240. }
  8241. if m.Filters == nil {
  8242. m.Filters = &ListTasksRequest_Filters{}
  8243. }
  8244. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  8245. return err
  8246. }
  8247. iNdEx = postIndex
  8248. default:
  8249. iNdEx = preIndex
  8250. skippy, err := skipControl(data[iNdEx:])
  8251. if err != nil {
  8252. return err
  8253. }
  8254. if skippy < 0 {
  8255. return ErrInvalidLengthControl
  8256. }
  8257. if (iNdEx + skippy) > l {
  8258. return io.ErrUnexpectedEOF
  8259. }
  8260. iNdEx += skippy
  8261. }
  8262. }
  8263. if iNdEx > l {
  8264. return io.ErrUnexpectedEOF
  8265. }
  8266. return nil
  8267. }
  8268. func (m *ListTasksRequest_Filters) Unmarshal(data []byte) error {
  8269. l := len(data)
  8270. iNdEx := 0
  8271. for iNdEx < l {
  8272. preIndex := iNdEx
  8273. var wire uint64
  8274. for shift := uint(0); ; shift += 7 {
  8275. if shift >= 64 {
  8276. return ErrIntOverflowControl
  8277. }
  8278. if iNdEx >= l {
  8279. return io.ErrUnexpectedEOF
  8280. }
  8281. b := data[iNdEx]
  8282. iNdEx++
  8283. wire |= (uint64(b) & 0x7F) << shift
  8284. if b < 0x80 {
  8285. break
  8286. }
  8287. }
  8288. fieldNum := int32(wire >> 3)
  8289. wireType := int(wire & 0x7)
  8290. if wireType == 4 {
  8291. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  8292. }
  8293. if fieldNum <= 0 {
  8294. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  8295. }
  8296. switch fieldNum {
  8297. case 1:
  8298. if wireType != 2 {
  8299. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  8300. }
  8301. var stringLen uint64
  8302. for shift := uint(0); ; shift += 7 {
  8303. if shift >= 64 {
  8304. return ErrIntOverflowControl
  8305. }
  8306. if iNdEx >= l {
  8307. return io.ErrUnexpectedEOF
  8308. }
  8309. b := data[iNdEx]
  8310. iNdEx++
  8311. stringLen |= (uint64(b) & 0x7F) << shift
  8312. if b < 0x80 {
  8313. break
  8314. }
  8315. }
  8316. intStringLen := int(stringLen)
  8317. if intStringLen < 0 {
  8318. return ErrInvalidLengthControl
  8319. }
  8320. postIndex := iNdEx + intStringLen
  8321. if postIndex > l {
  8322. return io.ErrUnexpectedEOF
  8323. }
  8324. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  8325. iNdEx = postIndex
  8326. case 2:
  8327. if wireType != 2 {
  8328. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  8329. }
  8330. var stringLen uint64
  8331. for shift := uint(0); ; shift += 7 {
  8332. if shift >= 64 {
  8333. return ErrIntOverflowControl
  8334. }
  8335. if iNdEx >= l {
  8336. return io.ErrUnexpectedEOF
  8337. }
  8338. b := data[iNdEx]
  8339. iNdEx++
  8340. stringLen |= (uint64(b) & 0x7F) << shift
  8341. if b < 0x80 {
  8342. break
  8343. }
  8344. }
  8345. intStringLen := int(stringLen)
  8346. if intStringLen < 0 {
  8347. return ErrInvalidLengthControl
  8348. }
  8349. postIndex := iNdEx + intStringLen
  8350. if postIndex > l {
  8351. return io.ErrUnexpectedEOF
  8352. }
  8353. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  8354. iNdEx = postIndex
  8355. case 3:
  8356. if wireType != 2 {
  8357. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  8358. }
  8359. var msglen int
  8360. for shift := uint(0); ; shift += 7 {
  8361. if shift >= 64 {
  8362. return ErrIntOverflowControl
  8363. }
  8364. if iNdEx >= l {
  8365. return io.ErrUnexpectedEOF
  8366. }
  8367. b := data[iNdEx]
  8368. iNdEx++
  8369. msglen |= (int(b) & 0x7F) << shift
  8370. if b < 0x80 {
  8371. break
  8372. }
  8373. }
  8374. if msglen < 0 {
  8375. return ErrInvalidLengthControl
  8376. }
  8377. postIndex := iNdEx + msglen
  8378. if postIndex > l {
  8379. return io.ErrUnexpectedEOF
  8380. }
  8381. var keykey uint64
  8382. for shift := uint(0); ; shift += 7 {
  8383. if shift >= 64 {
  8384. return ErrIntOverflowControl
  8385. }
  8386. if iNdEx >= l {
  8387. return io.ErrUnexpectedEOF
  8388. }
  8389. b := data[iNdEx]
  8390. iNdEx++
  8391. keykey |= (uint64(b) & 0x7F) << shift
  8392. if b < 0x80 {
  8393. break
  8394. }
  8395. }
  8396. var stringLenmapkey uint64
  8397. for shift := uint(0); ; shift += 7 {
  8398. if shift >= 64 {
  8399. return ErrIntOverflowControl
  8400. }
  8401. if iNdEx >= l {
  8402. return io.ErrUnexpectedEOF
  8403. }
  8404. b := data[iNdEx]
  8405. iNdEx++
  8406. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  8407. if b < 0x80 {
  8408. break
  8409. }
  8410. }
  8411. intStringLenmapkey := int(stringLenmapkey)
  8412. if intStringLenmapkey < 0 {
  8413. return ErrInvalidLengthControl
  8414. }
  8415. postStringIndexmapkey := iNdEx + intStringLenmapkey
  8416. if postStringIndexmapkey > l {
  8417. return io.ErrUnexpectedEOF
  8418. }
  8419. mapkey := string(data[iNdEx:postStringIndexmapkey])
  8420. iNdEx = postStringIndexmapkey
  8421. if m.Labels == nil {
  8422. m.Labels = make(map[string]string)
  8423. }
  8424. if iNdEx < postIndex {
  8425. var valuekey uint64
  8426. for shift := uint(0); ; shift += 7 {
  8427. if shift >= 64 {
  8428. return ErrIntOverflowControl
  8429. }
  8430. if iNdEx >= l {
  8431. return io.ErrUnexpectedEOF
  8432. }
  8433. b := data[iNdEx]
  8434. iNdEx++
  8435. valuekey |= (uint64(b) & 0x7F) << shift
  8436. if b < 0x80 {
  8437. break
  8438. }
  8439. }
  8440. var stringLenmapvalue uint64
  8441. for shift := uint(0); ; shift += 7 {
  8442. if shift >= 64 {
  8443. return ErrIntOverflowControl
  8444. }
  8445. if iNdEx >= l {
  8446. return io.ErrUnexpectedEOF
  8447. }
  8448. b := data[iNdEx]
  8449. iNdEx++
  8450. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  8451. if b < 0x80 {
  8452. break
  8453. }
  8454. }
  8455. intStringLenmapvalue := int(stringLenmapvalue)
  8456. if intStringLenmapvalue < 0 {
  8457. return ErrInvalidLengthControl
  8458. }
  8459. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  8460. if postStringIndexmapvalue > l {
  8461. return io.ErrUnexpectedEOF
  8462. }
  8463. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  8464. iNdEx = postStringIndexmapvalue
  8465. m.Labels[mapkey] = mapvalue
  8466. } else {
  8467. var mapvalue string
  8468. m.Labels[mapkey] = mapvalue
  8469. }
  8470. iNdEx = postIndex
  8471. case 4:
  8472. if wireType != 2 {
  8473. return fmt.Errorf("proto: wrong wireType = %d for field ServiceIDs", wireType)
  8474. }
  8475. var stringLen uint64
  8476. for shift := uint(0); ; shift += 7 {
  8477. if shift >= 64 {
  8478. return ErrIntOverflowControl
  8479. }
  8480. if iNdEx >= l {
  8481. return io.ErrUnexpectedEOF
  8482. }
  8483. b := data[iNdEx]
  8484. iNdEx++
  8485. stringLen |= (uint64(b) & 0x7F) << shift
  8486. if b < 0x80 {
  8487. break
  8488. }
  8489. }
  8490. intStringLen := int(stringLen)
  8491. if intStringLen < 0 {
  8492. return ErrInvalidLengthControl
  8493. }
  8494. postIndex := iNdEx + intStringLen
  8495. if postIndex > l {
  8496. return io.ErrUnexpectedEOF
  8497. }
  8498. m.ServiceIDs = append(m.ServiceIDs, string(data[iNdEx:postIndex]))
  8499. iNdEx = postIndex
  8500. case 5:
  8501. if wireType != 2 {
  8502. return fmt.Errorf("proto: wrong wireType = %d for field NodeIDs", wireType)
  8503. }
  8504. var stringLen uint64
  8505. for shift := uint(0); ; shift += 7 {
  8506. if shift >= 64 {
  8507. return ErrIntOverflowControl
  8508. }
  8509. if iNdEx >= l {
  8510. return io.ErrUnexpectedEOF
  8511. }
  8512. b := data[iNdEx]
  8513. iNdEx++
  8514. stringLen |= (uint64(b) & 0x7F) << shift
  8515. if b < 0x80 {
  8516. break
  8517. }
  8518. }
  8519. intStringLen := int(stringLen)
  8520. if intStringLen < 0 {
  8521. return ErrInvalidLengthControl
  8522. }
  8523. postIndex := iNdEx + intStringLen
  8524. if postIndex > l {
  8525. return io.ErrUnexpectedEOF
  8526. }
  8527. m.NodeIDs = append(m.NodeIDs, string(data[iNdEx:postIndex]))
  8528. iNdEx = postIndex
  8529. case 6:
  8530. if wireType != 0 {
  8531. return fmt.Errorf("proto: wrong wireType = %d for field DesiredStates", wireType)
  8532. }
  8533. var v TaskState
  8534. for shift := uint(0); ; shift += 7 {
  8535. if shift >= 64 {
  8536. return ErrIntOverflowControl
  8537. }
  8538. if iNdEx >= l {
  8539. return io.ErrUnexpectedEOF
  8540. }
  8541. b := data[iNdEx]
  8542. iNdEx++
  8543. v |= (TaskState(b) & 0x7F) << shift
  8544. if b < 0x80 {
  8545. break
  8546. }
  8547. }
  8548. m.DesiredStates = append(m.DesiredStates, v)
  8549. case 7:
  8550. if wireType != 2 {
  8551. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  8552. }
  8553. var stringLen uint64
  8554. for shift := uint(0); ; shift += 7 {
  8555. if shift >= 64 {
  8556. return ErrIntOverflowControl
  8557. }
  8558. if iNdEx >= l {
  8559. return io.ErrUnexpectedEOF
  8560. }
  8561. b := data[iNdEx]
  8562. iNdEx++
  8563. stringLen |= (uint64(b) & 0x7F) << shift
  8564. if b < 0x80 {
  8565. break
  8566. }
  8567. }
  8568. intStringLen := int(stringLen)
  8569. if intStringLen < 0 {
  8570. return ErrInvalidLengthControl
  8571. }
  8572. postIndex := iNdEx + intStringLen
  8573. if postIndex > l {
  8574. return io.ErrUnexpectedEOF
  8575. }
  8576. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  8577. iNdEx = postIndex
  8578. default:
  8579. iNdEx = preIndex
  8580. skippy, err := skipControl(data[iNdEx:])
  8581. if err != nil {
  8582. return err
  8583. }
  8584. if skippy < 0 {
  8585. return ErrInvalidLengthControl
  8586. }
  8587. if (iNdEx + skippy) > l {
  8588. return io.ErrUnexpectedEOF
  8589. }
  8590. iNdEx += skippy
  8591. }
  8592. }
  8593. if iNdEx > l {
  8594. return io.ErrUnexpectedEOF
  8595. }
  8596. return nil
  8597. }
  8598. func (m *ListTasksResponse) Unmarshal(data []byte) error {
  8599. l := len(data)
  8600. iNdEx := 0
  8601. for iNdEx < l {
  8602. preIndex := iNdEx
  8603. var wire uint64
  8604. for shift := uint(0); ; shift += 7 {
  8605. if shift >= 64 {
  8606. return ErrIntOverflowControl
  8607. }
  8608. if iNdEx >= l {
  8609. return io.ErrUnexpectedEOF
  8610. }
  8611. b := data[iNdEx]
  8612. iNdEx++
  8613. wire |= (uint64(b) & 0x7F) << shift
  8614. if b < 0x80 {
  8615. break
  8616. }
  8617. }
  8618. fieldNum := int32(wire >> 3)
  8619. wireType := int(wire & 0x7)
  8620. if wireType == 4 {
  8621. return fmt.Errorf("proto: ListTasksResponse: wiretype end group for non-group")
  8622. }
  8623. if fieldNum <= 0 {
  8624. return fmt.Errorf("proto: ListTasksResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  8625. }
  8626. switch fieldNum {
  8627. case 1:
  8628. if wireType != 2 {
  8629. return fmt.Errorf("proto: wrong wireType = %d for field Tasks", wireType)
  8630. }
  8631. var msglen int
  8632. for shift := uint(0); ; shift += 7 {
  8633. if shift >= 64 {
  8634. return ErrIntOverflowControl
  8635. }
  8636. if iNdEx >= l {
  8637. return io.ErrUnexpectedEOF
  8638. }
  8639. b := data[iNdEx]
  8640. iNdEx++
  8641. msglen |= (int(b) & 0x7F) << shift
  8642. if b < 0x80 {
  8643. break
  8644. }
  8645. }
  8646. if msglen < 0 {
  8647. return ErrInvalidLengthControl
  8648. }
  8649. postIndex := iNdEx + msglen
  8650. if postIndex > l {
  8651. return io.ErrUnexpectedEOF
  8652. }
  8653. m.Tasks = append(m.Tasks, &Task{})
  8654. if err := m.Tasks[len(m.Tasks)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  8655. return err
  8656. }
  8657. iNdEx = postIndex
  8658. default:
  8659. iNdEx = preIndex
  8660. skippy, err := skipControl(data[iNdEx:])
  8661. if err != nil {
  8662. return err
  8663. }
  8664. if skippy < 0 {
  8665. return ErrInvalidLengthControl
  8666. }
  8667. if (iNdEx + skippy) > l {
  8668. return io.ErrUnexpectedEOF
  8669. }
  8670. iNdEx += skippy
  8671. }
  8672. }
  8673. if iNdEx > l {
  8674. return io.ErrUnexpectedEOF
  8675. }
  8676. return nil
  8677. }
  8678. func (m *CreateServiceRequest) Unmarshal(data []byte) error {
  8679. l := len(data)
  8680. iNdEx := 0
  8681. for iNdEx < l {
  8682. preIndex := iNdEx
  8683. var wire uint64
  8684. for shift := uint(0); ; shift += 7 {
  8685. if shift >= 64 {
  8686. return ErrIntOverflowControl
  8687. }
  8688. if iNdEx >= l {
  8689. return io.ErrUnexpectedEOF
  8690. }
  8691. b := data[iNdEx]
  8692. iNdEx++
  8693. wire |= (uint64(b) & 0x7F) << shift
  8694. if b < 0x80 {
  8695. break
  8696. }
  8697. }
  8698. fieldNum := int32(wire >> 3)
  8699. wireType := int(wire & 0x7)
  8700. if wireType == 4 {
  8701. return fmt.Errorf("proto: CreateServiceRequest: wiretype end group for non-group")
  8702. }
  8703. if fieldNum <= 0 {
  8704. return fmt.Errorf("proto: CreateServiceRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  8705. }
  8706. switch fieldNum {
  8707. case 1:
  8708. if wireType != 2 {
  8709. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  8710. }
  8711. var msglen int
  8712. for shift := uint(0); ; shift += 7 {
  8713. if shift >= 64 {
  8714. return ErrIntOverflowControl
  8715. }
  8716. if iNdEx >= l {
  8717. return io.ErrUnexpectedEOF
  8718. }
  8719. b := data[iNdEx]
  8720. iNdEx++
  8721. msglen |= (int(b) & 0x7F) << shift
  8722. if b < 0x80 {
  8723. break
  8724. }
  8725. }
  8726. if msglen < 0 {
  8727. return ErrInvalidLengthControl
  8728. }
  8729. postIndex := iNdEx + msglen
  8730. if postIndex > l {
  8731. return io.ErrUnexpectedEOF
  8732. }
  8733. if m.Spec == nil {
  8734. m.Spec = &ServiceSpec{}
  8735. }
  8736. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  8737. return err
  8738. }
  8739. iNdEx = postIndex
  8740. default:
  8741. iNdEx = preIndex
  8742. skippy, err := skipControl(data[iNdEx:])
  8743. if err != nil {
  8744. return err
  8745. }
  8746. if skippy < 0 {
  8747. return ErrInvalidLengthControl
  8748. }
  8749. if (iNdEx + skippy) > l {
  8750. return io.ErrUnexpectedEOF
  8751. }
  8752. iNdEx += skippy
  8753. }
  8754. }
  8755. if iNdEx > l {
  8756. return io.ErrUnexpectedEOF
  8757. }
  8758. return nil
  8759. }
  8760. func (m *CreateServiceResponse) Unmarshal(data []byte) error {
  8761. l := len(data)
  8762. iNdEx := 0
  8763. for iNdEx < l {
  8764. preIndex := iNdEx
  8765. var wire uint64
  8766. for shift := uint(0); ; shift += 7 {
  8767. if shift >= 64 {
  8768. return ErrIntOverflowControl
  8769. }
  8770. if iNdEx >= l {
  8771. return io.ErrUnexpectedEOF
  8772. }
  8773. b := data[iNdEx]
  8774. iNdEx++
  8775. wire |= (uint64(b) & 0x7F) << shift
  8776. if b < 0x80 {
  8777. break
  8778. }
  8779. }
  8780. fieldNum := int32(wire >> 3)
  8781. wireType := int(wire & 0x7)
  8782. if wireType == 4 {
  8783. return fmt.Errorf("proto: CreateServiceResponse: wiretype end group for non-group")
  8784. }
  8785. if fieldNum <= 0 {
  8786. return fmt.Errorf("proto: CreateServiceResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  8787. }
  8788. switch fieldNum {
  8789. case 1:
  8790. if wireType != 2 {
  8791. return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType)
  8792. }
  8793. var msglen int
  8794. for shift := uint(0); ; shift += 7 {
  8795. if shift >= 64 {
  8796. return ErrIntOverflowControl
  8797. }
  8798. if iNdEx >= l {
  8799. return io.ErrUnexpectedEOF
  8800. }
  8801. b := data[iNdEx]
  8802. iNdEx++
  8803. msglen |= (int(b) & 0x7F) << shift
  8804. if b < 0x80 {
  8805. break
  8806. }
  8807. }
  8808. if msglen < 0 {
  8809. return ErrInvalidLengthControl
  8810. }
  8811. postIndex := iNdEx + msglen
  8812. if postIndex > l {
  8813. return io.ErrUnexpectedEOF
  8814. }
  8815. if m.Service == nil {
  8816. m.Service = &Service{}
  8817. }
  8818. if err := m.Service.Unmarshal(data[iNdEx:postIndex]); err != nil {
  8819. return err
  8820. }
  8821. iNdEx = postIndex
  8822. default:
  8823. iNdEx = preIndex
  8824. skippy, err := skipControl(data[iNdEx:])
  8825. if err != nil {
  8826. return err
  8827. }
  8828. if skippy < 0 {
  8829. return ErrInvalidLengthControl
  8830. }
  8831. if (iNdEx + skippy) > l {
  8832. return io.ErrUnexpectedEOF
  8833. }
  8834. iNdEx += skippy
  8835. }
  8836. }
  8837. if iNdEx > l {
  8838. return io.ErrUnexpectedEOF
  8839. }
  8840. return nil
  8841. }
  8842. func (m *GetServiceRequest) Unmarshal(data []byte) error {
  8843. l := len(data)
  8844. iNdEx := 0
  8845. for iNdEx < l {
  8846. preIndex := iNdEx
  8847. var wire uint64
  8848. for shift := uint(0); ; shift += 7 {
  8849. if shift >= 64 {
  8850. return ErrIntOverflowControl
  8851. }
  8852. if iNdEx >= l {
  8853. return io.ErrUnexpectedEOF
  8854. }
  8855. b := data[iNdEx]
  8856. iNdEx++
  8857. wire |= (uint64(b) & 0x7F) << shift
  8858. if b < 0x80 {
  8859. break
  8860. }
  8861. }
  8862. fieldNum := int32(wire >> 3)
  8863. wireType := int(wire & 0x7)
  8864. if wireType == 4 {
  8865. return fmt.Errorf("proto: GetServiceRequest: wiretype end group for non-group")
  8866. }
  8867. if fieldNum <= 0 {
  8868. return fmt.Errorf("proto: GetServiceRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  8869. }
  8870. switch fieldNum {
  8871. case 1:
  8872. if wireType != 2 {
  8873. return fmt.Errorf("proto: wrong wireType = %d for field ServiceID", wireType)
  8874. }
  8875. var stringLen uint64
  8876. for shift := uint(0); ; shift += 7 {
  8877. if shift >= 64 {
  8878. return ErrIntOverflowControl
  8879. }
  8880. if iNdEx >= l {
  8881. return io.ErrUnexpectedEOF
  8882. }
  8883. b := data[iNdEx]
  8884. iNdEx++
  8885. stringLen |= (uint64(b) & 0x7F) << shift
  8886. if b < 0x80 {
  8887. break
  8888. }
  8889. }
  8890. intStringLen := int(stringLen)
  8891. if intStringLen < 0 {
  8892. return ErrInvalidLengthControl
  8893. }
  8894. postIndex := iNdEx + intStringLen
  8895. if postIndex > l {
  8896. return io.ErrUnexpectedEOF
  8897. }
  8898. m.ServiceID = string(data[iNdEx:postIndex])
  8899. iNdEx = postIndex
  8900. default:
  8901. iNdEx = preIndex
  8902. skippy, err := skipControl(data[iNdEx:])
  8903. if err != nil {
  8904. return err
  8905. }
  8906. if skippy < 0 {
  8907. return ErrInvalidLengthControl
  8908. }
  8909. if (iNdEx + skippy) > l {
  8910. return io.ErrUnexpectedEOF
  8911. }
  8912. iNdEx += skippy
  8913. }
  8914. }
  8915. if iNdEx > l {
  8916. return io.ErrUnexpectedEOF
  8917. }
  8918. return nil
  8919. }
  8920. func (m *GetServiceResponse) Unmarshal(data []byte) error {
  8921. l := len(data)
  8922. iNdEx := 0
  8923. for iNdEx < l {
  8924. preIndex := iNdEx
  8925. var wire uint64
  8926. for shift := uint(0); ; shift += 7 {
  8927. if shift >= 64 {
  8928. return ErrIntOverflowControl
  8929. }
  8930. if iNdEx >= l {
  8931. return io.ErrUnexpectedEOF
  8932. }
  8933. b := data[iNdEx]
  8934. iNdEx++
  8935. wire |= (uint64(b) & 0x7F) << shift
  8936. if b < 0x80 {
  8937. break
  8938. }
  8939. }
  8940. fieldNum := int32(wire >> 3)
  8941. wireType := int(wire & 0x7)
  8942. if wireType == 4 {
  8943. return fmt.Errorf("proto: GetServiceResponse: wiretype end group for non-group")
  8944. }
  8945. if fieldNum <= 0 {
  8946. return fmt.Errorf("proto: GetServiceResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  8947. }
  8948. switch fieldNum {
  8949. case 1:
  8950. if wireType != 2 {
  8951. return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType)
  8952. }
  8953. var msglen int
  8954. for shift := uint(0); ; shift += 7 {
  8955. if shift >= 64 {
  8956. return ErrIntOverflowControl
  8957. }
  8958. if iNdEx >= l {
  8959. return io.ErrUnexpectedEOF
  8960. }
  8961. b := data[iNdEx]
  8962. iNdEx++
  8963. msglen |= (int(b) & 0x7F) << shift
  8964. if b < 0x80 {
  8965. break
  8966. }
  8967. }
  8968. if msglen < 0 {
  8969. return ErrInvalidLengthControl
  8970. }
  8971. postIndex := iNdEx + msglen
  8972. if postIndex > l {
  8973. return io.ErrUnexpectedEOF
  8974. }
  8975. if m.Service == nil {
  8976. m.Service = &Service{}
  8977. }
  8978. if err := m.Service.Unmarshal(data[iNdEx:postIndex]); err != nil {
  8979. return err
  8980. }
  8981. iNdEx = postIndex
  8982. default:
  8983. iNdEx = preIndex
  8984. skippy, err := skipControl(data[iNdEx:])
  8985. if err != nil {
  8986. return err
  8987. }
  8988. if skippy < 0 {
  8989. return ErrInvalidLengthControl
  8990. }
  8991. if (iNdEx + skippy) > l {
  8992. return io.ErrUnexpectedEOF
  8993. }
  8994. iNdEx += skippy
  8995. }
  8996. }
  8997. if iNdEx > l {
  8998. return io.ErrUnexpectedEOF
  8999. }
  9000. return nil
  9001. }
  9002. func (m *UpdateServiceRequest) Unmarshal(data []byte) error {
  9003. l := len(data)
  9004. iNdEx := 0
  9005. for iNdEx < l {
  9006. preIndex := iNdEx
  9007. var wire uint64
  9008. for shift := uint(0); ; shift += 7 {
  9009. if shift >= 64 {
  9010. return ErrIntOverflowControl
  9011. }
  9012. if iNdEx >= l {
  9013. return io.ErrUnexpectedEOF
  9014. }
  9015. b := data[iNdEx]
  9016. iNdEx++
  9017. wire |= (uint64(b) & 0x7F) << shift
  9018. if b < 0x80 {
  9019. break
  9020. }
  9021. }
  9022. fieldNum := int32(wire >> 3)
  9023. wireType := int(wire & 0x7)
  9024. if wireType == 4 {
  9025. return fmt.Errorf("proto: UpdateServiceRequest: wiretype end group for non-group")
  9026. }
  9027. if fieldNum <= 0 {
  9028. return fmt.Errorf("proto: UpdateServiceRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  9029. }
  9030. switch fieldNum {
  9031. case 1:
  9032. if wireType != 2 {
  9033. return fmt.Errorf("proto: wrong wireType = %d for field ServiceID", wireType)
  9034. }
  9035. var stringLen uint64
  9036. for shift := uint(0); ; shift += 7 {
  9037. if shift >= 64 {
  9038. return ErrIntOverflowControl
  9039. }
  9040. if iNdEx >= l {
  9041. return io.ErrUnexpectedEOF
  9042. }
  9043. b := data[iNdEx]
  9044. iNdEx++
  9045. stringLen |= (uint64(b) & 0x7F) << shift
  9046. if b < 0x80 {
  9047. break
  9048. }
  9049. }
  9050. intStringLen := int(stringLen)
  9051. if intStringLen < 0 {
  9052. return ErrInvalidLengthControl
  9053. }
  9054. postIndex := iNdEx + intStringLen
  9055. if postIndex > l {
  9056. return io.ErrUnexpectedEOF
  9057. }
  9058. m.ServiceID = string(data[iNdEx:postIndex])
  9059. iNdEx = postIndex
  9060. case 2:
  9061. if wireType != 2 {
  9062. return fmt.Errorf("proto: wrong wireType = %d for field ServiceVersion", wireType)
  9063. }
  9064. var msglen int
  9065. for shift := uint(0); ; shift += 7 {
  9066. if shift >= 64 {
  9067. return ErrIntOverflowControl
  9068. }
  9069. if iNdEx >= l {
  9070. return io.ErrUnexpectedEOF
  9071. }
  9072. b := data[iNdEx]
  9073. iNdEx++
  9074. msglen |= (int(b) & 0x7F) << shift
  9075. if b < 0x80 {
  9076. break
  9077. }
  9078. }
  9079. if msglen < 0 {
  9080. return ErrInvalidLengthControl
  9081. }
  9082. postIndex := iNdEx + msglen
  9083. if postIndex > l {
  9084. return io.ErrUnexpectedEOF
  9085. }
  9086. if m.ServiceVersion == nil {
  9087. m.ServiceVersion = &Version{}
  9088. }
  9089. if err := m.ServiceVersion.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9090. return err
  9091. }
  9092. iNdEx = postIndex
  9093. case 3:
  9094. if wireType != 2 {
  9095. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  9096. }
  9097. var msglen int
  9098. for shift := uint(0); ; shift += 7 {
  9099. if shift >= 64 {
  9100. return ErrIntOverflowControl
  9101. }
  9102. if iNdEx >= l {
  9103. return io.ErrUnexpectedEOF
  9104. }
  9105. b := data[iNdEx]
  9106. iNdEx++
  9107. msglen |= (int(b) & 0x7F) << shift
  9108. if b < 0x80 {
  9109. break
  9110. }
  9111. }
  9112. if msglen < 0 {
  9113. return ErrInvalidLengthControl
  9114. }
  9115. postIndex := iNdEx + msglen
  9116. if postIndex > l {
  9117. return io.ErrUnexpectedEOF
  9118. }
  9119. if m.Spec == nil {
  9120. m.Spec = &ServiceSpec{}
  9121. }
  9122. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9123. return err
  9124. }
  9125. iNdEx = postIndex
  9126. default:
  9127. iNdEx = preIndex
  9128. skippy, err := skipControl(data[iNdEx:])
  9129. if err != nil {
  9130. return err
  9131. }
  9132. if skippy < 0 {
  9133. return ErrInvalidLengthControl
  9134. }
  9135. if (iNdEx + skippy) > l {
  9136. return io.ErrUnexpectedEOF
  9137. }
  9138. iNdEx += skippy
  9139. }
  9140. }
  9141. if iNdEx > l {
  9142. return io.ErrUnexpectedEOF
  9143. }
  9144. return nil
  9145. }
  9146. func (m *UpdateServiceResponse) Unmarshal(data []byte) error {
  9147. l := len(data)
  9148. iNdEx := 0
  9149. for iNdEx < l {
  9150. preIndex := iNdEx
  9151. var wire uint64
  9152. for shift := uint(0); ; shift += 7 {
  9153. if shift >= 64 {
  9154. return ErrIntOverflowControl
  9155. }
  9156. if iNdEx >= l {
  9157. return io.ErrUnexpectedEOF
  9158. }
  9159. b := data[iNdEx]
  9160. iNdEx++
  9161. wire |= (uint64(b) & 0x7F) << shift
  9162. if b < 0x80 {
  9163. break
  9164. }
  9165. }
  9166. fieldNum := int32(wire >> 3)
  9167. wireType := int(wire & 0x7)
  9168. if wireType == 4 {
  9169. return fmt.Errorf("proto: UpdateServiceResponse: wiretype end group for non-group")
  9170. }
  9171. if fieldNum <= 0 {
  9172. return fmt.Errorf("proto: UpdateServiceResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  9173. }
  9174. switch fieldNum {
  9175. case 1:
  9176. if wireType != 2 {
  9177. return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType)
  9178. }
  9179. var msglen int
  9180. for shift := uint(0); ; shift += 7 {
  9181. if shift >= 64 {
  9182. return ErrIntOverflowControl
  9183. }
  9184. if iNdEx >= l {
  9185. return io.ErrUnexpectedEOF
  9186. }
  9187. b := data[iNdEx]
  9188. iNdEx++
  9189. msglen |= (int(b) & 0x7F) << shift
  9190. if b < 0x80 {
  9191. break
  9192. }
  9193. }
  9194. if msglen < 0 {
  9195. return ErrInvalidLengthControl
  9196. }
  9197. postIndex := iNdEx + msglen
  9198. if postIndex > l {
  9199. return io.ErrUnexpectedEOF
  9200. }
  9201. if m.Service == nil {
  9202. m.Service = &Service{}
  9203. }
  9204. if err := m.Service.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9205. return err
  9206. }
  9207. iNdEx = postIndex
  9208. default:
  9209. iNdEx = preIndex
  9210. skippy, err := skipControl(data[iNdEx:])
  9211. if err != nil {
  9212. return err
  9213. }
  9214. if skippy < 0 {
  9215. return ErrInvalidLengthControl
  9216. }
  9217. if (iNdEx + skippy) > l {
  9218. return io.ErrUnexpectedEOF
  9219. }
  9220. iNdEx += skippy
  9221. }
  9222. }
  9223. if iNdEx > l {
  9224. return io.ErrUnexpectedEOF
  9225. }
  9226. return nil
  9227. }
  9228. func (m *RemoveServiceRequest) Unmarshal(data []byte) error {
  9229. l := len(data)
  9230. iNdEx := 0
  9231. for iNdEx < l {
  9232. preIndex := iNdEx
  9233. var wire uint64
  9234. for shift := uint(0); ; shift += 7 {
  9235. if shift >= 64 {
  9236. return ErrIntOverflowControl
  9237. }
  9238. if iNdEx >= l {
  9239. return io.ErrUnexpectedEOF
  9240. }
  9241. b := data[iNdEx]
  9242. iNdEx++
  9243. wire |= (uint64(b) & 0x7F) << shift
  9244. if b < 0x80 {
  9245. break
  9246. }
  9247. }
  9248. fieldNum := int32(wire >> 3)
  9249. wireType := int(wire & 0x7)
  9250. if wireType == 4 {
  9251. return fmt.Errorf("proto: RemoveServiceRequest: wiretype end group for non-group")
  9252. }
  9253. if fieldNum <= 0 {
  9254. return fmt.Errorf("proto: RemoveServiceRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  9255. }
  9256. switch fieldNum {
  9257. case 1:
  9258. if wireType != 2 {
  9259. return fmt.Errorf("proto: wrong wireType = %d for field ServiceID", wireType)
  9260. }
  9261. var stringLen uint64
  9262. for shift := uint(0); ; shift += 7 {
  9263. if shift >= 64 {
  9264. return ErrIntOverflowControl
  9265. }
  9266. if iNdEx >= l {
  9267. return io.ErrUnexpectedEOF
  9268. }
  9269. b := data[iNdEx]
  9270. iNdEx++
  9271. stringLen |= (uint64(b) & 0x7F) << shift
  9272. if b < 0x80 {
  9273. break
  9274. }
  9275. }
  9276. intStringLen := int(stringLen)
  9277. if intStringLen < 0 {
  9278. return ErrInvalidLengthControl
  9279. }
  9280. postIndex := iNdEx + intStringLen
  9281. if postIndex > l {
  9282. return io.ErrUnexpectedEOF
  9283. }
  9284. m.ServiceID = string(data[iNdEx:postIndex])
  9285. iNdEx = postIndex
  9286. default:
  9287. iNdEx = preIndex
  9288. skippy, err := skipControl(data[iNdEx:])
  9289. if err != nil {
  9290. return err
  9291. }
  9292. if skippy < 0 {
  9293. return ErrInvalidLengthControl
  9294. }
  9295. if (iNdEx + skippy) > l {
  9296. return io.ErrUnexpectedEOF
  9297. }
  9298. iNdEx += skippy
  9299. }
  9300. }
  9301. if iNdEx > l {
  9302. return io.ErrUnexpectedEOF
  9303. }
  9304. return nil
  9305. }
  9306. func (m *RemoveServiceResponse) Unmarshal(data []byte) error {
  9307. l := len(data)
  9308. iNdEx := 0
  9309. for iNdEx < l {
  9310. preIndex := iNdEx
  9311. var wire uint64
  9312. for shift := uint(0); ; shift += 7 {
  9313. if shift >= 64 {
  9314. return ErrIntOverflowControl
  9315. }
  9316. if iNdEx >= l {
  9317. return io.ErrUnexpectedEOF
  9318. }
  9319. b := data[iNdEx]
  9320. iNdEx++
  9321. wire |= (uint64(b) & 0x7F) << shift
  9322. if b < 0x80 {
  9323. break
  9324. }
  9325. }
  9326. fieldNum := int32(wire >> 3)
  9327. wireType := int(wire & 0x7)
  9328. if wireType == 4 {
  9329. return fmt.Errorf("proto: RemoveServiceResponse: wiretype end group for non-group")
  9330. }
  9331. if fieldNum <= 0 {
  9332. return fmt.Errorf("proto: RemoveServiceResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  9333. }
  9334. switch fieldNum {
  9335. default:
  9336. iNdEx = preIndex
  9337. skippy, err := skipControl(data[iNdEx:])
  9338. if err != nil {
  9339. return err
  9340. }
  9341. if skippy < 0 {
  9342. return ErrInvalidLengthControl
  9343. }
  9344. if (iNdEx + skippy) > l {
  9345. return io.ErrUnexpectedEOF
  9346. }
  9347. iNdEx += skippy
  9348. }
  9349. }
  9350. if iNdEx > l {
  9351. return io.ErrUnexpectedEOF
  9352. }
  9353. return nil
  9354. }
  9355. func (m *ListServicesRequest) Unmarshal(data []byte) error {
  9356. l := len(data)
  9357. iNdEx := 0
  9358. for iNdEx < l {
  9359. preIndex := iNdEx
  9360. var wire uint64
  9361. for shift := uint(0); ; shift += 7 {
  9362. if shift >= 64 {
  9363. return ErrIntOverflowControl
  9364. }
  9365. if iNdEx >= l {
  9366. return io.ErrUnexpectedEOF
  9367. }
  9368. b := data[iNdEx]
  9369. iNdEx++
  9370. wire |= (uint64(b) & 0x7F) << shift
  9371. if b < 0x80 {
  9372. break
  9373. }
  9374. }
  9375. fieldNum := int32(wire >> 3)
  9376. wireType := int(wire & 0x7)
  9377. if wireType == 4 {
  9378. return fmt.Errorf("proto: ListServicesRequest: wiretype end group for non-group")
  9379. }
  9380. if fieldNum <= 0 {
  9381. return fmt.Errorf("proto: ListServicesRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  9382. }
  9383. switch fieldNum {
  9384. case 1:
  9385. if wireType != 2 {
  9386. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  9387. }
  9388. var msglen int
  9389. for shift := uint(0); ; shift += 7 {
  9390. if shift >= 64 {
  9391. return ErrIntOverflowControl
  9392. }
  9393. if iNdEx >= l {
  9394. return io.ErrUnexpectedEOF
  9395. }
  9396. b := data[iNdEx]
  9397. iNdEx++
  9398. msglen |= (int(b) & 0x7F) << shift
  9399. if b < 0x80 {
  9400. break
  9401. }
  9402. }
  9403. if msglen < 0 {
  9404. return ErrInvalidLengthControl
  9405. }
  9406. postIndex := iNdEx + msglen
  9407. if postIndex > l {
  9408. return io.ErrUnexpectedEOF
  9409. }
  9410. if m.Filters == nil {
  9411. m.Filters = &ListServicesRequest_Filters{}
  9412. }
  9413. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9414. return err
  9415. }
  9416. iNdEx = postIndex
  9417. default:
  9418. iNdEx = preIndex
  9419. skippy, err := skipControl(data[iNdEx:])
  9420. if err != nil {
  9421. return err
  9422. }
  9423. if skippy < 0 {
  9424. return ErrInvalidLengthControl
  9425. }
  9426. if (iNdEx + skippy) > l {
  9427. return io.ErrUnexpectedEOF
  9428. }
  9429. iNdEx += skippy
  9430. }
  9431. }
  9432. if iNdEx > l {
  9433. return io.ErrUnexpectedEOF
  9434. }
  9435. return nil
  9436. }
  9437. func (m *ListServicesRequest_Filters) Unmarshal(data []byte) error {
  9438. l := len(data)
  9439. iNdEx := 0
  9440. for iNdEx < l {
  9441. preIndex := iNdEx
  9442. var wire uint64
  9443. for shift := uint(0); ; shift += 7 {
  9444. if shift >= 64 {
  9445. return ErrIntOverflowControl
  9446. }
  9447. if iNdEx >= l {
  9448. return io.ErrUnexpectedEOF
  9449. }
  9450. b := data[iNdEx]
  9451. iNdEx++
  9452. wire |= (uint64(b) & 0x7F) << shift
  9453. if b < 0x80 {
  9454. break
  9455. }
  9456. }
  9457. fieldNum := int32(wire >> 3)
  9458. wireType := int(wire & 0x7)
  9459. if wireType == 4 {
  9460. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  9461. }
  9462. if fieldNum <= 0 {
  9463. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  9464. }
  9465. switch fieldNum {
  9466. case 1:
  9467. if wireType != 2 {
  9468. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  9469. }
  9470. var stringLen uint64
  9471. for shift := uint(0); ; shift += 7 {
  9472. if shift >= 64 {
  9473. return ErrIntOverflowControl
  9474. }
  9475. if iNdEx >= l {
  9476. return io.ErrUnexpectedEOF
  9477. }
  9478. b := data[iNdEx]
  9479. iNdEx++
  9480. stringLen |= (uint64(b) & 0x7F) << shift
  9481. if b < 0x80 {
  9482. break
  9483. }
  9484. }
  9485. intStringLen := int(stringLen)
  9486. if intStringLen < 0 {
  9487. return ErrInvalidLengthControl
  9488. }
  9489. postIndex := iNdEx + intStringLen
  9490. if postIndex > l {
  9491. return io.ErrUnexpectedEOF
  9492. }
  9493. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  9494. iNdEx = postIndex
  9495. case 2:
  9496. if wireType != 2 {
  9497. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  9498. }
  9499. var stringLen uint64
  9500. for shift := uint(0); ; shift += 7 {
  9501. if shift >= 64 {
  9502. return ErrIntOverflowControl
  9503. }
  9504. if iNdEx >= l {
  9505. return io.ErrUnexpectedEOF
  9506. }
  9507. b := data[iNdEx]
  9508. iNdEx++
  9509. stringLen |= (uint64(b) & 0x7F) << shift
  9510. if b < 0x80 {
  9511. break
  9512. }
  9513. }
  9514. intStringLen := int(stringLen)
  9515. if intStringLen < 0 {
  9516. return ErrInvalidLengthControl
  9517. }
  9518. postIndex := iNdEx + intStringLen
  9519. if postIndex > l {
  9520. return io.ErrUnexpectedEOF
  9521. }
  9522. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  9523. iNdEx = postIndex
  9524. case 3:
  9525. if wireType != 2 {
  9526. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  9527. }
  9528. var msglen int
  9529. for shift := uint(0); ; shift += 7 {
  9530. if shift >= 64 {
  9531. return ErrIntOverflowControl
  9532. }
  9533. if iNdEx >= l {
  9534. return io.ErrUnexpectedEOF
  9535. }
  9536. b := data[iNdEx]
  9537. iNdEx++
  9538. msglen |= (int(b) & 0x7F) << shift
  9539. if b < 0x80 {
  9540. break
  9541. }
  9542. }
  9543. if msglen < 0 {
  9544. return ErrInvalidLengthControl
  9545. }
  9546. postIndex := iNdEx + msglen
  9547. if postIndex > l {
  9548. return io.ErrUnexpectedEOF
  9549. }
  9550. var keykey uint64
  9551. for shift := uint(0); ; shift += 7 {
  9552. if shift >= 64 {
  9553. return ErrIntOverflowControl
  9554. }
  9555. if iNdEx >= l {
  9556. return io.ErrUnexpectedEOF
  9557. }
  9558. b := data[iNdEx]
  9559. iNdEx++
  9560. keykey |= (uint64(b) & 0x7F) << shift
  9561. if b < 0x80 {
  9562. break
  9563. }
  9564. }
  9565. var stringLenmapkey uint64
  9566. for shift := uint(0); ; shift += 7 {
  9567. if shift >= 64 {
  9568. return ErrIntOverflowControl
  9569. }
  9570. if iNdEx >= l {
  9571. return io.ErrUnexpectedEOF
  9572. }
  9573. b := data[iNdEx]
  9574. iNdEx++
  9575. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  9576. if b < 0x80 {
  9577. break
  9578. }
  9579. }
  9580. intStringLenmapkey := int(stringLenmapkey)
  9581. if intStringLenmapkey < 0 {
  9582. return ErrInvalidLengthControl
  9583. }
  9584. postStringIndexmapkey := iNdEx + intStringLenmapkey
  9585. if postStringIndexmapkey > l {
  9586. return io.ErrUnexpectedEOF
  9587. }
  9588. mapkey := string(data[iNdEx:postStringIndexmapkey])
  9589. iNdEx = postStringIndexmapkey
  9590. if m.Labels == nil {
  9591. m.Labels = make(map[string]string)
  9592. }
  9593. if iNdEx < postIndex {
  9594. var valuekey uint64
  9595. for shift := uint(0); ; shift += 7 {
  9596. if shift >= 64 {
  9597. return ErrIntOverflowControl
  9598. }
  9599. if iNdEx >= l {
  9600. return io.ErrUnexpectedEOF
  9601. }
  9602. b := data[iNdEx]
  9603. iNdEx++
  9604. valuekey |= (uint64(b) & 0x7F) << shift
  9605. if b < 0x80 {
  9606. break
  9607. }
  9608. }
  9609. var stringLenmapvalue uint64
  9610. for shift := uint(0); ; shift += 7 {
  9611. if shift >= 64 {
  9612. return ErrIntOverflowControl
  9613. }
  9614. if iNdEx >= l {
  9615. return io.ErrUnexpectedEOF
  9616. }
  9617. b := data[iNdEx]
  9618. iNdEx++
  9619. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  9620. if b < 0x80 {
  9621. break
  9622. }
  9623. }
  9624. intStringLenmapvalue := int(stringLenmapvalue)
  9625. if intStringLenmapvalue < 0 {
  9626. return ErrInvalidLengthControl
  9627. }
  9628. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  9629. if postStringIndexmapvalue > l {
  9630. return io.ErrUnexpectedEOF
  9631. }
  9632. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  9633. iNdEx = postStringIndexmapvalue
  9634. m.Labels[mapkey] = mapvalue
  9635. } else {
  9636. var mapvalue string
  9637. m.Labels[mapkey] = mapvalue
  9638. }
  9639. iNdEx = postIndex
  9640. case 4:
  9641. if wireType != 2 {
  9642. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  9643. }
  9644. var stringLen uint64
  9645. for shift := uint(0); ; shift += 7 {
  9646. if shift >= 64 {
  9647. return ErrIntOverflowControl
  9648. }
  9649. if iNdEx >= l {
  9650. return io.ErrUnexpectedEOF
  9651. }
  9652. b := data[iNdEx]
  9653. iNdEx++
  9654. stringLen |= (uint64(b) & 0x7F) << shift
  9655. if b < 0x80 {
  9656. break
  9657. }
  9658. }
  9659. intStringLen := int(stringLen)
  9660. if intStringLen < 0 {
  9661. return ErrInvalidLengthControl
  9662. }
  9663. postIndex := iNdEx + intStringLen
  9664. if postIndex > l {
  9665. return io.ErrUnexpectedEOF
  9666. }
  9667. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  9668. iNdEx = postIndex
  9669. default:
  9670. iNdEx = preIndex
  9671. skippy, err := skipControl(data[iNdEx:])
  9672. if err != nil {
  9673. return err
  9674. }
  9675. if skippy < 0 {
  9676. return ErrInvalidLengthControl
  9677. }
  9678. if (iNdEx + skippy) > l {
  9679. return io.ErrUnexpectedEOF
  9680. }
  9681. iNdEx += skippy
  9682. }
  9683. }
  9684. if iNdEx > l {
  9685. return io.ErrUnexpectedEOF
  9686. }
  9687. return nil
  9688. }
  9689. func (m *ListServicesResponse) Unmarshal(data []byte) error {
  9690. l := len(data)
  9691. iNdEx := 0
  9692. for iNdEx < l {
  9693. preIndex := iNdEx
  9694. var wire uint64
  9695. for shift := uint(0); ; shift += 7 {
  9696. if shift >= 64 {
  9697. return ErrIntOverflowControl
  9698. }
  9699. if iNdEx >= l {
  9700. return io.ErrUnexpectedEOF
  9701. }
  9702. b := data[iNdEx]
  9703. iNdEx++
  9704. wire |= (uint64(b) & 0x7F) << shift
  9705. if b < 0x80 {
  9706. break
  9707. }
  9708. }
  9709. fieldNum := int32(wire >> 3)
  9710. wireType := int(wire & 0x7)
  9711. if wireType == 4 {
  9712. return fmt.Errorf("proto: ListServicesResponse: wiretype end group for non-group")
  9713. }
  9714. if fieldNum <= 0 {
  9715. return fmt.Errorf("proto: ListServicesResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  9716. }
  9717. switch fieldNum {
  9718. case 1:
  9719. if wireType != 2 {
  9720. return fmt.Errorf("proto: wrong wireType = %d for field Services", wireType)
  9721. }
  9722. var msglen int
  9723. for shift := uint(0); ; shift += 7 {
  9724. if shift >= 64 {
  9725. return ErrIntOverflowControl
  9726. }
  9727. if iNdEx >= l {
  9728. return io.ErrUnexpectedEOF
  9729. }
  9730. b := data[iNdEx]
  9731. iNdEx++
  9732. msglen |= (int(b) & 0x7F) << shift
  9733. if b < 0x80 {
  9734. break
  9735. }
  9736. }
  9737. if msglen < 0 {
  9738. return ErrInvalidLengthControl
  9739. }
  9740. postIndex := iNdEx + msglen
  9741. if postIndex > l {
  9742. return io.ErrUnexpectedEOF
  9743. }
  9744. m.Services = append(m.Services, &Service{})
  9745. if err := m.Services[len(m.Services)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  9746. return err
  9747. }
  9748. iNdEx = postIndex
  9749. default:
  9750. iNdEx = preIndex
  9751. skippy, err := skipControl(data[iNdEx:])
  9752. if err != nil {
  9753. return err
  9754. }
  9755. if skippy < 0 {
  9756. return ErrInvalidLengthControl
  9757. }
  9758. if (iNdEx + skippy) > l {
  9759. return io.ErrUnexpectedEOF
  9760. }
  9761. iNdEx += skippy
  9762. }
  9763. }
  9764. if iNdEx > l {
  9765. return io.ErrUnexpectedEOF
  9766. }
  9767. return nil
  9768. }
  9769. func (m *CreateNetworkRequest) Unmarshal(data []byte) error {
  9770. l := len(data)
  9771. iNdEx := 0
  9772. for iNdEx < l {
  9773. preIndex := iNdEx
  9774. var wire uint64
  9775. for shift := uint(0); ; shift += 7 {
  9776. if shift >= 64 {
  9777. return ErrIntOverflowControl
  9778. }
  9779. if iNdEx >= l {
  9780. return io.ErrUnexpectedEOF
  9781. }
  9782. b := data[iNdEx]
  9783. iNdEx++
  9784. wire |= (uint64(b) & 0x7F) << shift
  9785. if b < 0x80 {
  9786. break
  9787. }
  9788. }
  9789. fieldNum := int32(wire >> 3)
  9790. wireType := int(wire & 0x7)
  9791. if wireType == 4 {
  9792. return fmt.Errorf("proto: CreateNetworkRequest: wiretype end group for non-group")
  9793. }
  9794. if fieldNum <= 0 {
  9795. return fmt.Errorf("proto: CreateNetworkRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  9796. }
  9797. switch fieldNum {
  9798. case 1:
  9799. if wireType != 2 {
  9800. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  9801. }
  9802. var msglen int
  9803. for shift := uint(0); ; shift += 7 {
  9804. if shift >= 64 {
  9805. return ErrIntOverflowControl
  9806. }
  9807. if iNdEx >= l {
  9808. return io.ErrUnexpectedEOF
  9809. }
  9810. b := data[iNdEx]
  9811. iNdEx++
  9812. msglen |= (int(b) & 0x7F) << shift
  9813. if b < 0x80 {
  9814. break
  9815. }
  9816. }
  9817. if msglen < 0 {
  9818. return ErrInvalidLengthControl
  9819. }
  9820. postIndex := iNdEx + msglen
  9821. if postIndex > l {
  9822. return io.ErrUnexpectedEOF
  9823. }
  9824. if m.Spec == nil {
  9825. m.Spec = &NetworkSpec{}
  9826. }
  9827. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9828. return err
  9829. }
  9830. iNdEx = postIndex
  9831. default:
  9832. iNdEx = preIndex
  9833. skippy, err := skipControl(data[iNdEx:])
  9834. if err != nil {
  9835. return err
  9836. }
  9837. if skippy < 0 {
  9838. return ErrInvalidLengthControl
  9839. }
  9840. if (iNdEx + skippy) > l {
  9841. return io.ErrUnexpectedEOF
  9842. }
  9843. iNdEx += skippy
  9844. }
  9845. }
  9846. if iNdEx > l {
  9847. return io.ErrUnexpectedEOF
  9848. }
  9849. return nil
  9850. }
  9851. func (m *CreateNetworkResponse) Unmarshal(data []byte) error {
  9852. l := len(data)
  9853. iNdEx := 0
  9854. for iNdEx < l {
  9855. preIndex := iNdEx
  9856. var wire uint64
  9857. for shift := uint(0); ; shift += 7 {
  9858. if shift >= 64 {
  9859. return ErrIntOverflowControl
  9860. }
  9861. if iNdEx >= l {
  9862. return io.ErrUnexpectedEOF
  9863. }
  9864. b := data[iNdEx]
  9865. iNdEx++
  9866. wire |= (uint64(b) & 0x7F) << shift
  9867. if b < 0x80 {
  9868. break
  9869. }
  9870. }
  9871. fieldNum := int32(wire >> 3)
  9872. wireType := int(wire & 0x7)
  9873. if wireType == 4 {
  9874. return fmt.Errorf("proto: CreateNetworkResponse: wiretype end group for non-group")
  9875. }
  9876. if fieldNum <= 0 {
  9877. return fmt.Errorf("proto: CreateNetworkResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  9878. }
  9879. switch fieldNum {
  9880. case 1:
  9881. if wireType != 2 {
  9882. return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
  9883. }
  9884. var msglen int
  9885. for shift := uint(0); ; shift += 7 {
  9886. if shift >= 64 {
  9887. return ErrIntOverflowControl
  9888. }
  9889. if iNdEx >= l {
  9890. return io.ErrUnexpectedEOF
  9891. }
  9892. b := data[iNdEx]
  9893. iNdEx++
  9894. msglen |= (int(b) & 0x7F) << shift
  9895. if b < 0x80 {
  9896. break
  9897. }
  9898. }
  9899. if msglen < 0 {
  9900. return ErrInvalidLengthControl
  9901. }
  9902. postIndex := iNdEx + msglen
  9903. if postIndex > l {
  9904. return io.ErrUnexpectedEOF
  9905. }
  9906. if m.Network == nil {
  9907. m.Network = &Network{}
  9908. }
  9909. if err := m.Network.Unmarshal(data[iNdEx:postIndex]); err != nil {
  9910. return err
  9911. }
  9912. iNdEx = postIndex
  9913. default:
  9914. iNdEx = preIndex
  9915. skippy, err := skipControl(data[iNdEx:])
  9916. if err != nil {
  9917. return err
  9918. }
  9919. if skippy < 0 {
  9920. return ErrInvalidLengthControl
  9921. }
  9922. if (iNdEx + skippy) > l {
  9923. return io.ErrUnexpectedEOF
  9924. }
  9925. iNdEx += skippy
  9926. }
  9927. }
  9928. if iNdEx > l {
  9929. return io.ErrUnexpectedEOF
  9930. }
  9931. return nil
  9932. }
  9933. func (m *GetNetworkRequest) Unmarshal(data []byte) error {
  9934. l := len(data)
  9935. iNdEx := 0
  9936. for iNdEx < l {
  9937. preIndex := iNdEx
  9938. var wire uint64
  9939. for shift := uint(0); ; shift += 7 {
  9940. if shift >= 64 {
  9941. return ErrIntOverflowControl
  9942. }
  9943. if iNdEx >= l {
  9944. return io.ErrUnexpectedEOF
  9945. }
  9946. b := data[iNdEx]
  9947. iNdEx++
  9948. wire |= (uint64(b) & 0x7F) << shift
  9949. if b < 0x80 {
  9950. break
  9951. }
  9952. }
  9953. fieldNum := int32(wire >> 3)
  9954. wireType := int(wire & 0x7)
  9955. if wireType == 4 {
  9956. return fmt.Errorf("proto: GetNetworkRequest: wiretype end group for non-group")
  9957. }
  9958. if fieldNum <= 0 {
  9959. return fmt.Errorf("proto: GetNetworkRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  9960. }
  9961. switch fieldNum {
  9962. case 1:
  9963. if wireType != 2 {
  9964. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  9965. }
  9966. var stringLen uint64
  9967. for shift := uint(0); ; shift += 7 {
  9968. if shift >= 64 {
  9969. return ErrIntOverflowControl
  9970. }
  9971. if iNdEx >= l {
  9972. return io.ErrUnexpectedEOF
  9973. }
  9974. b := data[iNdEx]
  9975. iNdEx++
  9976. stringLen |= (uint64(b) & 0x7F) << shift
  9977. if b < 0x80 {
  9978. break
  9979. }
  9980. }
  9981. intStringLen := int(stringLen)
  9982. if intStringLen < 0 {
  9983. return ErrInvalidLengthControl
  9984. }
  9985. postIndex := iNdEx + intStringLen
  9986. if postIndex > l {
  9987. return io.ErrUnexpectedEOF
  9988. }
  9989. m.Name = string(data[iNdEx:postIndex])
  9990. iNdEx = postIndex
  9991. case 2:
  9992. if wireType != 2 {
  9993. return fmt.Errorf("proto: wrong wireType = %d for field NetworkID", wireType)
  9994. }
  9995. var stringLen uint64
  9996. for shift := uint(0); ; shift += 7 {
  9997. if shift >= 64 {
  9998. return ErrIntOverflowControl
  9999. }
  10000. if iNdEx >= l {
  10001. return io.ErrUnexpectedEOF
  10002. }
  10003. b := data[iNdEx]
  10004. iNdEx++
  10005. stringLen |= (uint64(b) & 0x7F) << shift
  10006. if b < 0x80 {
  10007. break
  10008. }
  10009. }
  10010. intStringLen := int(stringLen)
  10011. if intStringLen < 0 {
  10012. return ErrInvalidLengthControl
  10013. }
  10014. postIndex := iNdEx + intStringLen
  10015. if postIndex > l {
  10016. return io.ErrUnexpectedEOF
  10017. }
  10018. m.NetworkID = string(data[iNdEx:postIndex])
  10019. iNdEx = postIndex
  10020. default:
  10021. iNdEx = preIndex
  10022. skippy, err := skipControl(data[iNdEx:])
  10023. if err != nil {
  10024. return err
  10025. }
  10026. if skippy < 0 {
  10027. return ErrInvalidLengthControl
  10028. }
  10029. if (iNdEx + skippy) > l {
  10030. return io.ErrUnexpectedEOF
  10031. }
  10032. iNdEx += skippy
  10033. }
  10034. }
  10035. if iNdEx > l {
  10036. return io.ErrUnexpectedEOF
  10037. }
  10038. return nil
  10039. }
  10040. func (m *GetNetworkResponse) Unmarshal(data []byte) error {
  10041. l := len(data)
  10042. iNdEx := 0
  10043. for iNdEx < l {
  10044. preIndex := iNdEx
  10045. var wire uint64
  10046. for shift := uint(0); ; shift += 7 {
  10047. if shift >= 64 {
  10048. return ErrIntOverflowControl
  10049. }
  10050. if iNdEx >= l {
  10051. return io.ErrUnexpectedEOF
  10052. }
  10053. b := data[iNdEx]
  10054. iNdEx++
  10055. wire |= (uint64(b) & 0x7F) << shift
  10056. if b < 0x80 {
  10057. break
  10058. }
  10059. }
  10060. fieldNum := int32(wire >> 3)
  10061. wireType := int(wire & 0x7)
  10062. if wireType == 4 {
  10063. return fmt.Errorf("proto: GetNetworkResponse: wiretype end group for non-group")
  10064. }
  10065. if fieldNum <= 0 {
  10066. return fmt.Errorf("proto: GetNetworkResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  10067. }
  10068. switch fieldNum {
  10069. case 1:
  10070. if wireType != 2 {
  10071. return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
  10072. }
  10073. var msglen int
  10074. for shift := uint(0); ; shift += 7 {
  10075. if shift >= 64 {
  10076. return ErrIntOverflowControl
  10077. }
  10078. if iNdEx >= l {
  10079. return io.ErrUnexpectedEOF
  10080. }
  10081. b := data[iNdEx]
  10082. iNdEx++
  10083. msglen |= (int(b) & 0x7F) << shift
  10084. if b < 0x80 {
  10085. break
  10086. }
  10087. }
  10088. if msglen < 0 {
  10089. return ErrInvalidLengthControl
  10090. }
  10091. postIndex := iNdEx + msglen
  10092. if postIndex > l {
  10093. return io.ErrUnexpectedEOF
  10094. }
  10095. if m.Network == nil {
  10096. m.Network = &Network{}
  10097. }
  10098. if err := m.Network.Unmarshal(data[iNdEx:postIndex]); err != nil {
  10099. return err
  10100. }
  10101. iNdEx = postIndex
  10102. default:
  10103. iNdEx = preIndex
  10104. skippy, err := skipControl(data[iNdEx:])
  10105. if err != nil {
  10106. return err
  10107. }
  10108. if skippy < 0 {
  10109. return ErrInvalidLengthControl
  10110. }
  10111. if (iNdEx + skippy) > l {
  10112. return io.ErrUnexpectedEOF
  10113. }
  10114. iNdEx += skippy
  10115. }
  10116. }
  10117. if iNdEx > l {
  10118. return io.ErrUnexpectedEOF
  10119. }
  10120. return nil
  10121. }
  10122. func (m *RemoveNetworkRequest) Unmarshal(data []byte) error {
  10123. l := len(data)
  10124. iNdEx := 0
  10125. for iNdEx < l {
  10126. preIndex := iNdEx
  10127. var wire uint64
  10128. for shift := uint(0); ; shift += 7 {
  10129. if shift >= 64 {
  10130. return ErrIntOverflowControl
  10131. }
  10132. if iNdEx >= l {
  10133. return io.ErrUnexpectedEOF
  10134. }
  10135. b := data[iNdEx]
  10136. iNdEx++
  10137. wire |= (uint64(b) & 0x7F) << shift
  10138. if b < 0x80 {
  10139. break
  10140. }
  10141. }
  10142. fieldNum := int32(wire >> 3)
  10143. wireType := int(wire & 0x7)
  10144. if wireType == 4 {
  10145. return fmt.Errorf("proto: RemoveNetworkRequest: wiretype end group for non-group")
  10146. }
  10147. if fieldNum <= 0 {
  10148. return fmt.Errorf("proto: RemoveNetworkRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  10149. }
  10150. switch fieldNum {
  10151. case 1:
  10152. if wireType != 2 {
  10153. return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
  10154. }
  10155. var stringLen uint64
  10156. for shift := uint(0); ; shift += 7 {
  10157. if shift >= 64 {
  10158. return ErrIntOverflowControl
  10159. }
  10160. if iNdEx >= l {
  10161. return io.ErrUnexpectedEOF
  10162. }
  10163. b := data[iNdEx]
  10164. iNdEx++
  10165. stringLen |= (uint64(b) & 0x7F) << shift
  10166. if b < 0x80 {
  10167. break
  10168. }
  10169. }
  10170. intStringLen := int(stringLen)
  10171. if intStringLen < 0 {
  10172. return ErrInvalidLengthControl
  10173. }
  10174. postIndex := iNdEx + intStringLen
  10175. if postIndex > l {
  10176. return io.ErrUnexpectedEOF
  10177. }
  10178. m.Name = string(data[iNdEx:postIndex])
  10179. iNdEx = postIndex
  10180. case 2:
  10181. if wireType != 2 {
  10182. return fmt.Errorf("proto: wrong wireType = %d for field NetworkID", wireType)
  10183. }
  10184. var stringLen uint64
  10185. for shift := uint(0); ; shift += 7 {
  10186. if shift >= 64 {
  10187. return ErrIntOverflowControl
  10188. }
  10189. if iNdEx >= l {
  10190. return io.ErrUnexpectedEOF
  10191. }
  10192. b := data[iNdEx]
  10193. iNdEx++
  10194. stringLen |= (uint64(b) & 0x7F) << shift
  10195. if b < 0x80 {
  10196. break
  10197. }
  10198. }
  10199. intStringLen := int(stringLen)
  10200. if intStringLen < 0 {
  10201. return ErrInvalidLengthControl
  10202. }
  10203. postIndex := iNdEx + intStringLen
  10204. if postIndex > l {
  10205. return io.ErrUnexpectedEOF
  10206. }
  10207. m.NetworkID = string(data[iNdEx:postIndex])
  10208. iNdEx = postIndex
  10209. default:
  10210. iNdEx = preIndex
  10211. skippy, err := skipControl(data[iNdEx:])
  10212. if err != nil {
  10213. return err
  10214. }
  10215. if skippy < 0 {
  10216. return ErrInvalidLengthControl
  10217. }
  10218. if (iNdEx + skippy) > l {
  10219. return io.ErrUnexpectedEOF
  10220. }
  10221. iNdEx += skippy
  10222. }
  10223. }
  10224. if iNdEx > l {
  10225. return io.ErrUnexpectedEOF
  10226. }
  10227. return nil
  10228. }
  10229. func (m *RemoveNetworkResponse) Unmarshal(data []byte) error {
  10230. l := len(data)
  10231. iNdEx := 0
  10232. for iNdEx < l {
  10233. preIndex := iNdEx
  10234. var wire uint64
  10235. for shift := uint(0); ; shift += 7 {
  10236. if shift >= 64 {
  10237. return ErrIntOverflowControl
  10238. }
  10239. if iNdEx >= l {
  10240. return io.ErrUnexpectedEOF
  10241. }
  10242. b := data[iNdEx]
  10243. iNdEx++
  10244. wire |= (uint64(b) & 0x7F) << shift
  10245. if b < 0x80 {
  10246. break
  10247. }
  10248. }
  10249. fieldNum := int32(wire >> 3)
  10250. wireType := int(wire & 0x7)
  10251. if wireType == 4 {
  10252. return fmt.Errorf("proto: RemoveNetworkResponse: wiretype end group for non-group")
  10253. }
  10254. if fieldNum <= 0 {
  10255. return fmt.Errorf("proto: RemoveNetworkResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  10256. }
  10257. switch fieldNum {
  10258. default:
  10259. iNdEx = preIndex
  10260. skippy, err := skipControl(data[iNdEx:])
  10261. if err != nil {
  10262. return err
  10263. }
  10264. if skippy < 0 {
  10265. return ErrInvalidLengthControl
  10266. }
  10267. if (iNdEx + skippy) > l {
  10268. return io.ErrUnexpectedEOF
  10269. }
  10270. iNdEx += skippy
  10271. }
  10272. }
  10273. if iNdEx > l {
  10274. return io.ErrUnexpectedEOF
  10275. }
  10276. return nil
  10277. }
  10278. func (m *ListNetworksRequest) Unmarshal(data []byte) error {
  10279. l := len(data)
  10280. iNdEx := 0
  10281. for iNdEx < l {
  10282. preIndex := iNdEx
  10283. var wire uint64
  10284. for shift := uint(0); ; shift += 7 {
  10285. if shift >= 64 {
  10286. return ErrIntOverflowControl
  10287. }
  10288. if iNdEx >= l {
  10289. return io.ErrUnexpectedEOF
  10290. }
  10291. b := data[iNdEx]
  10292. iNdEx++
  10293. wire |= (uint64(b) & 0x7F) << shift
  10294. if b < 0x80 {
  10295. break
  10296. }
  10297. }
  10298. fieldNum := int32(wire >> 3)
  10299. wireType := int(wire & 0x7)
  10300. if wireType == 4 {
  10301. return fmt.Errorf("proto: ListNetworksRequest: wiretype end group for non-group")
  10302. }
  10303. if fieldNum <= 0 {
  10304. return fmt.Errorf("proto: ListNetworksRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  10305. }
  10306. switch fieldNum {
  10307. case 1:
  10308. if wireType != 2 {
  10309. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  10310. }
  10311. var msglen int
  10312. for shift := uint(0); ; shift += 7 {
  10313. if shift >= 64 {
  10314. return ErrIntOverflowControl
  10315. }
  10316. if iNdEx >= l {
  10317. return io.ErrUnexpectedEOF
  10318. }
  10319. b := data[iNdEx]
  10320. iNdEx++
  10321. msglen |= (int(b) & 0x7F) << shift
  10322. if b < 0x80 {
  10323. break
  10324. }
  10325. }
  10326. if msglen < 0 {
  10327. return ErrInvalidLengthControl
  10328. }
  10329. postIndex := iNdEx + msglen
  10330. if postIndex > l {
  10331. return io.ErrUnexpectedEOF
  10332. }
  10333. if m.Filters == nil {
  10334. m.Filters = &ListNetworksRequest_Filters{}
  10335. }
  10336. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  10337. return err
  10338. }
  10339. iNdEx = postIndex
  10340. default:
  10341. iNdEx = preIndex
  10342. skippy, err := skipControl(data[iNdEx:])
  10343. if err != nil {
  10344. return err
  10345. }
  10346. if skippy < 0 {
  10347. return ErrInvalidLengthControl
  10348. }
  10349. if (iNdEx + skippy) > l {
  10350. return io.ErrUnexpectedEOF
  10351. }
  10352. iNdEx += skippy
  10353. }
  10354. }
  10355. if iNdEx > l {
  10356. return io.ErrUnexpectedEOF
  10357. }
  10358. return nil
  10359. }
  10360. func (m *ListNetworksRequest_Filters) Unmarshal(data []byte) error {
  10361. l := len(data)
  10362. iNdEx := 0
  10363. for iNdEx < l {
  10364. preIndex := iNdEx
  10365. var wire uint64
  10366. for shift := uint(0); ; shift += 7 {
  10367. if shift >= 64 {
  10368. return ErrIntOverflowControl
  10369. }
  10370. if iNdEx >= l {
  10371. return io.ErrUnexpectedEOF
  10372. }
  10373. b := data[iNdEx]
  10374. iNdEx++
  10375. wire |= (uint64(b) & 0x7F) << shift
  10376. if b < 0x80 {
  10377. break
  10378. }
  10379. }
  10380. fieldNum := int32(wire >> 3)
  10381. wireType := int(wire & 0x7)
  10382. if wireType == 4 {
  10383. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  10384. }
  10385. if fieldNum <= 0 {
  10386. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  10387. }
  10388. switch fieldNum {
  10389. case 1:
  10390. if wireType != 2 {
  10391. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  10392. }
  10393. var stringLen uint64
  10394. for shift := uint(0); ; shift += 7 {
  10395. if shift >= 64 {
  10396. return ErrIntOverflowControl
  10397. }
  10398. if iNdEx >= l {
  10399. return io.ErrUnexpectedEOF
  10400. }
  10401. b := data[iNdEx]
  10402. iNdEx++
  10403. stringLen |= (uint64(b) & 0x7F) << shift
  10404. if b < 0x80 {
  10405. break
  10406. }
  10407. }
  10408. intStringLen := int(stringLen)
  10409. if intStringLen < 0 {
  10410. return ErrInvalidLengthControl
  10411. }
  10412. postIndex := iNdEx + intStringLen
  10413. if postIndex > l {
  10414. return io.ErrUnexpectedEOF
  10415. }
  10416. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  10417. iNdEx = postIndex
  10418. case 2:
  10419. if wireType != 2 {
  10420. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  10421. }
  10422. var stringLen uint64
  10423. for shift := uint(0); ; shift += 7 {
  10424. if shift >= 64 {
  10425. return ErrIntOverflowControl
  10426. }
  10427. if iNdEx >= l {
  10428. return io.ErrUnexpectedEOF
  10429. }
  10430. b := data[iNdEx]
  10431. iNdEx++
  10432. stringLen |= (uint64(b) & 0x7F) << shift
  10433. if b < 0x80 {
  10434. break
  10435. }
  10436. }
  10437. intStringLen := int(stringLen)
  10438. if intStringLen < 0 {
  10439. return ErrInvalidLengthControl
  10440. }
  10441. postIndex := iNdEx + intStringLen
  10442. if postIndex > l {
  10443. return io.ErrUnexpectedEOF
  10444. }
  10445. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  10446. iNdEx = postIndex
  10447. case 3:
  10448. if wireType != 2 {
  10449. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  10450. }
  10451. var msglen int
  10452. for shift := uint(0); ; shift += 7 {
  10453. if shift >= 64 {
  10454. return ErrIntOverflowControl
  10455. }
  10456. if iNdEx >= l {
  10457. return io.ErrUnexpectedEOF
  10458. }
  10459. b := data[iNdEx]
  10460. iNdEx++
  10461. msglen |= (int(b) & 0x7F) << shift
  10462. if b < 0x80 {
  10463. break
  10464. }
  10465. }
  10466. if msglen < 0 {
  10467. return ErrInvalidLengthControl
  10468. }
  10469. postIndex := iNdEx + msglen
  10470. if postIndex > l {
  10471. return io.ErrUnexpectedEOF
  10472. }
  10473. var keykey uint64
  10474. for shift := uint(0); ; shift += 7 {
  10475. if shift >= 64 {
  10476. return ErrIntOverflowControl
  10477. }
  10478. if iNdEx >= l {
  10479. return io.ErrUnexpectedEOF
  10480. }
  10481. b := data[iNdEx]
  10482. iNdEx++
  10483. keykey |= (uint64(b) & 0x7F) << shift
  10484. if b < 0x80 {
  10485. break
  10486. }
  10487. }
  10488. var stringLenmapkey uint64
  10489. for shift := uint(0); ; shift += 7 {
  10490. if shift >= 64 {
  10491. return ErrIntOverflowControl
  10492. }
  10493. if iNdEx >= l {
  10494. return io.ErrUnexpectedEOF
  10495. }
  10496. b := data[iNdEx]
  10497. iNdEx++
  10498. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  10499. if b < 0x80 {
  10500. break
  10501. }
  10502. }
  10503. intStringLenmapkey := int(stringLenmapkey)
  10504. if intStringLenmapkey < 0 {
  10505. return ErrInvalidLengthControl
  10506. }
  10507. postStringIndexmapkey := iNdEx + intStringLenmapkey
  10508. if postStringIndexmapkey > l {
  10509. return io.ErrUnexpectedEOF
  10510. }
  10511. mapkey := string(data[iNdEx:postStringIndexmapkey])
  10512. iNdEx = postStringIndexmapkey
  10513. if m.Labels == nil {
  10514. m.Labels = make(map[string]string)
  10515. }
  10516. if iNdEx < postIndex {
  10517. var valuekey uint64
  10518. for shift := uint(0); ; shift += 7 {
  10519. if shift >= 64 {
  10520. return ErrIntOverflowControl
  10521. }
  10522. if iNdEx >= l {
  10523. return io.ErrUnexpectedEOF
  10524. }
  10525. b := data[iNdEx]
  10526. iNdEx++
  10527. valuekey |= (uint64(b) & 0x7F) << shift
  10528. if b < 0x80 {
  10529. break
  10530. }
  10531. }
  10532. var stringLenmapvalue uint64
  10533. for shift := uint(0); ; shift += 7 {
  10534. if shift >= 64 {
  10535. return ErrIntOverflowControl
  10536. }
  10537. if iNdEx >= l {
  10538. return io.ErrUnexpectedEOF
  10539. }
  10540. b := data[iNdEx]
  10541. iNdEx++
  10542. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  10543. if b < 0x80 {
  10544. break
  10545. }
  10546. }
  10547. intStringLenmapvalue := int(stringLenmapvalue)
  10548. if intStringLenmapvalue < 0 {
  10549. return ErrInvalidLengthControl
  10550. }
  10551. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  10552. if postStringIndexmapvalue > l {
  10553. return io.ErrUnexpectedEOF
  10554. }
  10555. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  10556. iNdEx = postStringIndexmapvalue
  10557. m.Labels[mapkey] = mapvalue
  10558. } else {
  10559. var mapvalue string
  10560. m.Labels[mapkey] = mapvalue
  10561. }
  10562. iNdEx = postIndex
  10563. case 4:
  10564. if wireType != 2 {
  10565. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  10566. }
  10567. var stringLen uint64
  10568. for shift := uint(0); ; shift += 7 {
  10569. if shift >= 64 {
  10570. return ErrIntOverflowControl
  10571. }
  10572. if iNdEx >= l {
  10573. return io.ErrUnexpectedEOF
  10574. }
  10575. b := data[iNdEx]
  10576. iNdEx++
  10577. stringLen |= (uint64(b) & 0x7F) << shift
  10578. if b < 0x80 {
  10579. break
  10580. }
  10581. }
  10582. intStringLen := int(stringLen)
  10583. if intStringLen < 0 {
  10584. return ErrInvalidLengthControl
  10585. }
  10586. postIndex := iNdEx + intStringLen
  10587. if postIndex > l {
  10588. return io.ErrUnexpectedEOF
  10589. }
  10590. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  10591. iNdEx = postIndex
  10592. default:
  10593. iNdEx = preIndex
  10594. skippy, err := skipControl(data[iNdEx:])
  10595. if err != nil {
  10596. return err
  10597. }
  10598. if skippy < 0 {
  10599. return ErrInvalidLengthControl
  10600. }
  10601. if (iNdEx + skippy) > l {
  10602. return io.ErrUnexpectedEOF
  10603. }
  10604. iNdEx += skippy
  10605. }
  10606. }
  10607. if iNdEx > l {
  10608. return io.ErrUnexpectedEOF
  10609. }
  10610. return nil
  10611. }
  10612. func (m *ListNetworksResponse) Unmarshal(data []byte) error {
  10613. l := len(data)
  10614. iNdEx := 0
  10615. for iNdEx < l {
  10616. preIndex := iNdEx
  10617. var wire uint64
  10618. for shift := uint(0); ; shift += 7 {
  10619. if shift >= 64 {
  10620. return ErrIntOverflowControl
  10621. }
  10622. if iNdEx >= l {
  10623. return io.ErrUnexpectedEOF
  10624. }
  10625. b := data[iNdEx]
  10626. iNdEx++
  10627. wire |= (uint64(b) & 0x7F) << shift
  10628. if b < 0x80 {
  10629. break
  10630. }
  10631. }
  10632. fieldNum := int32(wire >> 3)
  10633. wireType := int(wire & 0x7)
  10634. if wireType == 4 {
  10635. return fmt.Errorf("proto: ListNetworksResponse: wiretype end group for non-group")
  10636. }
  10637. if fieldNum <= 0 {
  10638. return fmt.Errorf("proto: ListNetworksResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  10639. }
  10640. switch fieldNum {
  10641. case 1:
  10642. if wireType != 2 {
  10643. return fmt.Errorf("proto: wrong wireType = %d for field Networks", wireType)
  10644. }
  10645. var msglen int
  10646. for shift := uint(0); ; shift += 7 {
  10647. if shift >= 64 {
  10648. return ErrIntOverflowControl
  10649. }
  10650. if iNdEx >= l {
  10651. return io.ErrUnexpectedEOF
  10652. }
  10653. b := data[iNdEx]
  10654. iNdEx++
  10655. msglen |= (int(b) & 0x7F) << shift
  10656. if b < 0x80 {
  10657. break
  10658. }
  10659. }
  10660. if msglen < 0 {
  10661. return ErrInvalidLengthControl
  10662. }
  10663. postIndex := iNdEx + msglen
  10664. if postIndex > l {
  10665. return io.ErrUnexpectedEOF
  10666. }
  10667. m.Networks = append(m.Networks, &Network{})
  10668. if err := m.Networks[len(m.Networks)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  10669. return err
  10670. }
  10671. iNdEx = postIndex
  10672. default:
  10673. iNdEx = preIndex
  10674. skippy, err := skipControl(data[iNdEx:])
  10675. if err != nil {
  10676. return err
  10677. }
  10678. if skippy < 0 {
  10679. return ErrInvalidLengthControl
  10680. }
  10681. if (iNdEx + skippy) > l {
  10682. return io.ErrUnexpectedEOF
  10683. }
  10684. iNdEx += skippy
  10685. }
  10686. }
  10687. if iNdEx > l {
  10688. return io.ErrUnexpectedEOF
  10689. }
  10690. return nil
  10691. }
  10692. func (m *GetClusterRequest) Unmarshal(data []byte) error {
  10693. l := len(data)
  10694. iNdEx := 0
  10695. for iNdEx < l {
  10696. preIndex := iNdEx
  10697. var wire uint64
  10698. for shift := uint(0); ; shift += 7 {
  10699. if shift >= 64 {
  10700. return ErrIntOverflowControl
  10701. }
  10702. if iNdEx >= l {
  10703. return io.ErrUnexpectedEOF
  10704. }
  10705. b := data[iNdEx]
  10706. iNdEx++
  10707. wire |= (uint64(b) & 0x7F) << shift
  10708. if b < 0x80 {
  10709. break
  10710. }
  10711. }
  10712. fieldNum := int32(wire >> 3)
  10713. wireType := int(wire & 0x7)
  10714. if wireType == 4 {
  10715. return fmt.Errorf("proto: GetClusterRequest: wiretype end group for non-group")
  10716. }
  10717. if fieldNum <= 0 {
  10718. return fmt.Errorf("proto: GetClusterRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  10719. }
  10720. switch fieldNum {
  10721. case 1:
  10722. if wireType != 2 {
  10723. return fmt.Errorf("proto: wrong wireType = %d for field ClusterID", wireType)
  10724. }
  10725. var stringLen uint64
  10726. for shift := uint(0); ; shift += 7 {
  10727. if shift >= 64 {
  10728. return ErrIntOverflowControl
  10729. }
  10730. if iNdEx >= l {
  10731. return io.ErrUnexpectedEOF
  10732. }
  10733. b := data[iNdEx]
  10734. iNdEx++
  10735. stringLen |= (uint64(b) & 0x7F) << shift
  10736. if b < 0x80 {
  10737. break
  10738. }
  10739. }
  10740. intStringLen := int(stringLen)
  10741. if intStringLen < 0 {
  10742. return ErrInvalidLengthControl
  10743. }
  10744. postIndex := iNdEx + intStringLen
  10745. if postIndex > l {
  10746. return io.ErrUnexpectedEOF
  10747. }
  10748. m.ClusterID = string(data[iNdEx:postIndex])
  10749. iNdEx = postIndex
  10750. default:
  10751. iNdEx = preIndex
  10752. skippy, err := skipControl(data[iNdEx:])
  10753. if err != nil {
  10754. return err
  10755. }
  10756. if skippy < 0 {
  10757. return ErrInvalidLengthControl
  10758. }
  10759. if (iNdEx + skippy) > l {
  10760. return io.ErrUnexpectedEOF
  10761. }
  10762. iNdEx += skippy
  10763. }
  10764. }
  10765. if iNdEx > l {
  10766. return io.ErrUnexpectedEOF
  10767. }
  10768. return nil
  10769. }
  10770. func (m *GetClusterResponse) Unmarshal(data []byte) error {
  10771. l := len(data)
  10772. iNdEx := 0
  10773. for iNdEx < l {
  10774. preIndex := iNdEx
  10775. var wire uint64
  10776. for shift := uint(0); ; shift += 7 {
  10777. if shift >= 64 {
  10778. return ErrIntOverflowControl
  10779. }
  10780. if iNdEx >= l {
  10781. return io.ErrUnexpectedEOF
  10782. }
  10783. b := data[iNdEx]
  10784. iNdEx++
  10785. wire |= (uint64(b) & 0x7F) << shift
  10786. if b < 0x80 {
  10787. break
  10788. }
  10789. }
  10790. fieldNum := int32(wire >> 3)
  10791. wireType := int(wire & 0x7)
  10792. if wireType == 4 {
  10793. return fmt.Errorf("proto: GetClusterResponse: wiretype end group for non-group")
  10794. }
  10795. if fieldNum <= 0 {
  10796. return fmt.Errorf("proto: GetClusterResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  10797. }
  10798. switch fieldNum {
  10799. case 1:
  10800. if wireType != 2 {
  10801. return fmt.Errorf("proto: wrong wireType = %d for field Cluster", wireType)
  10802. }
  10803. var msglen int
  10804. for shift := uint(0); ; shift += 7 {
  10805. if shift >= 64 {
  10806. return ErrIntOverflowControl
  10807. }
  10808. if iNdEx >= l {
  10809. return io.ErrUnexpectedEOF
  10810. }
  10811. b := data[iNdEx]
  10812. iNdEx++
  10813. msglen |= (int(b) & 0x7F) << shift
  10814. if b < 0x80 {
  10815. break
  10816. }
  10817. }
  10818. if msglen < 0 {
  10819. return ErrInvalidLengthControl
  10820. }
  10821. postIndex := iNdEx + msglen
  10822. if postIndex > l {
  10823. return io.ErrUnexpectedEOF
  10824. }
  10825. if m.Cluster == nil {
  10826. m.Cluster = &Cluster{}
  10827. }
  10828. if err := m.Cluster.Unmarshal(data[iNdEx:postIndex]); err != nil {
  10829. return err
  10830. }
  10831. iNdEx = postIndex
  10832. default:
  10833. iNdEx = preIndex
  10834. skippy, err := skipControl(data[iNdEx:])
  10835. if err != nil {
  10836. return err
  10837. }
  10838. if skippy < 0 {
  10839. return ErrInvalidLengthControl
  10840. }
  10841. if (iNdEx + skippy) > l {
  10842. return io.ErrUnexpectedEOF
  10843. }
  10844. iNdEx += skippy
  10845. }
  10846. }
  10847. if iNdEx > l {
  10848. return io.ErrUnexpectedEOF
  10849. }
  10850. return nil
  10851. }
  10852. func (m *ListClustersRequest) Unmarshal(data []byte) error {
  10853. l := len(data)
  10854. iNdEx := 0
  10855. for iNdEx < l {
  10856. preIndex := iNdEx
  10857. var wire uint64
  10858. for shift := uint(0); ; shift += 7 {
  10859. if shift >= 64 {
  10860. return ErrIntOverflowControl
  10861. }
  10862. if iNdEx >= l {
  10863. return io.ErrUnexpectedEOF
  10864. }
  10865. b := data[iNdEx]
  10866. iNdEx++
  10867. wire |= (uint64(b) & 0x7F) << shift
  10868. if b < 0x80 {
  10869. break
  10870. }
  10871. }
  10872. fieldNum := int32(wire >> 3)
  10873. wireType := int(wire & 0x7)
  10874. if wireType == 4 {
  10875. return fmt.Errorf("proto: ListClustersRequest: wiretype end group for non-group")
  10876. }
  10877. if fieldNum <= 0 {
  10878. return fmt.Errorf("proto: ListClustersRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  10879. }
  10880. switch fieldNum {
  10881. case 1:
  10882. if wireType != 2 {
  10883. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  10884. }
  10885. var msglen int
  10886. for shift := uint(0); ; shift += 7 {
  10887. if shift >= 64 {
  10888. return ErrIntOverflowControl
  10889. }
  10890. if iNdEx >= l {
  10891. return io.ErrUnexpectedEOF
  10892. }
  10893. b := data[iNdEx]
  10894. iNdEx++
  10895. msglen |= (int(b) & 0x7F) << shift
  10896. if b < 0x80 {
  10897. break
  10898. }
  10899. }
  10900. if msglen < 0 {
  10901. return ErrInvalidLengthControl
  10902. }
  10903. postIndex := iNdEx + msglen
  10904. if postIndex > l {
  10905. return io.ErrUnexpectedEOF
  10906. }
  10907. if m.Filters == nil {
  10908. m.Filters = &ListClustersRequest_Filters{}
  10909. }
  10910. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  10911. return err
  10912. }
  10913. iNdEx = postIndex
  10914. default:
  10915. iNdEx = preIndex
  10916. skippy, err := skipControl(data[iNdEx:])
  10917. if err != nil {
  10918. return err
  10919. }
  10920. if skippy < 0 {
  10921. return ErrInvalidLengthControl
  10922. }
  10923. if (iNdEx + skippy) > l {
  10924. return io.ErrUnexpectedEOF
  10925. }
  10926. iNdEx += skippy
  10927. }
  10928. }
  10929. if iNdEx > l {
  10930. return io.ErrUnexpectedEOF
  10931. }
  10932. return nil
  10933. }
  10934. func (m *ListClustersRequest_Filters) Unmarshal(data []byte) error {
  10935. l := len(data)
  10936. iNdEx := 0
  10937. for iNdEx < l {
  10938. preIndex := iNdEx
  10939. var wire uint64
  10940. for shift := uint(0); ; shift += 7 {
  10941. if shift >= 64 {
  10942. return ErrIntOverflowControl
  10943. }
  10944. if iNdEx >= l {
  10945. return io.ErrUnexpectedEOF
  10946. }
  10947. b := data[iNdEx]
  10948. iNdEx++
  10949. wire |= (uint64(b) & 0x7F) << shift
  10950. if b < 0x80 {
  10951. break
  10952. }
  10953. }
  10954. fieldNum := int32(wire >> 3)
  10955. wireType := int(wire & 0x7)
  10956. if wireType == 4 {
  10957. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  10958. }
  10959. if fieldNum <= 0 {
  10960. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  10961. }
  10962. switch fieldNum {
  10963. case 1:
  10964. if wireType != 2 {
  10965. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  10966. }
  10967. var stringLen uint64
  10968. for shift := uint(0); ; shift += 7 {
  10969. if shift >= 64 {
  10970. return ErrIntOverflowControl
  10971. }
  10972. if iNdEx >= l {
  10973. return io.ErrUnexpectedEOF
  10974. }
  10975. b := data[iNdEx]
  10976. iNdEx++
  10977. stringLen |= (uint64(b) & 0x7F) << shift
  10978. if b < 0x80 {
  10979. break
  10980. }
  10981. }
  10982. intStringLen := int(stringLen)
  10983. if intStringLen < 0 {
  10984. return ErrInvalidLengthControl
  10985. }
  10986. postIndex := iNdEx + intStringLen
  10987. if postIndex > l {
  10988. return io.ErrUnexpectedEOF
  10989. }
  10990. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  10991. iNdEx = postIndex
  10992. case 2:
  10993. if wireType != 2 {
  10994. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  10995. }
  10996. var stringLen uint64
  10997. for shift := uint(0); ; shift += 7 {
  10998. if shift >= 64 {
  10999. return ErrIntOverflowControl
  11000. }
  11001. if iNdEx >= l {
  11002. return io.ErrUnexpectedEOF
  11003. }
  11004. b := data[iNdEx]
  11005. iNdEx++
  11006. stringLen |= (uint64(b) & 0x7F) << shift
  11007. if b < 0x80 {
  11008. break
  11009. }
  11010. }
  11011. intStringLen := int(stringLen)
  11012. if intStringLen < 0 {
  11013. return ErrInvalidLengthControl
  11014. }
  11015. postIndex := iNdEx + intStringLen
  11016. if postIndex > l {
  11017. return io.ErrUnexpectedEOF
  11018. }
  11019. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  11020. iNdEx = postIndex
  11021. case 3:
  11022. if wireType != 2 {
  11023. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  11024. }
  11025. var msglen int
  11026. for shift := uint(0); ; shift += 7 {
  11027. if shift >= 64 {
  11028. return ErrIntOverflowControl
  11029. }
  11030. if iNdEx >= l {
  11031. return io.ErrUnexpectedEOF
  11032. }
  11033. b := data[iNdEx]
  11034. iNdEx++
  11035. msglen |= (int(b) & 0x7F) << shift
  11036. if b < 0x80 {
  11037. break
  11038. }
  11039. }
  11040. if msglen < 0 {
  11041. return ErrInvalidLengthControl
  11042. }
  11043. postIndex := iNdEx + msglen
  11044. if postIndex > l {
  11045. return io.ErrUnexpectedEOF
  11046. }
  11047. var keykey uint64
  11048. for shift := uint(0); ; shift += 7 {
  11049. if shift >= 64 {
  11050. return ErrIntOverflowControl
  11051. }
  11052. if iNdEx >= l {
  11053. return io.ErrUnexpectedEOF
  11054. }
  11055. b := data[iNdEx]
  11056. iNdEx++
  11057. keykey |= (uint64(b) & 0x7F) << shift
  11058. if b < 0x80 {
  11059. break
  11060. }
  11061. }
  11062. var stringLenmapkey uint64
  11063. for shift := uint(0); ; shift += 7 {
  11064. if shift >= 64 {
  11065. return ErrIntOverflowControl
  11066. }
  11067. if iNdEx >= l {
  11068. return io.ErrUnexpectedEOF
  11069. }
  11070. b := data[iNdEx]
  11071. iNdEx++
  11072. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  11073. if b < 0x80 {
  11074. break
  11075. }
  11076. }
  11077. intStringLenmapkey := int(stringLenmapkey)
  11078. if intStringLenmapkey < 0 {
  11079. return ErrInvalidLengthControl
  11080. }
  11081. postStringIndexmapkey := iNdEx + intStringLenmapkey
  11082. if postStringIndexmapkey > l {
  11083. return io.ErrUnexpectedEOF
  11084. }
  11085. mapkey := string(data[iNdEx:postStringIndexmapkey])
  11086. iNdEx = postStringIndexmapkey
  11087. if m.Labels == nil {
  11088. m.Labels = make(map[string]string)
  11089. }
  11090. if iNdEx < postIndex {
  11091. var valuekey uint64
  11092. for shift := uint(0); ; shift += 7 {
  11093. if shift >= 64 {
  11094. return ErrIntOverflowControl
  11095. }
  11096. if iNdEx >= l {
  11097. return io.ErrUnexpectedEOF
  11098. }
  11099. b := data[iNdEx]
  11100. iNdEx++
  11101. valuekey |= (uint64(b) & 0x7F) << shift
  11102. if b < 0x80 {
  11103. break
  11104. }
  11105. }
  11106. var stringLenmapvalue uint64
  11107. for shift := uint(0); ; shift += 7 {
  11108. if shift >= 64 {
  11109. return ErrIntOverflowControl
  11110. }
  11111. if iNdEx >= l {
  11112. return io.ErrUnexpectedEOF
  11113. }
  11114. b := data[iNdEx]
  11115. iNdEx++
  11116. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  11117. if b < 0x80 {
  11118. break
  11119. }
  11120. }
  11121. intStringLenmapvalue := int(stringLenmapvalue)
  11122. if intStringLenmapvalue < 0 {
  11123. return ErrInvalidLengthControl
  11124. }
  11125. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  11126. if postStringIndexmapvalue > l {
  11127. return io.ErrUnexpectedEOF
  11128. }
  11129. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  11130. iNdEx = postStringIndexmapvalue
  11131. m.Labels[mapkey] = mapvalue
  11132. } else {
  11133. var mapvalue string
  11134. m.Labels[mapkey] = mapvalue
  11135. }
  11136. iNdEx = postIndex
  11137. case 4:
  11138. if wireType != 2 {
  11139. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  11140. }
  11141. var stringLen uint64
  11142. for shift := uint(0); ; shift += 7 {
  11143. if shift >= 64 {
  11144. return ErrIntOverflowControl
  11145. }
  11146. if iNdEx >= l {
  11147. return io.ErrUnexpectedEOF
  11148. }
  11149. b := data[iNdEx]
  11150. iNdEx++
  11151. stringLen |= (uint64(b) & 0x7F) << shift
  11152. if b < 0x80 {
  11153. break
  11154. }
  11155. }
  11156. intStringLen := int(stringLen)
  11157. if intStringLen < 0 {
  11158. return ErrInvalidLengthControl
  11159. }
  11160. postIndex := iNdEx + intStringLen
  11161. if postIndex > l {
  11162. return io.ErrUnexpectedEOF
  11163. }
  11164. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  11165. iNdEx = postIndex
  11166. default:
  11167. iNdEx = preIndex
  11168. skippy, err := skipControl(data[iNdEx:])
  11169. if err != nil {
  11170. return err
  11171. }
  11172. if skippy < 0 {
  11173. return ErrInvalidLengthControl
  11174. }
  11175. if (iNdEx + skippy) > l {
  11176. return io.ErrUnexpectedEOF
  11177. }
  11178. iNdEx += skippy
  11179. }
  11180. }
  11181. if iNdEx > l {
  11182. return io.ErrUnexpectedEOF
  11183. }
  11184. return nil
  11185. }
  11186. func (m *ListClustersResponse) Unmarshal(data []byte) error {
  11187. l := len(data)
  11188. iNdEx := 0
  11189. for iNdEx < l {
  11190. preIndex := iNdEx
  11191. var wire uint64
  11192. for shift := uint(0); ; shift += 7 {
  11193. if shift >= 64 {
  11194. return ErrIntOverflowControl
  11195. }
  11196. if iNdEx >= l {
  11197. return io.ErrUnexpectedEOF
  11198. }
  11199. b := data[iNdEx]
  11200. iNdEx++
  11201. wire |= (uint64(b) & 0x7F) << shift
  11202. if b < 0x80 {
  11203. break
  11204. }
  11205. }
  11206. fieldNum := int32(wire >> 3)
  11207. wireType := int(wire & 0x7)
  11208. if wireType == 4 {
  11209. return fmt.Errorf("proto: ListClustersResponse: wiretype end group for non-group")
  11210. }
  11211. if fieldNum <= 0 {
  11212. return fmt.Errorf("proto: ListClustersResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  11213. }
  11214. switch fieldNum {
  11215. case 1:
  11216. if wireType != 2 {
  11217. return fmt.Errorf("proto: wrong wireType = %d for field Clusters", wireType)
  11218. }
  11219. var msglen int
  11220. for shift := uint(0); ; shift += 7 {
  11221. if shift >= 64 {
  11222. return ErrIntOverflowControl
  11223. }
  11224. if iNdEx >= l {
  11225. return io.ErrUnexpectedEOF
  11226. }
  11227. b := data[iNdEx]
  11228. iNdEx++
  11229. msglen |= (int(b) & 0x7F) << shift
  11230. if b < 0x80 {
  11231. break
  11232. }
  11233. }
  11234. if msglen < 0 {
  11235. return ErrInvalidLengthControl
  11236. }
  11237. postIndex := iNdEx + msglen
  11238. if postIndex > l {
  11239. return io.ErrUnexpectedEOF
  11240. }
  11241. m.Clusters = append(m.Clusters, &Cluster{})
  11242. if err := m.Clusters[len(m.Clusters)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  11243. return err
  11244. }
  11245. iNdEx = postIndex
  11246. default:
  11247. iNdEx = preIndex
  11248. skippy, err := skipControl(data[iNdEx:])
  11249. if err != nil {
  11250. return err
  11251. }
  11252. if skippy < 0 {
  11253. return ErrInvalidLengthControl
  11254. }
  11255. if (iNdEx + skippy) > l {
  11256. return io.ErrUnexpectedEOF
  11257. }
  11258. iNdEx += skippy
  11259. }
  11260. }
  11261. if iNdEx > l {
  11262. return io.ErrUnexpectedEOF
  11263. }
  11264. return nil
  11265. }
  11266. func (m *KeyRotation) Unmarshal(data []byte) error {
  11267. l := len(data)
  11268. iNdEx := 0
  11269. for iNdEx < l {
  11270. preIndex := iNdEx
  11271. var wire uint64
  11272. for shift := uint(0); ; shift += 7 {
  11273. if shift >= 64 {
  11274. return ErrIntOverflowControl
  11275. }
  11276. if iNdEx >= l {
  11277. return io.ErrUnexpectedEOF
  11278. }
  11279. b := data[iNdEx]
  11280. iNdEx++
  11281. wire |= (uint64(b) & 0x7F) << shift
  11282. if b < 0x80 {
  11283. break
  11284. }
  11285. }
  11286. fieldNum := int32(wire >> 3)
  11287. wireType := int(wire & 0x7)
  11288. if wireType == 4 {
  11289. return fmt.Errorf("proto: KeyRotation: wiretype end group for non-group")
  11290. }
  11291. if fieldNum <= 0 {
  11292. return fmt.Errorf("proto: KeyRotation: illegal tag %d (wire type %d)", fieldNum, wire)
  11293. }
  11294. switch fieldNum {
  11295. case 1:
  11296. if wireType != 0 {
  11297. return fmt.Errorf("proto: wrong wireType = %d for field WorkerJoinToken", wireType)
  11298. }
  11299. var v int
  11300. for shift := uint(0); ; shift += 7 {
  11301. if shift >= 64 {
  11302. return ErrIntOverflowControl
  11303. }
  11304. if iNdEx >= l {
  11305. return io.ErrUnexpectedEOF
  11306. }
  11307. b := data[iNdEx]
  11308. iNdEx++
  11309. v |= (int(b) & 0x7F) << shift
  11310. if b < 0x80 {
  11311. break
  11312. }
  11313. }
  11314. m.WorkerJoinToken = bool(v != 0)
  11315. case 2:
  11316. if wireType != 0 {
  11317. return fmt.Errorf("proto: wrong wireType = %d for field ManagerJoinToken", wireType)
  11318. }
  11319. var v int
  11320. for shift := uint(0); ; shift += 7 {
  11321. if shift >= 64 {
  11322. return ErrIntOverflowControl
  11323. }
  11324. if iNdEx >= l {
  11325. return io.ErrUnexpectedEOF
  11326. }
  11327. b := data[iNdEx]
  11328. iNdEx++
  11329. v |= (int(b) & 0x7F) << shift
  11330. if b < 0x80 {
  11331. break
  11332. }
  11333. }
  11334. m.ManagerJoinToken = bool(v != 0)
  11335. case 3:
  11336. if wireType != 0 {
  11337. return fmt.Errorf("proto: wrong wireType = %d for field ManagerUnlockKey", wireType)
  11338. }
  11339. var v int
  11340. for shift := uint(0); ; shift += 7 {
  11341. if shift >= 64 {
  11342. return ErrIntOverflowControl
  11343. }
  11344. if iNdEx >= l {
  11345. return io.ErrUnexpectedEOF
  11346. }
  11347. b := data[iNdEx]
  11348. iNdEx++
  11349. v |= (int(b) & 0x7F) << shift
  11350. if b < 0x80 {
  11351. break
  11352. }
  11353. }
  11354. m.ManagerUnlockKey = bool(v != 0)
  11355. default:
  11356. iNdEx = preIndex
  11357. skippy, err := skipControl(data[iNdEx:])
  11358. if err != nil {
  11359. return err
  11360. }
  11361. if skippy < 0 {
  11362. return ErrInvalidLengthControl
  11363. }
  11364. if (iNdEx + skippy) > l {
  11365. return io.ErrUnexpectedEOF
  11366. }
  11367. iNdEx += skippy
  11368. }
  11369. }
  11370. if iNdEx > l {
  11371. return io.ErrUnexpectedEOF
  11372. }
  11373. return nil
  11374. }
  11375. func (m *UpdateClusterRequest) Unmarshal(data []byte) error {
  11376. l := len(data)
  11377. iNdEx := 0
  11378. for iNdEx < l {
  11379. preIndex := iNdEx
  11380. var wire uint64
  11381. for shift := uint(0); ; shift += 7 {
  11382. if shift >= 64 {
  11383. return ErrIntOverflowControl
  11384. }
  11385. if iNdEx >= l {
  11386. return io.ErrUnexpectedEOF
  11387. }
  11388. b := data[iNdEx]
  11389. iNdEx++
  11390. wire |= (uint64(b) & 0x7F) << shift
  11391. if b < 0x80 {
  11392. break
  11393. }
  11394. }
  11395. fieldNum := int32(wire >> 3)
  11396. wireType := int(wire & 0x7)
  11397. if wireType == 4 {
  11398. return fmt.Errorf("proto: UpdateClusterRequest: wiretype end group for non-group")
  11399. }
  11400. if fieldNum <= 0 {
  11401. return fmt.Errorf("proto: UpdateClusterRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  11402. }
  11403. switch fieldNum {
  11404. case 1:
  11405. if wireType != 2 {
  11406. return fmt.Errorf("proto: wrong wireType = %d for field ClusterID", wireType)
  11407. }
  11408. var stringLen uint64
  11409. for shift := uint(0); ; shift += 7 {
  11410. if shift >= 64 {
  11411. return ErrIntOverflowControl
  11412. }
  11413. if iNdEx >= l {
  11414. return io.ErrUnexpectedEOF
  11415. }
  11416. b := data[iNdEx]
  11417. iNdEx++
  11418. stringLen |= (uint64(b) & 0x7F) << shift
  11419. if b < 0x80 {
  11420. break
  11421. }
  11422. }
  11423. intStringLen := int(stringLen)
  11424. if intStringLen < 0 {
  11425. return ErrInvalidLengthControl
  11426. }
  11427. postIndex := iNdEx + intStringLen
  11428. if postIndex > l {
  11429. return io.ErrUnexpectedEOF
  11430. }
  11431. m.ClusterID = string(data[iNdEx:postIndex])
  11432. iNdEx = postIndex
  11433. case 2:
  11434. if wireType != 2 {
  11435. return fmt.Errorf("proto: wrong wireType = %d for field ClusterVersion", wireType)
  11436. }
  11437. var msglen int
  11438. for shift := uint(0); ; shift += 7 {
  11439. if shift >= 64 {
  11440. return ErrIntOverflowControl
  11441. }
  11442. if iNdEx >= l {
  11443. return io.ErrUnexpectedEOF
  11444. }
  11445. b := data[iNdEx]
  11446. iNdEx++
  11447. msglen |= (int(b) & 0x7F) << shift
  11448. if b < 0x80 {
  11449. break
  11450. }
  11451. }
  11452. if msglen < 0 {
  11453. return ErrInvalidLengthControl
  11454. }
  11455. postIndex := iNdEx + msglen
  11456. if postIndex > l {
  11457. return io.ErrUnexpectedEOF
  11458. }
  11459. if m.ClusterVersion == nil {
  11460. m.ClusterVersion = &Version{}
  11461. }
  11462. if err := m.ClusterVersion.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11463. return err
  11464. }
  11465. iNdEx = postIndex
  11466. case 3:
  11467. if wireType != 2 {
  11468. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  11469. }
  11470. var msglen int
  11471. for shift := uint(0); ; shift += 7 {
  11472. if shift >= 64 {
  11473. return ErrIntOverflowControl
  11474. }
  11475. if iNdEx >= l {
  11476. return io.ErrUnexpectedEOF
  11477. }
  11478. b := data[iNdEx]
  11479. iNdEx++
  11480. msglen |= (int(b) & 0x7F) << shift
  11481. if b < 0x80 {
  11482. break
  11483. }
  11484. }
  11485. if msglen < 0 {
  11486. return ErrInvalidLengthControl
  11487. }
  11488. postIndex := iNdEx + msglen
  11489. if postIndex > l {
  11490. return io.ErrUnexpectedEOF
  11491. }
  11492. if m.Spec == nil {
  11493. m.Spec = &ClusterSpec{}
  11494. }
  11495. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11496. return err
  11497. }
  11498. iNdEx = postIndex
  11499. case 4:
  11500. if wireType != 2 {
  11501. return fmt.Errorf("proto: wrong wireType = %d for field Rotation", wireType)
  11502. }
  11503. var msglen int
  11504. for shift := uint(0); ; shift += 7 {
  11505. if shift >= 64 {
  11506. return ErrIntOverflowControl
  11507. }
  11508. if iNdEx >= l {
  11509. return io.ErrUnexpectedEOF
  11510. }
  11511. b := data[iNdEx]
  11512. iNdEx++
  11513. msglen |= (int(b) & 0x7F) << shift
  11514. if b < 0x80 {
  11515. break
  11516. }
  11517. }
  11518. if msglen < 0 {
  11519. return ErrInvalidLengthControl
  11520. }
  11521. postIndex := iNdEx + msglen
  11522. if postIndex > l {
  11523. return io.ErrUnexpectedEOF
  11524. }
  11525. if err := m.Rotation.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11526. return err
  11527. }
  11528. iNdEx = postIndex
  11529. default:
  11530. iNdEx = preIndex
  11531. skippy, err := skipControl(data[iNdEx:])
  11532. if err != nil {
  11533. return err
  11534. }
  11535. if skippy < 0 {
  11536. return ErrInvalidLengthControl
  11537. }
  11538. if (iNdEx + skippy) > l {
  11539. return io.ErrUnexpectedEOF
  11540. }
  11541. iNdEx += skippy
  11542. }
  11543. }
  11544. if iNdEx > l {
  11545. return io.ErrUnexpectedEOF
  11546. }
  11547. return nil
  11548. }
  11549. func (m *UpdateClusterResponse) Unmarshal(data []byte) error {
  11550. l := len(data)
  11551. iNdEx := 0
  11552. for iNdEx < l {
  11553. preIndex := iNdEx
  11554. var wire uint64
  11555. for shift := uint(0); ; shift += 7 {
  11556. if shift >= 64 {
  11557. return ErrIntOverflowControl
  11558. }
  11559. if iNdEx >= l {
  11560. return io.ErrUnexpectedEOF
  11561. }
  11562. b := data[iNdEx]
  11563. iNdEx++
  11564. wire |= (uint64(b) & 0x7F) << shift
  11565. if b < 0x80 {
  11566. break
  11567. }
  11568. }
  11569. fieldNum := int32(wire >> 3)
  11570. wireType := int(wire & 0x7)
  11571. if wireType == 4 {
  11572. return fmt.Errorf("proto: UpdateClusterResponse: wiretype end group for non-group")
  11573. }
  11574. if fieldNum <= 0 {
  11575. return fmt.Errorf("proto: UpdateClusterResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  11576. }
  11577. switch fieldNum {
  11578. case 1:
  11579. if wireType != 2 {
  11580. return fmt.Errorf("proto: wrong wireType = %d for field Cluster", wireType)
  11581. }
  11582. var msglen int
  11583. for shift := uint(0); ; shift += 7 {
  11584. if shift >= 64 {
  11585. return ErrIntOverflowControl
  11586. }
  11587. if iNdEx >= l {
  11588. return io.ErrUnexpectedEOF
  11589. }
  11590. b := data[iNdEx]
  11591. iNdEx++
  11592. msglen |= (int(b) & 0x7F) << shift
  11593. if b < 0x80 {
  11594. break
  11595. }
  11596. }
  11597. if msglen < 0 {
  11598. return ErrInvalidLengthControl
  11599. }
  11600. postIndex := iNdEx + msglen
  11601. if postIndex > l {
  11602. return io.ErrUnexpectedEOF
  11603. }
  11604. if m.Cluster == nil {
  11605. m.Cluster = &Cluster{}
  11606. }
  11607. if err := m.Cluster.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11608. return err
  11609. }
  11610. iNdEx = postIndex
  11611. default:
  11612. iNdEx = preIndex
  11613. skippy, err := skipControl(data[iNdEx:])
  11614. if err != nil {
  11615. return err
  11616. }
  11617. if skippy < 0 {
  11618. return ErrInvalidLengthControl
  11619. }
  11620. if (iNdEx + skippy) > l {
  11621. return io.ErrUnexpectedEOF
  11622. }
  11623. iNdEx += skippy
  11624. }
  11625. }
  11626. if iNdEx > l {
  11627. return io.ErrUnexpectedEOF
  11628. }
  11629. return nil
  11630. }
  11631. func (m *GetSecretRequest) Unmarshal(data []byte) error {
  11632. l := len(data)
  11633. iNdEx := 0
  11634. for iNdEx < l {
  11635. preIndex := iNdEx
  11636. var wire uint64
  11637. for shift := uint(0); ; shift += 7 {
  11638. if shift >= 64 {
  11639. return ErrIntOverflowControl
  11640. }
  11641. if iNdEx >= l {
  11642. return io.ErrUnexpectedEOF
  11643. }
  11644. b := data[iNdEx]
  11645. iNdEx++
  11646. wire |= (uint64(b) & 0x7F) << shift
  11647. if b < 0x80 {
  11648. break
  11649. }
  11650. }
  11651. fieldNum := int32(wire >> 3)
  11652. wireType := int(wire & 0x7)
  11653. if wireType == 4 {
  11654. return fmt.Errorf("proto: GetSecretRequest: wiretype end group for non-group")
  11655. }
  11656. if fieldNum <= 0 {
  11657. return fmt.Errorf("proto: GetSecretRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  11658. }
  11659. switch fieldNum {
  11660. case 1:
  11661. if wireType != 2 {
  11662. return fmt.Errorf("proto: wrong wireType = %d for field SecretID", wireType)
  11663. }
  11664. var stringLen uint64
  11665. for shift := uint(0); ; shift += 7 {
  11666. if shift >= 64 {
  11667. return ErrIntOverflowControl
  11668. }
  11669. if iNdEx >= l {
  11670. return io.ErrUnexpectedEOF
  11671. }
  11672. b := data[iNdEx]
  11673. iNdEx++
  11674. stringLen |= (uint64(b) & 0x7F) << shift
  11675. if b < 0x80 {
  11676. break
  11677. }
  11678. }
  11679. intStringLen := int(stringLen)
  11680. if intStringLen < 0 {
  11681. return ErrInvalidLengthControl
  11682. }
  11683. postIndex := iNdEx + intStringLen
  11684. if postIndex > l {
  11685. return io.ErrUnexpectedEOF
  11686. }
  11687. m.SecretID = string(data[iNdEx:postIndex])
  11688. iNdEx = postIndex
  11689. default:
  11690. iNdEx = preIndex
  11691. skippy, err := skipControl(data[iNdEx:])
  11692. if err != nil {
  11693. return err
  11694. }
  11695. if skippy < 0 {
  11696. return ErrInvalidLengthControl
  11697. }
  11698. if (iNdEx + skippy) > l {
  11699. return io.ErrUnexpectedEOF
  11700. }
  11701. iNdEx += skippy
  11702. }
  11703. }
  11704. if iNdEx > l {
  11705. return io.ErrUnexpectedEOF
  11706. }
  11707. return nil
  11708. }
  11709. func (m *GetSecretResponse) Unmarshal(data []byte) error {
  11710. l := len(data)
  11711. iNdEx := 0
  11712. for iNdEx < l {
  11713. preIndex := iNdEx
  11714. var wire uint64
  11715. for shift := uint(0); ; shift += 7 {
  11716. if shift >= 64 {
  11717. return ErrIntOverflowControl
  11718. }
  11719. if iNdEx >= l {
  11720. return io.ErrUnexpectedEOF
  11721. }
  11722. b := data[iNdEx]
  11723. iNdEx++
  11724. wire |= (uint64(b) & 0x7F) << shift
  11725. if b < 0x80 {
  11726. break
  11727. }
  11728. }
  11729. fieldNum := int32(wire >> 3)
  11730. wireType := int(wire & 0x7)
  11731. if wireType == 4 {
  11732. return fmt.Errorf("proto: GetSecretResponse: wiretype end group for non-group")
  11733. }
  11734. if fieldNum <= 0 {
  11735. return fmt.Errorf("proto: GetSecretResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  11736. }
  11737. switch fieldNum {
  11738. case 1:
  11739. if wireType != 2 {
  11740. return fmt.Errorf("proto: wrong wireType = %d for field Secret", wireType)
  11741. }
  11742. var msglen int
  11743. for shift := uint(0); ; shift += 7 {
  11744. if shift >= 64 {
  11745. return ErrIntOverflowControl
  11746. }
  11747. if iNdEx >= l {
  11748. return io.ErrUnexpectedEOF
  11749. }
  11750. b := data[iNdEx]
  11751. iNdEx++
  11752. msglen |= (int(b) & 0x7F) << shift
  11753. if b < 0x80 {
  11754. break
  11755. }
  11756. }
  11757. if msglen < 0 {
  11758. return ErrInvalidLengthControl
  11759. }
  11760. postIndex := iNdEx + msglen
  11761. if postIndex > l {
  11762. return io.ErrUnexpectedEOF
  11763. }
  11764. if m.Secret == nil {
  11765. m.Secret = &Secret{}
  11766. }
  11767. if err := m.Secret.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11768. return err
  11769. }
  11770. iNdEx = postIndex
  11771. default:
  11772. iNdEx = preIndex
  11773. skippy, err := skipControl(data[iNdEx:])
  11774. if err != nil {
  11775. return err
  11776. }
  11777. if skippy < 0 {
  11778. return ErrInvalidLengthControl
  11779. }
  11780. if (iNdEx + skippy) > l {
  11781. return io.ErrUnexpectedEOF
  11782. }
  11783. iNdEx += skippy
  11784. }
  11785. }
  11786. if iNdEx > l {
  11787. return io.ErrUnexpectedEOF
  11788. }
  11789. return nil
  11790. }
  11791. func (m *UpdateSecretRequest) Unmarshal(data []byte) error {
  11792. l := len(data)
  11793. iNdEx := 0
  11794. for iNdEx < l {
  11795. preIndex := iNdEx
  11796. var wire uint64
  11797. for shift := uint(0); ; shift += 7 {
  11798. if shift >= 64 {
  11799. return ErrIntOverflowControl
  11800. }
  11801. if iNdEx >= l {
  11802. return io.ErrUnexpectedEOF
  11803. }
  11804. b := data[iNdEx]
  11805. iNdEx++
  11806. wire |= (uint64(b) & 0x7F) << shift
  11807. if b < 0x80 {
  11808. break
  11809. }
  11810. }
  11811. fieldNum := int32(wire >> 3)
  11812. wireType := int(wire & 0x7)
  11813. if wireType == 4 {
  11814. return fmt.Errorf("proto: UpdateSecretRequest: wiretype end group for non-group")
  11815. }
  11816. if fieldNum <= 0 {
  11817. return fmt.Errorf("proto: UpdateSecretRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  11818. }
  11819. switch fieldNum {
  11820. case 1:
  11821. if wireType != 2 {
  11822. return fmt.Errorf("proto: wrong wireType = %d for field SecretID", wireType)
  11823. }
  11824. var stringLen uint64
  11825. for shift := uint(0); ; shift += 7 {
  11826. if shift >= 64 {
  11827. return ErrIntOverflowControl
  11828. }
  11829. if iNdEx >= l {
  11830. return io.ErrUnexpectedEOF
  11831. }
  11832. b := data[iNdEx]
  11833. iNdEx++
  11834. stringLen |= (uint64(b) & 0x7F) << shift
  11835. if b < 0x80 {
  11836. break
  11837. }
  11838. }
  11839. intStringLen := int(stringLen)
  11840. if intStringLen < 0 {
  11841. return ErrInvalidLengthControl
  11842. }
  11843. postIndex := iNdEx + intStringLen
  11844. if postIndex > l {
  11845. return io.ErrUnexpectedEOF
  11846. }
  11847. m.SecretID = string(data[iNdEx:postIndex])
  11848. iNdEx = postIndex
  11849. case 2:
  11850. if wireType != 2 {
  11851. return fmt.Errorf("proto: wrong wireType = %d for field SecretVersion", wireType)
  11852. }
  11853. var msglen int
  11854. for shift := uint(0); ; shift += 7 {
  11855. if shift >= 64 {
  11856. return ErrIntOverflowControl
  11857. }
  11858. if iNdEx >= l {
  11859. return io.ErrUnexpectedEOF
  11860. }
  11861. b := data[iNdEx]
  11862. iNdEx++
  11863. msglen |= (int(b) & 0x7F) << shift
  11864. if b < 0x80 {
  11865. break
  11866. }
  11867. }
  11868. if msglen < 0 {
  11869. return ErrInvalidLengthControl
  11870. }
  11871. postIndex := iNdEx + msglen
  11872. if postIndex > l {
  11873. return io.ErrUnexpectedEOF
  11874. }
  11875. if m.SecretVersion == nil {
  11876. m.SecretVersion = &Version{}
  11877. }
  11878. if err := m.SecretVersion.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11879. return err
  11880. }
  11881. iNdEx = postIndex
  11882. case 3:
  11883. if wireType != 2 {
  11884. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  11885. }
  11886. var msglen int
  11887. for shift := uint(0); ; shift += 7 {
  11888. if shift >= 64 {
  11889. return ErrIntOverflowControl
  11890. }
  11891. if iNdEx >= l {
  11892. return io.ErrUnexpectedEOF
  11893. }
  11894. b := data[iNdEx]
  11895. iNdEx++
  11896. msglen |= (int(b) & 0x7F) << shift
  11897. if b < 0x80 {
  11898. break
  11899. }
  11900. }
  11901. if msglen < 0 {
  11902. return ErrInvalidLengthControl
  11903. }
  11904. postIndex := iNdEx + msglen
  11905. if postIndex > l {
  11906. return io.ErrUnexpectedEOF
  11907. }
  11908. if m.Spec == nil {
  11909. m.Spec = &SecretSpec{}
  11910. }
  11911. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11912. return err
  11913. }
  11914. iNdEx = postIndex
  11915. default:
  11916. iNdEx = preIndex
  11917. skippy, err := skipControl(data[iNdEx:])
  11918. if err != nil {
  11919. return err
  11920. }
  11921. if skippy < 0 {
  11922. return ErrInvalidLengthControl
  11923. }
  11924. if (iNdEx + skippy) > l {
  11925. return io.ErrUnexpectedEOF
  11926. }
  11927. iNdEx += skippy
  11928. }
  11929. }
  11930. if iNdEx > l {
  11931. return io.ErrUnexpectedEOF
  11932. }
  11933. return nil
  11934. }
  11935. func (m *UpdateSecretResponse) Unmarshal(data []byte) error {
  11936. l := len(data)
  11937. iNdEx := 0
  11938. for iNdEx < l {
  11939. preIndex := iNdEx
  11940. var wire uint64
  11941. for shift := uint(0); ; shift += 7 {
  11942. if shift >= 64 {
  11943. return ErrIntOverflowControl
  11944. }
  11945. if iNdEx >= l {
  11946. return io.ErrUnexpectedEOF
  11947. }
  11948. b := data[iNdEx]
  11949. iNdEx++
  11950. wire |= (uint64(b) & 0x7F) << shift
  11951. if b < 0x80 {
  11952. break
  11953. }
  11954. }
  11955. fieldNum := int32(wire >> 3)
  11956. wireType := int(wire & 0x7)
  11957. if wireType == 4 {
  11958. return fmt.Errorf("proto: UpdateSecretResponse: wiretype end group for non-group")
  11959. }
  11960. if fieldNum <= 0 {
  11961. return fmt.Errorf("proto: UpdateSecretResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  11962. }
  11963. switch fieldNum {
  11964. case 1:
  11965. if wireType != 2 {
  11966. return fmt.Errorf("proto: wrong wireType = %d for field Secret", wireType)
  11967. }
  11968. var msglen int
  11969. for shift := uint(0); ; shift += 7 {
  11970. if shift >= 64 {
  11971. return ErrIntOverflowControl
  11972. }
  11973. if iNdEx >= l {
  11974. return io.ErrUnexpectedEOF
  11975. }
  11976. b := data[iNdEx]
  11977. iNdEx++
  11978. msglen |= (int(b) & 0x7F) << shift
  11979. if b < 0x80 {
  11980. break
  11981. }
  11982. }
  11983. if msglen < 0 {
  11984. return ErrInvalidLengthControl
  11985. }
  11986. postIndex := iNdEx + msglen
  11987. if postIndex > l {
  11988. return io.ErrUnexpectedEOF
  11989. }
  11990. if m.Secret == nil {
  11991. m.Secret = &Secret{}
  11992. }
  11993. if err := m.Secret.Unmarshal(data[iNdEx:postIndex]); err != nil {
  11994. return err
  11995. }
  11996. iNdEx = postIndex
  11997. default:
  11998. iNdEx = preIndex
  11999. skippy, err := skipControl(data[iNdEx:])
  12000. if err != nil {
  12001. return err
  12002. }
  12003. if skippy < 0 {
  12004. return ErrInvalidLengthControl
  12005. }
  12006. if (iNdEx + skippy) > l {
  12007. return io.ErrUnexpectedEOF
  12008. }
  12009. iNdEx += skippy
  12010. }
  12011. }
  12012. if iNdEx > l {
  12013. return io.ErrUnexpectedEOF
  12014. }
  12015. return nil
  12016. }
  12017. func (m *ListSecretsRequest) Unmarshal(data []byte) error {
  12018. l := len(data)
  12019. iNdEx := 0
  12020. for iNdEx < l {
  12021. preIndex := iNdEx
  12022. var wire uint64
  12023. for shift := uint(0); ; shift += 7 {
  12024. if shift >= 64 {
  12025. return ErrIntOverflowControl
  12026. }
  12027. if iNdEx >= l {
  12028. return io.ErrUnexpectedEOF
  12029. }
  12030. b := data[iNdEx]
  12031. iNdEx++
  12032. wire |= (uint64(b) & 0x7F) << shift
  12033. if b < 0x80 {
  12034. break
  12035. }
  12036. }
  12037. fieldNum := int32(wire >> 3)
  12038. wireType := int(wire & 0x7)
  12039. if wireType == 4 {
  12040. return fmt.Errorf("proto: ListSecretsRequest: wiretype end group for non-group")
  12041. }
  12042. if fieldNum <= 0 {
  12043. return fmt.Errorf("proto: ListSecretsRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  12044. }
  12045. switch fieldNum {
  12046. case 1:
  12047. if wireType != 2 {
  12048. return fmt.Errorf("proto: wrong wireType = %d for field Filters", wireType)
  12049. }
  12050. var msglen int
  12051. for shift := uint(0); ; shift += 7 {
  12052. if shift >= 64 {
  12053. return ErrIntOverflowControl
  12054. }
  12055. if iNdEx >= l {
  12056. return io.ErrUnexpectedEOF
  12057. }
  12058. b := data[iNdEx]
  12059. iNdEx++
  12060. msglen |= (int(b) & 0x7F) << shift
  12061. if b < 0x80 {
  12062. break
  12063. }
  12064. }
  12065. if msglen < 0 {
  12066. return ErrInvalidLengthControl
  12067. }
  12068. postIndex := iNdEx + msglen
  12069. if postIndex > l {
  12070. return io.ErrUnexpectedEOF
  12071. }
  12072. if m.Filters == nil {
  12073. m.Filters = &ListSecretsRequest_Filters{}
  12074. }
  12075. if err := m.Filters.Unmarshal(data[iNdEx:postIndex]); err != nil {
  12076. return err
  12077. }
  12078. iNdEx = postIndex
  12079. default:
  12080. iNdEx = preIndex
  12081. skippy, err := skipControl(data[iNdEx:])
  12082. if err != nil {
  12083. return err
  12084. }
  12085. if skippy < 0 {
  12086. return ErrInvalidLengthControl
  12087. }
  12088. if (iNdEx + skippy) > l {
  12089. return io.ErrUnexpectedEOF
  12090. }
  12091. iNdEx += skippy
  12092. }
  12093. }
  12094. if iNdEx > l {
  12095. return io.ErrUnexpectedEOF
  12096. }
  12097. return nil
  12098. }
  12099. func (m *ListSecretsRequest_Filters) Unmarshal(data []byte) error {
  12100. l := len(data)
  12101. iNdEx := 0
  12102. for iNdEx < l {
  12103. preIndex := iNdEx
  12104. var wire uint64
  12105. for shift := uint(0); ; shift += 7 {
  12106. if shift >= 64 {
  12107. return ErrIntOverflowControl
  12108. }
  12109. if iNdEx >= l {
  12110. return io.ErrUnexpectedEOF
  12111. }
  12112. b := data[iNdEx]
  12113. iNdEx++
  12114. wire |= (uint64(b) & 0x7F) << shift
  12115. if b < 0x80 {
  12116. break
  12117. }
  12118. }
  12119. fieldNum := int32(wire >> 3)
  12120. wireType := int(wire & 0x7)
  12121. if wireType == 4 {
  12122. return fmt.Errorf("proto: Filters: wiretype end group for non-group")
  12123. }
  12124. if fieldNum <= 0 {
  12125. return fmt.Errorf("proto: Filters: illegal tag %d (wire type %d)", fieldNum, wire)
  12126. }
  12127. switch fieldNum {
  12128. case 1:
  12129. if wireType != 2 {
  12130. return fmt.Errorf("proto: wrong wireType = %d for field Names", wireType)
  12131. }
  12132. var stringLen uint64
  12133. for shift := uint(0); ; shift += 7 {
  12134. if shift >= 64 {
  12135. return ErrIntOverflowControl
  12136. }
  12137. if iNdEx >= l {
  12138. return io.ErrUnexpectedEOF
  12139. }
  12140. b := data[iNdEx]
  12141. iNdEx++
  12142. stringLen |= (uint64(b) & 0x7F) << shift
  12143. if b < 0x80 {
  12144. break
  12145. }
  12146. }
  12147. intStringLen := int(stringLen)
  12148. if intStringLen < 0 {
  12149. return ErrInvalidLengthControl
  12150. }
  12151. postIndex := iNdEx + intStringLen
  12152. if postIndex > l {
  12153. return io.ErrUnexpectedEOF
  12154. }
  12155. m.Names = append(m.Names, string(data[iNdEx:postIndex]))
  12156. iNdEx = postIndex
  12157. case 2:
  12158. if wireType != 2 {
  12159. return fmt.Errorf("proto: wrong wireType = %d for field IDPrefixes", wireType)
  12160. }
  12161. var stringLen uint64
  12162. for shift := uint(0); ; shift += 7 {
  12163. if shift >= 64 {
  12164. return ErrIntOverflowControl
  12165. }
  12166. if iNdEx >= l {
  12167. return io.ErrUnexpectedEOF
  12168. }
  12169. b := data[iNdEx]
  12170. iNdEx++
  12171. stringLen |= (uint64(b) & 0x7F) << shift
  12172. if b < 0x80 {
  12173. break
  12174. }
  12175. }
  12176. intStringLen := int(stringLen)
  12177. if intStringLen < 0 {
  12178. return ErrInvalidLengthControl
  12179. }
  12180. postIndex := iNdEx + intStringLen
  12181. if postIndex > l {
  12182. return io.ErrUnexpectedEOF
  12183. }
  12184. m.IDPrefixes = append(m.IDPrefixes, string(data[iNdEx:postIndex]))
  12185. iNdEx = postIndex
  12186. case 3:
  12187. if wireType != 2 {
  12188. return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType)
  12189. }
  12190. var msglen int
  12191. for shift := uint(0); ; shift += 7 {
  12192. if shift >= 64 {
  12193. return ErrIntOverflowControl
  12194. }
  12195. if iNdEx >= l {
  12196. return io.ErrUnexpectedEOF
  12197. }
  12198. b := data[iNdEx]
  12199. iNdEx++
  12200. msglen |= (int(b) & 0x7F) << shift
  12201. if b < 0x80 {
  12202. break
  12203. }
  12204. }
  12205. if msglen < 0 {
  12206. return ErrInvalidLengthControl
  12207. }
  12208. postIndex := iNdEx + msglen
  12209. if postIndex > l {
  12210. return io.ErrUnexpectedEOF
  12211. }
  12212. var keykey uint64
  12213. for shift := uint(0); ; shift += 7 {
  12214. if shift >= 64 {
  12215. return ErrIntOverflowControl
  12216. }
  12217. if iNdEx >= l {
  12218. return io.ErrUnexpectedEOF
  12219. }
  12220. b := data[iNdEx]
  12221. iNdEx++
  12222. keykey |= (uint64(b) & 0x7F) << shift
  12223. if b < 0x80 {
  12224. break
  12225. }
  12226. }
  12227. var stringLenmapkey uint64
  12228. for shift := uint(0); ; shift += 7 {
  12229. if shift >= 64 {
  12230. return ErrIntOverflowControl
  12231. }
  12232. if iNdEx >= l {
  12233. return io.ErrUnexpectedEOF
  12234. }
  12235. b := data[iNdEx]
  12236. iNdEx++
  12237. stringLenmapkey |= (uint64(b) & 0x7F) << shift
  12238. if b < 0x80 {
  12239. break
  12240. }
  12241. }
  12242. intStringLenmapkey := int(stringLenmapkey)
  12243. if intStringLenmapkey < 0 {
  12244. return ErrInvalidLengthControl
  12245. }
  12246. postStringIndexmapkey := iNdEx + intStringLenmapkey
  12247. if postStringIndexmapkey > l {
  12248. return io.ErrUnexpectedEOF
  12249. }
  12250. mapkey := string(data[iNdEx:postStringIndexmapkey])
  12251. iNdEx = postStringIndexmapkey
  12252. if m.Labels == nil {
  12253. m.Labels = make(map[string]string)
  12254. }
  12255. if iNdEx < postIndex {
  12256. var valuekey uint64
  12257. for shift := uint(0); ; shift += 7 {
  12258. if shift >= 64 {
  12259. return ErrIntOverflowControl
  12260. }
  12261. if iNdEx >= l {
  12262. return io.ErrUnexpectedEOF
  12263. }
  12264. b := data[iNdEx]
  12265. iNdEx++
  12266. valuekey |= (uint64(b) & 0x7F) << shift
  12267. if b < 0x80 {
  12268. break
  12269. }
  12270. }
  12271. var stringLenmapvalue uint64
  12272. for shift := uint(0); ; shift += 7 {
  12273. if shift >= 64 {
  12274. return ErrIntOverflowControl
  12275. }
  12276. if iNdEx >= l {
  12277. return io.ErrUnexpectedEOF
  12278. }
  12279. b := data[iNdEx]
  12280. iNdEx++
  12281. stringLenmapvalue |= (uint64(b) & 0x7F) << shift
  12282. if b < 0x80 {
  12283. break
  12284. }
  12285. }
  12286. intStringLenmapvalue := int(stringLenmapvalue)
  12287. if intStringLenmapvalue < 0 {
  12288. return ErrInvalidLengthControl
  12289. }
  12290. postStringIndexmapvalue := iNdEx + intStringLenmapvalue
  12291. if postStringIndexmapvalue > l {
  12292. return io.ErrUnexpectedEOF
  12293. }
  12294. mapvalue := string(data[iNdEx:postStringIndexmapvalue])
  12295. iNdEx = postStringIndexmapvalue
  12296. m.Labels[mapkey] = mapvalue
  12297. } else {
  12298. var mapvalue string
  12299. m.Labels[mapkey] = mapvalue
  12300. }
  12301. iNdEx = postIndex
  12302. case 4:
  12303. if wireType != 2 {
  12304. return fmt.Errorf("proto: wrong wireType = %d for field NamePrefixes", wireType)
  12305. }
  12306. var stringLen uint64
  12307. for shift := uint(0); ; shift += 7 {
  12308. if shift >= 64 {
  12309. return ErrIntOverflowControl
  12310. }
  12311. if iNdEx >= l {
  12312. return io.ErrUnexpectedEOF
  12313. }
  12314. b := data[iNdEx]
  12315. iNdEx++
  12316. stringLen |= (uint64(b) & 0x7F) << shift
  12317. if b < 0x80 {
  12318. break
  12319. }
  12320. }
  12321. intStringLen := int(stringLen)
  12322. if intStringLen < 0 {
  12323. return ErrInvalidLengthControl
  12324. }
  12325. postIndex := iNdEx + intStringLen
  12326. if postIndex > l {
  12327. return io.ErrUnexpectedEOF
  12328. }
  12329. m.NamePrefixes = append(m.NamePrefixes, string(data[iNdEx:postIndex]))
  12330. iNdEx = postIndex
  12331. default:
  12332. iNdEx = preIndex
  12333. skippy, err := skipControl(data[iNdEx:])
  12334. if err != nil {
  12335. return err
  12336. }
  12337. if skippy < 0 {
  12338. return ErrInvalidLengthControl
  12339. }
  12340. if (iNdEx + skippy) > l {
  12341. return io.ErrUnexpectedEOF
  12342. }
  12343. iNdEx += skippy
  12344. }
  12345. }
  12346. if iNdEx > l {
  12347. return io.ErrUnexpectedEOF
  12348. }
  12349. return nil
  12350. }
  12351. func (m *ListSecretsResponse) Unmarshal(data []byte) error {
  12352. l := len(data)
  12353. iNdEx := 0
  12354. for iNdEx < l {
  12355. preIndex := iNdEx
  12356. var wire uint64
  12357. for shift := uint(0); ; shift += 7 {
  12358. if shift >= 64 {
  12359. return ErrIntOverflowControl
  12360. }
  12361. if iNdEx >= l {
  12362. return io.ErrUnexpectedEOF
  12363. }
  12364. b := data[iNdEx]
  12365. iNdEx++
  12366. wire |= (uint64(b) & 0x7F) << shift
  12367. if b < 0x80 {
  12368. break
  12369. }
  12370. }
  12371. fieldNum := int32(wire >> 3)
  12372. wireType := int(wire & 0x7)
  12373. if wireType == 4 {
  12374. return fmt.Errorf("proto: ListSecretsResponse: wiretype end group for non-group")
  12375. }
  12376. if fieldNum <= 0 {
  12377. return fmt.Errorf("proto: ListSecretsResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  12378. }
  12379. switch fieldNum {
  12380. case 1:
  12381. if wireType != 2 {
  12382. return fmt.Errorf("proto: wrong wireType = %d for field Secrets", wireType)
  12383. }
  12384. var msglen int
  12385. for shift := uint(0); ; shift += 7 {
  12386. if shift >= 64 {
  12387. return ErrIntOverflowControl
  12388. }
  12389. if iNdEx >= l {
  12390. return io.ErrUnexpectedEOF
  12391. }
  12392. b := data[iNdEx]
  12393. iNdEx++
  12394. msglen |= (int(b) & 0x7F) << shift
  12395. if b < 0x80 {
  12396. break
  12397. }
  12398. }
  12399. if msglen < 0 {
  12400. return ErrInvalidLengthControl
  12401. }
  12402. postIndex := iNdEx + msglen
  12403. if postIndex > l {
  12404. return io.ErrUnexpectedEOF
  12405. }
  12406. m.Secrets = append(m.Secrets, &Secret{})
  12407. if err := m.Secrets[len(m.Secrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil {
  12408. return err
  12409. }
  12410. iNdEx = postIndex
  12411. default:
  12412. iNdEx = preIndex
  12413. skippy, err := skipControl(data[iNdEx:])
  12414. if err != nil {
  12415. return err
  12416. }
  12417. if skippy < 0 {
  12418. return ErrInvalidLengthControl
  12419. }
  12420. if (iNdEx + skippy) > l {
  12421. return io.ErrUnexpectedEOF
  12422. }
  12423. iNdEx += skippy
  12424. }
  12425. }
  12426. if iNdEx > l {
  12427. return io.ErrUnexpectedEOF
  12428. }
  12429. return nil
  12430. }
  12431. func (m *CreateSecretRequest) Unmarshal(data []byte) error {
  12432. l := len(data)
  12433. iNdEx := 0
  12434. for iNdEx < l {
  12435. preIndex := iNdEx
  12436. var wire uint64
  12437. for shift := uint(0); ; shift += 7 {
  12438. if shift >= 64 {
  12439. return ErrIntOverflowControl
  12440. }
  12441. if iNdEx >= l {
  12442. return io.ErrUnexpectedEOF
  12443. }
  12444. b := data[iNdEx]
  12445. iNdEx++
  12446. wire |= (uint64(b) & 0x7F) << shift
  12447. if b < 0x80 {
  12448. break
  12449. }
  12450. }
  12451. fieldNum := int32(wire >> 3)
  12452. wireType := int(wire & 0x7)
  12453. if wireType == 4 {
  12454. return fmt.Errorf("proto: CreateSecretRequest: wiretype end group for non-group")
  12455. }
  12456. if fieldNum <= 0 {
  12457. return fmt.Errorf("proto: CreateSecretRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  12458. }
  12459. switch fieldNum {
  12460. case 1:
  12461. if wireType != 2 {
  12462. return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
  12463. }
  12464. var msglen int
  12465. for shift := uint(0); ; shift += 7 {
  12466. if shift >= 64 {
  12467. return ErrIntOverflowControl
  12468. }
  12469. if iNdEx >= l {
  12470. return io.ErrUnexpectedEOF
  12471. }
  12472. b := data[iNdEx]
  12473. iNdEx++
  12474. msglen |= (int(b) & 0x7F) << shift
  12475. if b < 0x80 {
  12476. break
  12477. }
  12478. }
  12479. if msglen < 0 {
  12480. return ErrInvalidLengthControl
  12481. }
  12482. postIndex := iNdEx + msglen
  12483. if postIndex > l {
  12484. return io.ErrUnexpectedEOF
  12485. }
  12486. if m.Spec == nil {
  12487. m.Spec = &SecretSpec{}
  12488. }
  12489. if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil {
  12490. return err
  12491. }
  12492. iNdEx = postIndex
  12493. default:
  12494. iNdEx = preIndex
  12495. skippy, err := skipControl(data[iNdEx:])
  12496. if err != nil {
  12497. return err
  12498. }
  12499. if skippy < 0 {
  12500. return ErrInvalidLengthControl
  12501. }
  12502. if (iNdEx + skippy) > l {
  12503. return io.ErrUnexpectedEOF
  12504. }
  12505. iNdEx += skippy
  12506. }
  12507. }
  12508. if iNdEx > l {
  12509. return io.ErrUnexpectedEOF
  12510. }
  12511. return nil
  12512. }
  12513. func (m *CreateSecretResponse) Unmarshal(data []byte) error {
  12514. l := len(data)
  12515. iNdEx := 0
  12516. for iNdEx < l {
  12517. preIndex := iNdEx
  12518. var wire uint64
  12519. for shift := uint(0); ; shift += 7 {
  12520. if shift >= 64 {
  12521. return ErrIntOverflowControl
  12522. }
  12523. if iNdEx >= l {
  12524. return io.ErrUnexpectedEOF
  12525. }
  12526. b := data[iNdEx]
  12527. iNdEx++
  12528. wire |= (uint64(b) & 0x7F) << shift
  12529. if b < 0x80 {
  12530. break
  12531. }
  12532. }
  12533. fieldNum := int32(wire >> 3)
  12534. wireType := int(wire & 0x7)
  12535. if wireType == 4 {
  12536. return fmt.Errorf("proto: CreateSecretResponse: wiretype end group for non-group")
  12537. }
  12538. if fieldNum <= 0 {
  12539. return fmt.Errorf("proto: CreateSecretResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  12540. }
  12541. switch fieldNum {
  12542. case 1:
  12543. if wireType != 2 {
  12544. return fmt.Errorf("proto: wrong wireType = %d for field Secret", wireType)
  12545. }
  12546. var msglen int
  12547. for shift := uint(0); ; shift += 7 {
  12548. if shift >= 64 {
  12549. return ErrIntOverflowControl
  12550. }
  12551. if iNdEx >= l {
  12552. return io.ErrUnexpectedEOF
  12553. }
  12554. b := data[iNdEx]
  12555. iNdEx++
  12556. msglen |= (int(b) & 0x7F) << shift
  12557. if b < 0x80 {
  12558. break
  12559. }
  12560. }
  12561. if msglen < 0 {
  12562. return ErrInvalidLengthControl
  12563. }
  12564. postIndex := iNdEx + msglen
  12565. if postIndex > l {
  12566. return io.ErrUnexpectedEOF
  12567. }
  12568. if m.Secret == nil {
  12569. m.Secret = &Secret{}
  12570. }
  12571. if err := m.Secret.Unmarshal(data[iNdEx:postIndex]); err != nil {
  12572. return err
  12573. }
  12574. iNdEx = postIndex
  12575. default:
  12576. iNdEx = preIndex
  12577. skippy, err := skipControl(data[iNdEx:])
  12578. if err != nil {
  12579. return err
  12580. }
  12581. if skippy < 0 {
  12582. return ErrInvalidLengthControl
  12583. }
  12584. if (iNdEx + skippy) > l {
  12585. return io.ErrUnexpectedEOF
  12586. }
  12587. iNdEx += skippy
  12588. }
  12589. }
  12590. if iNdEx > l {
  12591. return io.ErrUnexpectedEOF
  12592. }
  12593. return nil
  12594. }
  12595. func (m *RemoveSecretRequest) Unmarshal(data []byte) error {
  12596. l := len(data)
  12597. iNdEx := 0
  12598. for iNdEx < l {
  12599. preIndex := iNdEx
  12600. var wire uint64
  12601. for shift := uint(0); ; shift += 7 {
  12602. if shift >= 64 {
  12603. return ErrIntOverflowControl
  12604. }
  12605. if iNdEx >= l {
  12606. return io.ErrUnexpectedEOF
  12607. }
  12608. b := data[iNdEx]
  12609. iNdEx++
  12610. wire |= (uint64(b) & 0x7F) << shift
  12611. if b < 0x80 {
  12612. break
  12613. }
  12614. }
  12615. fieldNum := int32(wire >> 3)
  12616. wireType := int(wire & 0x7)
  12617. if wireType == 4 {
  12618. return fmt.Errorf("proto: RemoveSecretRequest: wiretype end group for non-group")
  12619. }
  12620. if fieldNum <= 0 {
  12621. return fmt.Errorf("proto: RemoveSecretRequest: illegal tag %d (wire type %d)", fieldNum, wire)
  12622. }
  12623. switch fieldNum {
  12624. case 1:
  12625. if wireType != 2 {
  12626. return fmt.Errorf("proto: wrong wireType = %d for field SecretID", wireType)
  12627. }
  12628. var stringLen uint64
  12629. for shift := uint(0); ; shift += 7 {
  12630. if shift >= 64 {
  12631. return ErrIntOverflowControl
  12632. }
  12633. if iNdEx >= l {
  12634. return io.ErrUnexpectedEOF
  12635. }
  12636. b := data[iNdEx]
  12637. iNdEx++
  12638. stringLen |= (uint64(b) & 0x7F) << shift
  12639. if b < 0x80 {
  12640. break
  12641. }
  12642. }
  12643. intStringLen := int(stringLen)
  12644. if intStringLen < 0 {
  12645. return ErrInvalidLengthControl
  12646. }
  12647. postIndex := iNdEx + intStringLen
  12648. if postIndex > l {
  12649. return io.ErrUnexpectedEOF
  12650. }
  12651. m.SecretID = string(data[iNdEx:postIndex])
  12652. iNdEx = postIndex
  12653. default:
  12654. iNdEx = preIndex
  12655. skippy, err := skipControl(data[iNdEx:])
  12656. if err != nil {
  12657. return err
  12658. }
  12659. if skippy < 0 {
  12660. return ErrInvalidLengthControl
  12661. }
  12662. if (iNdEx + skippy) > l {
  12663. return io.ErrUnexpectedEOF
  12664. }
  12665. iNdEx += skippy
  12666. }
  12667. }
  12668. if iNdEx > l {
  12669. return io.ErrUnexpectedEOF
  12670. }
  12671. return nil
  12672. }
  12673. func (m *RemoveSecretResponse) Unmarshal(data []byte) error {
  12674. l := len(data)
  12675. iNdEx := 0
  12676. for iNdEx < l {
  12677. preIndex := iNdEx
  12678. var wire uint64
  12679. for shift := uint(0); ; shift += 7 {
  12680. if shift >= 64 {
  12681. return ErrIntOverflowControl
  12682. }
  12683. if iNdEx >= l {
  12684. return io.ErrUnexpectedEOF
  12685. }
  12686. b := data[iNdEx]
  12687. iNdEx++
  12688. wire |= (uint64(b) & 0x7F) << shift
  12689. if b < 0x80 {
  12690. break
  12691. }
  12692. }
  12693. fieldNum := int32(wire >> 3)
  12694. wireType := int(wire & 0x7)
  12695. if wireType == 4 {
  12696. return fmt.Errorf("proto: RemoveSecretResponse: wiretype end group for non-group")
  12697. }
  12698. if fieldNum <= 0 {
  12699. return fmt.Errorf("proto: RemoveSecretResponse: illegal tag %d (wire type %d)", fieldNum, wire)
  12700. }
  12701. switch fieldNum {
  12702. default:
  12703. iNdEx = preIndex
  12704. skippy, err := skipControl(data[iNdEx:])
  12705. if err != nil {
  12706. return err
  12707. }
  12708. if skippy < 0 {
  12709. return ErrInvalidLengthControl
  12710. }
  12711. if (iNdEx + skippy) > l {
  12712. return io.ErrUnexpectedEOF
  12713. }
  12714. iNdEx += skippy
  12715. }
  12716. }
  12717. if iNdEx > l {
  12718. return io.ErrUnexpectedEOF
  12719. }
  12720. return nil
  12721. }
  12722. func skipControl(data []byte) (n int, err error) {
  12723. l := len(data)
  12724. iNdEx := 0
  12725. for iNdEx < l {
  12726. var wire uint64
  12727. for shift := uint(0); ; shift += 7 {
  12728. if shift >= 64 {
  12729. return 0, ErrIntOverflowControl
  12730. }
  12731. if iNdEx >= l {
  12732. return 0, io.ErrUnexpectedEOF
  12733. }
  12734. b := data[iNdEx]
  12735. iNdEx++
  12736. wire |= (uint64(b) & 0x7F) << shift
  12737. if b < 0x80 {
  12738. break
  12739. }
  12740. }
  12741. wireType := int(wire & 0x7)
  12742. switch wireType {
  12743. case 0:
  12744. for shift := uint(0); ; shift += 7 {
  12745. if shift >= 64 {
  12746. return 0, ErrIntOverflowControl
  12747. }
  12748. if iNdEx >= l {
  12749. return 0, io.ErrUnexpectedEOF
  12750. }
  12751. iNdEx++
  12752. if data[iNdEx-1] < 0x80 {
  12753. break
  12754. }
  12755. }
  12756. return iNdEx, nil
  12757. case 1:
  12758. iNdEx += 8
  12759. return iNdEx, nil
  12760. case 2:
  12761. var length int
  12762. for shift := uint(0); ; shift += 7 {
  12763. if shift >= 64 {
  12764. return 0, ErrIntOverflowControl
  12765. }
  12766. if iNdEx >= l {
  12767. return 0, io.ErrUnexpectedEOF
  12768. }
  12769. b := data[iNdEx]
  12770. iNdEx++
  12771. length |= (int(b) & 0x7F) << shift
  12772. if b < 0x80 {
  12773. break
  12774. }
  12775. }
  12776. iNdEx += length
  12777. if length < 0 {
  12778. return 0, ErrInvalidLengthControl
  12779. }
  12780. return iNdEx, nil
  12781. case 3:
  12782. for {
  12783. var innerWire uint64
  12784. var start int = iNdEx
  12785. for shift := uint(0); ; shift += 7 {
  12786. if shift >= 64 {
  12787. return 0, ErrIntOverflowControl
  12788. }
  12789. if iNdEx >= l {
  12790. return 0, io.ErrUnexpectedEOF
  12791. }
  12792. b := data[iNdEx]
  12793. iNdEx++
  12794. innerWire |= (uint64(b) & 0x7F) << shift
  12795. if b < 0x80 {
  12796. break
  12797. }
  12798. }
  12799. innerWireType := int(innerWire & 0x7)
  12800. if innerWireType == 4 {
  12801. break
  12802. }
  12803. next, err := skipControl(data[start:])
  12804. if err != nil {
  12805. return 0, err
  12806. }
  12807. iNdEx = start + next
  12808. }
  12809. return iNdEx, nil
  12810. case 4:
  12811. return iNdEx, nil
  12812. case 5:
  12813. iNdEx += 4
  12814. return iNdEx, nil
  12815. default:
  12816. return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  12817. }
  12818. }
  12819. panic("unreachable")
  12820. }
  12821. var (
  12822. ErrInvalidLengthControl = fmt.Errorf("proto: negative length found during unmarshaling")
  12823. ErrIntOverflowControl = fmt.Errorf("proto: integer overflow")
  12824. )
  12825. func init() { proto.RegisterFile("control.proto", fileDescriptorControl) }
  12826. var fileDescriptorControl = []byte{
  12827. // 1781 bytes of a gzipped FileDescriptorProto
  12828. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xcc, 0x5a, 0xcd, 0x6f, 0x1b, 0x45,
  12829. 0x14, 0xaf, 0xed, 0x24, 0x4e, 0x9e, 0xe3, 0x7c, 0x4c, 0xdc, 0x62, 0x6d, 0x8b, 0x53, 0x6d, 0x69,
  12830. 0xea, 0xa0, 0xe0, 0x80, 0x4b, 0x45, 0x29, 0xe2, 0xa3, 0x8e, 0x69, 0x71, 0x53, 0x42, 0xb5, 0x69,
  12831. 0x11, 0xb7, 0xc8, 0xb1, 0xa7, 0x61, 0x6b, 0xc7, 0x6b, 0x76, 0x37, 0x69, 0x23, 0x2e, 0x80, 0xe0,
  12832. 0x4f, 0x40, 0xe2, 0xca, 0x15, 0x24, 0xce, 0xdc, 0xb8, 0x56, 0x9c, 0x38, 0x72, 0xb2, 0xa8, 0x25,
  12833. 0x24, 0x4e, 0x88, 0xbf, 0x00, 0xa1, 0xf9, 0xda, 0x2f, 0xcf, 0xee, 0xda, 0x71, 0x50, 0x7a, 0x8a,
  12834. 0x77, 0xf6, 0xf7, 0xe6, 0xbd, 0x99, 0xf7, 0x9b, 0xdf, 0xbe, 0x79, 0x0a, 0x64, 0x1b, 0x46, 0xc7,
  12835. 0x36, 0x8d, 0x76, 0xa9, 0x6b, 0x1a, 0xb6, 0x81, 0x50, 0xd3, 0x68, 0xb4, 0xb0, 0x59, 0xb2, 0x1e,
  12836. 0xd7, 0xcd, 0xfd, 0x96, 0x6e, 0x97, 0x0e, 0x5f, 0x53, 0x32, 0x56, 0x17, 0x37, 0x2c, 0x06, 0x50,
  12837. 0xb2, 0xc6, 0xee, 0x23, 0xdc, 0xb0, 0xc5, 0x63, 0xc6, 0x3e, 0xea, 0x62, 0xf1, 0x90, 0xdb, 0x33,
  12838. 0xf6, 0x0c, 0xfa, 0x73, 0x9d, 0xfc, 0xe2, 0xa3, 0x4b, 0xdd, 0xf6, 0xc1, 0x9e, 0xde, 0x59, 0x67,
  12839. 0x7f, 0xd8, 0xa0, 0x7a, 0x0d, 0xe6, 0x6e, 0x63, 0x7b, 0xcb, 0x68, 0x62, 0x0d, 0x7f, 0x76, 0x80,
  12840. 0x2d, 0x1b, 0x5d, 0x82, 0x74, 0xc7, 0x68, 0xe2, 0x1d, 0xbd, 0x99, 0x4f, 0x5c, 0x4c, 0x14, 0x67,
  12841. 0x2a, 0xd0, 0xef, 0x2d, 0x4f, 0x11, 0x44, 0xad, 0xaa, 0x4d, 0x91, 0x57, 0xb5, 0xa6, 0xfa, 0x2e,
  12842. 0xcc, 0x3b, 0x66, 0x56, 0xd7, 0xe8, 0x58, 0x18, 0xad, 0xc1, 0x04, 0x79, 0x49, 0x8d, 0x32, 0xe5,
  12843. 0x7c, 0x69, 0x70, 0x01, 0x25, 0x8a, 0xa7, 0x28, 0xb5, 0x97, 0x82, 0x85, 0xbb, 0xba, 0x45, 0xa7,
  12844. 0xb0, 0x84, 0xeb, 0x5b, 0x90, 0x7e, 0xa8, 0xb7, 0x6d, 0x6c, 0x5a, 0x7c, 0x96, 0x35, 0xd9, 0x2c,
  12845. 0x41, 0xb3, 0xd2, 0x2d, 0x66, 0xa3, 0x09, 0x63, 0xe5, 0xcb, 0x14, 0xa4, 0xf9, 0x20, 0xca, 0xc1,
  12846. 0x64, 0xa7, 0xbe, 0x8f, 0xc9, 0x8c, 0xa9, 0xe2, 0x8c, 0xc6, 0x1e, 0xd0, 0x3a, 0x64, 0xf4, 0xe6,
  12847. 0x4e, 0xd7, 0xc4, 0x0f, 0xf5, 0x27, 0xd8, 0xca, 0x27, 0xc9, 0xbb, 0xca, 0x5c, 0xbf, 0xb7, 0x0c,
  12848. 0xb5, 0xea, 0x3d, 0x3e, 0xaa, 0x81, 0xde, 0x14, 0xbf, 0xd1, 0x3d, 0x98, 0x6a, 0xd7, 0x77, 0x71,
  12849. 0xdb, 0xca, 0xa7, 0x2e, 0xa6, 0x8a, 0x99, 0xf2, 0xf5, 0x51, 0x22, 0x2b, 0xdd, 0xa5, 0xa6, 0xef,
  12850. 0x77, 0x6c, 0xf3, 0x48, 0xe3, 0xf3, 0xa0, 0x1a, 0x64, 0xf6, 0xf1, 0xfe, 0x2e, 0x36, 0xad, 0x4f,
  12851. 0xf5, 0xae, 0x95, 0x9f, 0xb8, 0x98, 0x2a, 0xce, 0x95, 0xaf, 0x84, 0x6d, 0xdb, 0x76, 0x17, 0x37,
  12852. 0x4a, 0x1f, 0x3a, 0x78, 0xcd, 0x6b, 0x8b, 0xca, 0x30, 0x69, 0x1a, 0x6d, 0x6c, 0xe5, 0x27, 0xe9,
  12853. 0x24, 0x17, 0x42, 0xf7, 0xde, 0x68, 0x63, 0x8d, 0x41, 0xd1, 0x25, 0xc8, 0x92, 0xad, 0x70, 0xf7,
  12854. 0x60, 0x8a, 0xee, 0xcf, 0x2c, 0x19, 0x14, 0xab, 0x56, 0xde, 0x84, 0x8c, 0x27, 0x74, 0xb4, 0x00,
  12855. 0xa9, 0x16, 0x3e, 0x62, 0xb4, 0xd0, 0xc8, 0x4f, 0xb2, 0xbb, 0x87, 0xf5, 0xf6, 0x01, 0xce, 0x27,
  12856. 0xe9, 0x18, 0x7b, 0xb8, 0x91, 0xbc, 0x9e, 0x50, 0x37, 0x60, 0xd1, 0xb3, 0x1d, 0x9c, 0x23, 0x25,
  12857. 0x98, 0x24, 0xd9, 0x67, 0xc9, 0x88, 0x22, 0x09, 0x83, 0xa9, 0x3f, 0x24, 0x60, 0xf1, 0x41, 0xb7,
  12858. 0x59, 0xb7, 0xf1, 0xa8, 0x0c, 0x45, 0xef, 0xc0, 0x2c, 0x05, 0x1d, 0x62, 0xd3, 0xd2, 0x8d, 0x0e,
  12859. 0x0d, 0x30, 0x53, 0x3e, 0x2f, 0xf3, 0xf8, 0x31, 0x83, 0x68, 0x19, 0x62, 0xc0, 0x1f, 0xd0, 0xab,
  12860. 0x30, 0x41, 0x8e, 0x5b, 0x3e, 0x45, 0xed, 0x2e, 0x44, 0xe5, 0x45, 0xa3, 0x48, 0xb5, 0x02, 0xc8,
  12861. 0x1b, 0xeb, 0xb1, 0x8e, 0xc5, 0x16, 0x2c, 0x6a, 0x78, 0xdf, 0x38, 0x1c, 0x7d, 0xbd, 0x39, 0x98,
  12862. 0x7c, 0x68, 0x98, 0x0d, 0x96, 0x89, 0x69, 0x8d, 0x3d, 0xa8, 0x39, 0x40, 0xde, 0xf9, 0x58, 0x4c,
  12863. 0xfc, 0xd0, 0xdf, 0xaf, 0x5b, 0x2d, 0x8f, 0x0b, 0xbb, 0x6e, 0xb5, 0x02, 0x2e, 0x08, 0x82, 0xb8,
  12864. 0x20, 0xaf, 0x9c, 0x43, 0xcf, 0xcc, 0xdc, 0xd5, 0x91, 0x97, 0x51, 0xab, 0xa3, 0x78, 0x8a, 0x52,
  12865. 0xaf, 0x8b, 0xd5, 0x8d, 0xec, 0xda, 0x59, 0x87, 0xd7, 0xbb, 0xfa, 0x2f, 0x17, 0x11, 0x32, 0x78,
  12866. 0x0c, 0x11, 0xf1, 0x9a, 0x0d, 0x8a, 0xc8, 0xf7, 0xa7, 0x28, 0x22, 0xb2, 0xc8, 0xa4, 0x22, 0xb2,
  12867. 0x0e, 0x19, 0x0b, 0x9b, 0x87, 0x7a, 0x83, 0xb0, 0x83, 0x89, 0x08, 0x0f, 0x61, 0x9b, 0x0d, 0xd7,
  12868. 0xaa, 0x96, 0x06, 0x1c, 0x52, 0x6b, 0x5a, 0x68, 0x05, 0xa6, 0x39, 0x97, 0x98, 0x5a, 0xcc, 0x54,
  12869. 0x32, 0xfd, 0xde, 0x72, 0x9a, 0x91, 0xc9, 0xd2, 0xd2, 0x8c, 0x4d, 0x16, 0xaa, 0xc2, 0x5c, 0x13,
  12870. 0x5b, 0xba, 0x89, 0x9b, 0x3b, 0x96, 0x5d, 0xb7, 0xb9, 0x3e, 0xcc, 0x95, 0x5f, 0x0c, 0x4b, 0xf1,
  12871. 0x36, 0x41, 0x69, 0x59, 0x6e, 0x44, 0x9f, 0x24, 0x22, 0x93, 0xfe, 0x5f, 0x44, 0x86, 0x6f, 0x97,
  12872. 0x2b, 0x32, 0x84, 0x35, 0x91, 0x22, 0x43, 0x69, 0xc4, 0x60, 0xea, 0x26, 0xe4, 0x36, 0x4c, 0x5c,
  12873. 0xb7, 0x31, 0xdf, 0x32, 0x41, 0xa4, 0xab, 0x5c, 0x01, 0x18, 0x8b, 0x96, 0x65, 0xd3, 0x70, 0x0b,
  12874. 0x8f, 0x08, 0x6c, 0xc1, 0xd9, 0xc0, 0x64, 0x3c, 0xaa, 0x6b, 0x90, 0xe6, 0x69, 0xe0, 0x13, 0x9e,
  12875. 0x8f, 0x98, 0x50, 0x13, 0x58, 0xf5, 0x26, 0x2c, 0xde, 0xc6, 0x76, 0x20, 0xb2, 0x35, 0x00, 0x37,
  12876. 0xeb, 0xfc, 0xd4, 0x64, 0xfb, 0xbd, 0xe5, 0x19, 0x27, 0xe9, 0xda, 0x8c, 0x93, 0x73, 0x75, 0x13,
  12877. 0x90, 0x77, 0x8a, 0xf1, 0xe2, 0xf9, 0x25, 0x01, 0x39, 0xa6, 0x72, 0xe3, 0xc4, 0x84, 0xaa, 0x30,
  12878. 0x2f, 0xd0, 0x23, 0x08, 0xf4, 0x1c, 0xb7, 0x11, 0x1a, 0x7d, 0xd5, 0xa7, 0xd1, 0xc3, 0x67, 0x28,
  12879. 0xb0, 0x80, 0xf1, 0x76, 0xa4, 0x0a, 0x39, 0x26, 0x4d, 0x63, 0x25, 0xe9, 0x05, 0x38, 0x1b, 0x98,
  12880. 0x85, 0x6b, 0xdc, 0x5f, 0x49, 0x58, 0x22, 0x1c, 0xe7, 0xe3, 0x8e, 0xcc, 0xd5, 0x82, 0x32, 0xb7,
  12881. 0x1e, 0x26, 0x26, 0x01, 0xcb, 0x41, 0xa5, 0xfb, 0x26, 0x79, 0xe2, 0x4a, 0xb7, 0x1d, 0x50, 0xba,
  12882. 0xb7, 0x46, 0x0c, 0x4e, 0x2a, 0x76, 0x03, 0x6a, 0x32, 0x71, 0xb2, 0x6a, 0xf2, 0x11, 0xe4, 0xfc,
  12883. 0x21, 0x71, 0x62, 0xbc, 0x01, 0xd3, 0x3c, 0x51, 0x42, 0x53, 0x22, 0x99, 0xe1, 0x80, 0x5d, 0x65,
  12884. 0xd9, 0xc2, 0xf6, 0x63, 0xc3, 0x6c, 0x8d, 0xa0, 0x2c, 0xdc, 0x42, 0xa6, 0x2c, 0xce, 0x64, 0x2e,
  12885. 0x6f, 0x3b, 0x6c, 0x28, 0x8a, 0xb7, 0xc2, 0x4a, 0x60, 0xd5, 0x07, 0x54, 0x59, 0x02, 0x91, 0x21,
  12886. 0x98, 0x20, 0xbb, 0xc9, 0xf7, 0x8b, 0xfe, 0x26, 0x44, 0xe6, 0x36, 0x84, 0xc8, 0x49, 0x97, 0xc8,
  12887. 0xdc, 0x96, 0x10, 0x99, 0x03, 0x1c, 0xb5, 0x39, 0xa1, 0x18, 0x3f, 0x11, 0x67, 0xeb, 0xc4, 0xc3,
  12888. 0x74, 0xce, 0x5b, 0x20, 0x52, 0xe7, 0xbc, 0xf1, 0xf1, 0x63, 0x9c, 0xb7, 0x80, 0xe5, 0xf3, 0x75,
  12889. 0xde, 0x42, 0x82, 0x3b, 0xcd, 0xf3, 0xe6, 0x86, 0xe4, 0x9e, 0x37, 0x9e, 0xa8, 0xc8, 0xf3, 0x26,
  12890. 0x32, 0xe7, 0x80, 0xf9, 0xc7, 0x72, 0xa3, 0x7d, 0x60, 0xd9, 0xd8, 0xf4, 0xe8, 0x70, 0x83, 0x8d,
  12891. 0x04, 0x74, 0x98, 0xe3, 0x08, 0x2f, 0x38, 0xc0, 0xa1, 0xaf, 0x33, 0x85, 0x4b, 0x5f, 0x0e, 0x89,
  12892. 0xa2, 0xaf, 0xb0, 0x12, 0x58, 0x87, 0x4b, 0xfc, 0xc5, 0x31, 0xb8, 0x14, 0xb0, 0x7c, 0xbe, 0xb8,
  12893. 0x14, 0x12, 0xdc, 0x69, 0x72, 0xc9, 0x0d, 0xc9, 0xe5, 0x12, 0xcf, 0x46, 0x24, 0x97, 0x44, 0xea,
  12894. 0x1c, 0xb0, 0xfa, 0x6d, 0x02, 0x32, 0x9b, 0xf8, 0x48, 0x33, 0xec, 0xba, 0x4d, 0x6a, 0x8d, 0x97,
  12895. 0x61, 0x91, 0x90, 0x0c, 0x9b, 0x3b, 0x8f, 0x0c, 0xbd, 0xb3, 0x63, 0x1b, 0x2d, 0xdc, 0xa1, 0xa1,
  12896. 0x4d, 0x6b, 0xf3, 0xec, 0xc5, 0x1d, 0x43, 0xef, 0xdc, 0x27, 0xc3, 0x68, 0x0d, 0xd0, 0x7e, 0xbd,
  12897. 0x53, 0xdf, 0xf3, 0x83, 0xd9, 0xc5, 0x6c, 0x81, 0xbf, 0x91, 0xa2, 0x0f, 0x3a, 0x6d, 0xa3, 0xd1,
  12898. 0xda, 0x21, 0xab, 0x4e, 0xf9, 0xd0, 0x0f, 0xe8, 0x8b, 0x4d, 0x7c, 0xa4, 0x7e, 0x95, 0x14, 0x05,
  12899. 0xd8, 0x38, 0x3c, 0x27, 0x05, 0x98, 0x40, 0x8f, 0x52, 0x80, 0x71, 0x9b, 0x11, 0x0a, 0x30, 0xee,
  12900. 0xdd, 0xfd, 0x90, 0xa1, 0x9b, 0x30, 0x6d, 0xf2, 0x5d, 0xcd, 0x4f, 0x84, 0x1b, 0x7a, 0x36, 0xbf,
  12901. 0x32, 0xf1, 0xb4, 0xb7, 0x7c, 0x46, 0x73, 0xcc, 0xdc, 0x1a, 0xee, 0x84, 0x0e, 0xea, 0xdb, 0xb0,
  12902. 0x40, 0x4b, 0xe4, 0x86, 0x89, 0x6d, 0xb1, 0x9f, 0xab, 0x30, 0x63, 0xd1, 0x01, 0x77, 0x3b, 0x67,
  12903. 0xfb, 0xbd, 0xe5, 0x69, 0x86, 0xaa, 0x55, 0xc9, 0x77, 0x9e, 0xfe, 0x6a, 0xaa, 0xb7, 0x79, 0x91,
  12904. 0xce, 0xcc, 0x79, 0x28, 0x65, 0x98, 0x62, 0x00, 0x1e, 0x89, 0x22, 0xaf, 0x19, 0xa8, 0x0d, 0x47,
  12905. 0xaa, 0x3f, 0x27, 0x60, 0x49, 0x14, 0xa7, 0xc7, 0x8b, 0x05, 0x55, 0x60, 0x8e, 0x43, 0x47, 0xc8,
  12906. 0x6b, 0x96, 0x99, 0x88, 0xb4, 0x96, 0x7d, 0x69, 0x2d, 0x84, 0x07, 0xee, 0x29, 0x4f, 0xee, 0xb8,
  12907. 0xf7, 0x82, 0xb1, 0xb7, 0xe1, 0xcf, 0x24, 0x20, 0x56, 0x89, 0x91, 0x47, 0x47, 0x36, 0x3f, 0x08,
  12908. 0xca, 0x66, 0x29, 0xbc, 0xaa, 0xf4, 0x1a, 0x0e, 0xaa, 0xe6, 0xd7, 0x27, 0xaf, 0x9a, 0x5a, 0x40,
  12909. 0x35, 0x6f, 0x8c, 0x16, 0xdb, 0xa9, 0x88, 0xe6, 0xa6, 0xb8, 0x5a, 0xf0, 0x88, 0x78, 0xca, 0x5e,
  12910. 0x27, 0x17, 0x21, 0x3a, 0xc4, 0x25, 0x33, 0x2a, 0x67, 0x02, 0xaa, 0xd6, 0x60, 0x49, 0xdc, 0x7c,
  12911. 0xbd, 0xd4, 0x2d, 0xfb, 0x6a, 0xdd, 0xa1, 0xb9, 0xe4, 0x9f, 0x6a, 0x0c, 0x2e, 0xbd, 0x07, 0x4b,
  12912. 0xe2, 0x62, 0x75, 0xcc, 0xd3, 0x7d, 0xce, 0xbd, 0xe0, 0x79, 0xa3, 0x29, 0xff, 0x78, 0x0e, 0xd2,
  12913. 0x1b, 0xac, 0x69, 0x8f, 0x74, 0x48, 0xf3, 0x7e, 0x38, 0x52, 0x65, 0x41, 0xf9, 0x7b, 0xec, 0xca,
  12914. 0xa5, 0x48, 0x0c, 0xaf, 0x44, 0xcf, 0xfe, 0xfa, 0xd3, 0xdf, 0xdf, 0x25, 0xe7, 0x21, 0x4b, 0x41,
  12915. 0xaf, 0xf0, 0x2f, 0x01, 0x32, 0x60, 0xc6, 0x69, 0xac, 0xa2, 0x97, 0x86, 0x69, 0x43, 0x2b, 0x97,
  12916. 0x63, 0x50, 0xd1, 0x0e, 0x4d, 0x00, 0xb7, 0xaf, 0x89, 0xa4, 0x73, 0x0d, 0xf4, 0x68, 0x95, 0x95,
  12917. 0x38, 0x58, 0xac, 0x4f, 0xb7, 0x6f, 0x29, 0xf7, 0x39, 0xd0, 0x27, 0x95, 0xfb, 0x94, 0xb4, 0x3f,
  12918. 0x43, 0x7c, 0xb2, 0x1c, 0xde, 0xaf, 0x5b, 0xad, 0xd0, 0x1c, 0x7a, 0xfa, 0x96, 0xa1, 0x39, 0xf4,
  12919. 0x75, 0x28, 0xa3, 0x73, 0x48, 0xfb, 0x56, 0xe1, 0x39, 0xf4, 0x76, 0x01, 0xc3, 0x73, 0xe8, 0x6b,
  12920. 0x7e, 0xc5, 0xee, 0x27, 0x5d, 0x5e, 0xc4, 0x7e, 0x7a, 0x57, 0xb8, 0x12, 0x07, 0x8b, 0xf5, 0xe9,
  12921. 0xf6, 0x9d, 0xe4, 0x3e, 0x07, 0x5a, 0x5b, 0x72, 0x9f, 0x83, 0xed, 0xab, 0x30, 0x9f, 0x4f, 0x60,
  12922. 0xd6, 0x7b, 0x85, 0x47, 0x57, 0x86, 0xec, 0x3b, 0x28, 0xc5, 0x78, 0x60, 0xb4, 0xe7, 0xcf, 0x21,
  12923. 0xeb, 0x6b, 0xfc, 0x21, 0xe9, 0x8c, 0xb2, 0x46, 0xa3, 0xb2, 0x3a, 0x04, 0x32, 0xd6, 0xb9, 0xaf,
  12924. 0xa7, 0x25, 0x77, 0x2e, 0xeb, 0xdb, 0xc9, 0x9d, 0x4b, 0x1b, 0x64, 0x11, 0xce, 0x7d, 0xad, 0x2b,
  12925. 0xb9, 0x73, 0x59, 0x8f, 0x4c, 0xee, 0x5c, 0xde, 0x07, 0x8b, 0x24, 0x19, 0xbf, 0x0a, 0x86, 0x92,
  12926. 0xcc, 0xdf, 0x3e, 0x08, 0x25, 0x59, 0xb0, 0x17, 0x10, 0x4d, 0x32, 0x71, 0x6f, 0x0d, 0x27, 0x59,
  12927. 0xe0, 0xb2, 0x1d, 0x4e, 0xb2, 0xe0, 0x15, 0x38, 0x96, 0x64, 0x62, 0xc1, 0x11, 0x24, 0x0b, 0xac,
  12928. 0x79, 0x75, 0x08, 0xe4, 0x90, 0x79, 0x8e, 0x74, 0x2e, 0xeb, 0xd7, 0x44, 0xe5, 0x79, 0x48, 0xe7,
  12929. 0x2c, 0xcf, 0xbc, 0x70, 0x0f, 0xcd, 0xb3, 0xff, 0x4a, 0x14, 0x9a, 0xe7, 0xc0, 0xad, 0x21, 0x26,
  12930. 0xcf, 0xe2, 0x4e, 0x19, 0x9e, 0xe7, 0xc0, 0x45, 0x38, 0x3c, 0xcf, 0xc1, 0xeb, 0x69, 0xec, 0x79,
  12931. 0x16, 0x0b, 0x8e, 0x38, 0xcf, 0x81, 0x35, 0xaf, 0x0e, 0x81, 0x8c, 0xfd, 0x38, 0x39, 0xb7, 0x19,
  12932. 0xf9, 0xc7, 0x29, 0x78, 0x57, 0x52, 0x2e, 0xc7, 0xa0, 0x62, 0xf7, 0xd9, 0x7b, 0x75, 0x90, 0xef,
  12933. 0xb3, 0xe4, 0x5a, 0xa4, 0x14, 0xe3, 0x81, 0xd1, 0x9e, 0x0f, 0x20, 0xe3, 0x29, 0x80, 0xd1, 0xca,
  12934. 0x70, 0x35, 0xbb, 0x72, 0x25, 0x16, 0x17, 0xbb, 0x60, 0x6f, 0x7d, 0x2b, 0x5f, 0xb0, 0xa4, 0x98,
  12935. 0x56, 0x8a, 0xf1, 0xc0, 0x58, 0xcf, 0xde, 0x5a, 0x56, 0xee, 0x59, 0x52, 0x2f, 0x2b, 0xc5, 0x78,
  12936. 0x60, 0xa4, 0xe7, 0xca, 0x85, 0xa7, 0xcf, 0x0a, 0x67, 0x7e, 0x7f, 0x56, 0x38, 0xf3, 0xcf, 0xb3,
  12937. 0x42, 0xe2, 0x8b, 0x7e, 0x21, 0xf1, 0xb4, 0x5f, 0x48, 0xfc, 0xd6, 0x2f, 0x24, 0xfe, 0xe8, 0x17,
  12938. 0x12, 0xbb, 0x53, 0xf4, 0xbf, 0x51, 0xae, 0xfe, 0x17, 0x00, 0x00, 0xff, 0xff, 0x0c, 0xe8, 0xa4,
  12939. 0xf9, 0x06, 0x23, 0x00, 0x00,
  12940. }