Hey Tolga,

At this point, trying to change from backends to module would be more 1-1 
help request than something suited for the google groups. I would suggest 
you go and ask this on Stack Overflow. Do note that we have some members of 
the support team on Stack Overflow answering questions, so you might end up 
getting help from the same people as you would get here (plus the added 
benefit of a bigger community of OTHER users to answer). Do take a second 
to read Stack's "how to ask <http://stackoverflow.com/help/how-to-ask>" 
article and make sure you abide by this.

Now, for the backends not starting when you want them to, I'm actually not 
sure you should be using the /_ah/start to send to your backend, but you 
should make the call yourself. The call to /_ah/starts is what tells your 
instance to start. In your instance itself, you should send a request to 
something else, that should be handled by your backend. This also could be 
an interesting question for Stack Overflow, but as backends are getting 
deprecated, chances are you'll get a similar answer to mine (ie: "why not 
change to modules?").

Cheers

On Tuesday, September 1, 2015 at 12:27:36 PM UTC-4, Tolga Tanrıverdi wrote:
>
> Hi Patrice
>
> Thanks for the reply.
> I've tried to specify my backend as dynamic and also resident. In both 
> case the situation didn't change somehow app engine decide by itself for 
> when to start my backends.
>
> I'm starting my backends with connecting my backend servlet to  /_ah/start 
> web service as much as I read from documentation it says /_ah/start starts 
> when the instance is started.
> And my backend servlet code is google's standard push notification code 
> which you may find it in here:
>
>
> https://github.com/GoogleCloudPlatform/solutions-ios-push-notification-sample-backend-java/blob/master/src/com/google/cloud/solutions/mobilepushnotification/PushNotificationWorkerServlet.java
>
> Anyway I may change my backends to module but I don't know how. I'm using 
> google eclipse plugin and I've created my project as google-> java web 
> application
> And as much as I can see java web application doesn't have support for 
> ear(enterprise application) so is there any documentation to how to convert 
> my java web application to enterprise application? And is it going to solve 
> my problem ?
>
> All I can see was the below documentation and it doesn't give the 
> information that I need:
> https://cloud.google.com/appengine/docs/java/modules/converting
>
> Thanks
> Tolga
>
> 1 Eylül 2015 Salı 19:16:57 UTC+3 tarihinde Patrice (Cloud Platform 
> Support) yazdı:
>>
>> Hi,
>>
>> Looking into the java Backend documentation 
>> <https://cloud.google.com/appengine/docs/java/config/backends#About_backends>,
>>  
>> this seems to be expected. If you don't specify your instance to be 
>> dynamic, it is "resident", which means it needs to be manually started.
>>
>> You should not use backends anymore, but modules. I would suggest using a 
>> Manually scaled module. 
>>
>> In any case, in your specific case, what is getting called to start your 
>> worker? Do you do the call yourself, is it part of your application?
>>
>> Cheers
>>
>>
>>
>> On Monday, August 31, 2015 at 7:06:57 PM UTC-4, Tolga Tanrıverdi wrote:
>>>
>>> I'm using google app engine for my IOS and Android application's server 
>>> needs(Storing contents and datas for my applications) And I'm also using 
>>> app engine to send push notifications to mobile clients. I'm using the 
>>> below library to send push notifications:
>>> https://github.com/GoogleCloudPlatform/solutions-ios-push-notification-sample-backend-java
>>>
>>> But when I integrate the above library to my code and deploy it to my 
>>> google app engine account.GAE shows that there are backends in the code but 
>>> it doesn't deploy it to any instances. [image: GAE Frontend & Backend 
>>> Instance Deployments] <http://i.stack.imgur.com/CAcdo.png>
>>>
>>> But after sometimes (after 2-3 hours) it automatically deploys the 
>>> worker backend to 1 instance and then it starts to work and deliver 
>>> notifications.But this is unaccaptable for me
>>>
>>> So what I want is,my worker backend to start working immediately with 
>>> the frontend instance and shutdown immediately with the frontend.(So it 
>>> shouldn't work 7/24 ) Do you know why it may happen? Am I missing something.
>>>
>>> You can find my app engine xml files below: *AppEngine-Web XML:*
>>>
>>> <?xml version="1.0" encoding="utf-8"?>
>>> <appengine-web-app xmlns="http://appengine.google.com/ns/1.0";>
>>> <application>tokyo-analyst-845</application>
>>> <version>1</version>
>>>
>>> <threadsafe>true</threadsafe>
>>>
>>> <sessions-enabled>true</sessions-enabled>
>>>
>>> <system-properties>
>>> <property name="java.util.logging.config.file" 
>>> value="WEB-INF/logging.properties"/>
>>> </system-properties>
>>>
>>> <use-google-connector-j>true</use-google-connector-j>
>>>
>>> </appengine-web-app>
>>>
>>> *Backends.XML:*
>>>
>>> <backends>
>>>   <backend name="worker">
>>>   </backend>
>>>
>>> *Queue.XML:*
>>>
>>> <queue-entries>
>>>   <queue>
>>>     <name>notification-preprocessing</name>
>>>     <rate>200/s</rate>
>>>     <bucket-size>100</bucket-size>
>>>   </queue>
>>>   <queue>
>>>     <name>notification-delivery</name>
>>>     <mode>pull</mode>
>>>   </queue>
>>>   <queue>
>>>     <name>notification-device-token-cleanup</name>
>>>     <rate>10/s</rate>
>>>     <bucket-size>20</bucket-size>
>>>     <target>default</target>
>>>   </queue>
>>> </queue-entries>
>>>
>>> *Web.XML:*
>>>
>>>   <servlet-mapping>
>>>      <servlet-name>spring</servlet-name>
>>>      <url-pattern>/</url-pattern>
>>>   </servlet-mapping>
>>>   <context-param>
>>>      <param-name>contextConfigLocation</param-name>
>>>      <param-value>
>>>         /WEB-INF/spring-servlet.xml
>>>      </param-value>
>>>   </context-param>
>>>   <listener>
>>>      <listener-class>
>>>         org.springframework.web.context.ContextLoaderListener
>>>      </listener-class>
>>>   </listener>
>>> <servlet>
>>>   <servlet-name>PushNotificationWorkerServlet</servlet-name>
>>>   
>>> <servlet-class>com.finarapp.pn.controller.PushNotificationWorkerServlet</servlet-class>
>>> </servlet>
>>> <servlet-mapping>
>>>   <servlet-name>PushNotificationWorkerServlet</servlet-name>
>>>   <url-pattern>/_ah/start</url-pattern>
>>> </servlet-mapping>
>>>
>>> <servlet>
>>>   <servlet-name>PushPreProcessingServlet</servlet-name>
>>>   
>>> <servlet-class>com.finarapp.pn.controller.PushPreProcessingServlet</servlet-class>
>>> </servlet>
>>> <servlet-mapping>
>>>   <servlet-name>PushPreProcessingServlet</servlet-name>
>>>   <url-pattern>/admin/push/preprocessing</url-pattern>
>>> </servlet-mapping>
>>>
>>> Thanks
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/ebd5bfe2-c572-4e68-8fd7-383b62a78124%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to