Stai visualizzando la documentazione di Apigee e Apigee hybrid.
Visualizza la documentazione di
Apigee Edge.
InvalidTimeout
Messaggio di errore
Il deployment del proxy API tramite l'API o l'interfaccia utente di Apigee non va a buon fine con questo messaggio di errore:
Error Saving Revision revision_number CacheLookupTimeoutInSeconds value value should be greater than zero.
Esempio di messaggio di errore
Error Saving Revision 2
CacheLookupTimeoutInSeconds -1 value should be greater than zero.
Screenshot di errore di esempio

Causa
Se l'elemento <CacheLookupTimeoutInSeconds> di un criterio LookupCache è impostato su un numero negativo, il deployment del proxy API non va a buon fine.
Ad esempio, se l'elemento <CacheLookupTimeoutInSeconds> è -1, il deployment del proxy API non va a buon fine.
Diagnosi
Identifica il valore non valido specificato per l'elemento
<CacheLookupTimeoutInSeconds>nel parametro LookupCache. Puoi trovare queste informazioni nel messaggio di errore. Ad esempio, nel seguente errore, il valore non valido utilizzato per l'elemento<CacheLookupTimeoutInSeconds>è-1:CacheLookupTimeoutInSeconds -1 value should be greater than zero.Esamina tutti i criteri LookupCache nel proxy API specifico in cui si è verificato l'errore. Potrebbero essere presenti uno o più criteri LookupCache in cui è specificato l'elemento
<CacheLookupTimeoutInSeconds>. Identifica la policy LookUpCache in cui è specificato il valore non valido (identificato nel passaggio 1 sopra) per l'elemento<CacheLookupTimeoutInSeconds>.Ad esempio, la seguente configurazione del criterio specifica il valore
<CacheLookupTimeoutInSeconds>di-1, che corrisponde al messaggio di errore:<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <LookupCache async="false" continueOnError="false" enabled="true" name="LookupCache-Token"> <DisplayName>LookupCache-Token</DisplayName> <Properties/> <CacheKey> <Prefix/> <KeyFragment ref="request.queryparam.client_id"/> </CacheKey> <CacheLookupTimeoutInSeconds>-1</CacheLookupTimeoutInSeconds> <Scope>Exclusive</Scope> <ExpirySettings> <TimeoutInSec>3600</TimeoutInSec> </ExpirySettings> <AssignTo>usertoken</AssignTo> </LookupCache>Se
<CacheLookupTimeoutInSeconds>è specificato come numero intero negativo, è la causa dell'errore.
Risoluzione
Assicurati che il valore dell'elemento <CacheLookupTimeoutInSeconds> del criterio LookupCache sia sempre specificato come numero intero non negativo.
Per correggere la norma LookupCache di esempio mostrata sopra, puoi modificare l'elemento <CacheLookupTimeoutInSeconds> in 30.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<LookupCache async="false" continueOnError="false" enabled="true" name="LookupCache-Token">
<DisplayName>LookupCache-Token</DisplayName>
<Properties/>
<CacheKey>
<Prefix/>
<KeyFragment ref="request.queryparam.client_id"/>
</CacheKey>
<CacheResource>tokencache</CacheResource>
<CacheLookupTimeoutInSeconds>30</CacheLookupTimeoutInSeconds>
<Scope>Exclusive</Scope>
<ExpirySettings>
<TimeoutInSec>3600</TimeoutInSec>
</ExpirySettings>
<AssignTo>usertoken</AssignTo>
</LookupCache>
InvalidCacheResourceReference
Messaggio di errore
Il deployment del proxy API tramite l'API o l'interfaccia utente di Apigee non va a buon fine con questo messaggio di errore:
Error Deploying Revision revision_number to environment Invalid cache resource reference [cache_resource] in Step definition [populate_cache_policy_name]. Context Revision:[revision_number];APIProxy:ResponseCache;Organization:[organization];Environment:[environment]
Esempio di messaggio di errore
Error Deploying Revision 2 to test
Invalid cache resource reference tokencache in Step definition LookupCache-Token. Context Revision:2;APIProxy:TestCache;Organization:kkalckstein-eval;Environment:test
Screenshot di errore di esempio

Causa
Questo errore si verifica se all'elemento <CacheResource> è associato un nome che non esiste nell'ambiente in cui viene eseguito il deployment del proxy API.
Diagnosi
Identifica la cache non valida utilizzata nell'elemento
<CacheResource>del criterio LookupCache e l'ambiente in cui si è verificato l'errore. Puoi trovare entrambi questi elementi nel messaggio di errore. Ad esempio, nell'errore seguente, il nome della cache non valida ètokencachee il nome dell'ambiente ètest.Invalid cache resource reference tokencache in Step definition LookupCache-Token. Context Revision:2;APIProxy:TestCache;Organization:kkalckstein-eval;Environment:testEsamina tutti i criteri LookupCache nel proxy API specifico in cui si è verificato l'errore. Identifica la norma LookupCache specifica in cui la cache non valida (identificata nel passaggio 1) è specificata nell'elemento
<CacheResource>.Ad esempio, il seguente criterio specifica il valore di
<CacheResource>cometokencache, che corrisponde al messaggio di errore:<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <LookupCache async="false" continueOnError="false" enabled="true" name="LookupCache-Token"> <DisplayName>LookupCache-Token</DisplayName> <Properties/> <CacheKey> <Prefix/> <KeyFragment ref="request.queryparam.client_id"/> </CacheKey> <CacheResource>tokencache</CacheResource> <CacheLookupTimeoutInSeconds/> <Scope>Exclusive</Scope> <ExpirySettings> <TimeoutInSec>3600</TimeoutInSec> </ExpirySettings> <AssignTo>usertoken</AssignTo> </LookupCache>Verifica se la cache (determinata nel passaggio 1) è stata definita nell'ambiente specifico (identificato nel passaggio 1).
Nell'interfaccia utente di Apigee, vai ad AMMINISTRAZIONE > Ambiente > test e controlla se la cache esiste nella scheda Cache di Configurazione ambiente. Se la cache non esiste, è la causa dell'errore.
Ad esempio, nello screenshot di seguito noterai che la cache denominata
tokencachenon esiste.
Poiché la cache denominata
tokencachenon è definita nell'ambientetest, viene visualizzato l'errore:Invalid cache resource reference tokencache in Step definition LookupCache-Token. Context Revision:2;APIProxy:TestCache;Organization:kkalckstein-eval;Environment:test
Risoluzione
Assicurati che il nome della cache specificato nell'elemento <CacheResource> sia stato creato nell'ambiente in cui vuoi eseguire il deployment del proxy API.
CacheNotFound
Messaggio di errore
Il deployment del proxy API tramite l'API o l'interfaccia utente di Apigee genera un messaggio di errore come questo e lo stato di deployment del proxy API è contrassegnato come parziale:
Error: Cache : cache_resource, not found in organization : organization__environment.
Esempio di messaggio di errore
Error Cache : configCache, not found in organization : kkalckstein-eval__test
Causa
Questo errore si verifica se la cache specifica indicata nel messaggio di errore non è stata creata in un componente di processore di messaggi specifico.
Risoluzione
Contatta l'assistenza Apigee per ricevere aiuto.