Well , I have seen an issue sometimes where the service is not available anymore in the gateway check issue label "Failing Service" on this mailing list : 

basically i get this exception below but if i change the version number it works fine . 

The other use-case , is where i backup my database and load it again , how do i publish everything again ? 





 io.apiman.gateway.engine.beans.exceptions.InvalidServiceException: Service not found.
	at io.apiman.gateway.engine.impl.ServiceRequestExecutorImpl$3.handle(ServiceRequestExecutorImpl.java:261)
	at io.apiman.gateway.engine.impl.ServiceRequestExecutorImpl$3.handle(ServiceRequestExecutorImpl.java:255)
	at io.apiman.gateway.engine.impl.SecureRegistryWrapper$1.handle(SecureRegistryWrapper.java:107)
	at io.apiman.gateway.engine.impl.SecureRegistryWrapper$1.handle(SecureRegistryWrapper.java:97)
	at io.apiman.gateway.engine.es.ESRegistry$10.completed(ESRegistry.java:415)
	at io.apiman.gateway.engine.es.ESRegistry$10.completed(ESRegistry.java:407)
	at io.searchbox.client.http.JestHttpClient$DefaultCallback.completed(JestHttpClient.java:195)
	at io.searchbox.client.http.JestHttpClient$DefaultCallback.completed(JestHttpClient.java:178)
	at org.apache.http.concurrent.BasicFuture.completed(BasicFuture.java:119)
	at org.apache.http.impl.nio.client.DefaultClientExchangeHandlerImpl.responseCompleted(DefaultClientExchangeHandlerImpl.java:177)
	at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.processResponse(HttpAsyncRequestExecutor.java:412)
	at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.inputReady(HttpAsyncRequestExecutor.java:305)
	at org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(DefaultNHttpClientConnection.java:267)
	at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:81)
	at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:39)
	at org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(AbstractIODispatch.java:116)
	at org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:164)
	at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:339)
	at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:317)
	at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:278)
	at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:106)
	at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:590)
	at java.lang.Thread.run(Thread.java:745)


On Wed, Sep 16, 2015 at 2:53 PM, Eric Wittmann <eric.wittmann@redhat.com> wrote:
Hi Fadi.

You are right - the API Gateway stores its configuration in elasticsearch (by default).  This is a persistent data store, so barring some sort of catastrophic crash resulting in data loss in the Gateway, you shouldn't need to force a resync between the API Manager and the API Gateway.

Perhaps I have misunderstood your question. :)

-Eric


On 9/16/2015 2:10 PM, Fadi Abdin wrote:
Hi Eric,

I have been following your documentation for production setup
http://www.apiman.io/latest/production-guide.html# ..
and it worked successfully. i want to clarify something.

Now i have API Manager data stored in the apiman database , which is
great , i can copy it and all that .. but from how i see , when you
publish an api , it will be published to the gateway and the gateway
stores the data in elastic search !! ? I might be missing something.

How do i force a refresh from the apiman to gateway ? or do i need to
clear elastic search data !

Sorry if i completely missunderstand something.

Thanks,
Fadi