Hello Prachi You cannot use Threads in GAE. Here is a list of things you cannot do in GAE<http://code.google.com/appengine/docs/java/runtime.html#The_Sandbox> :
If you want to do something asynchronously, look into TaskQueues. Thanks, Shilendra On Mon, Dec 17, 2012 at 11:36 PM, Prachi Deodhar <[email protected]>wrote: > I am new to Google App Engine. I am trying to call Amazon's CloudWatch > service using its Java SDKs. I am planning to run this App in Google App > Engine. However at the time of instantiating my AmazonCloudWatchClient in > my code I get the following exception. > > access denied (java.lang.RuntimePermission modifyThreadGroup) > Caused by: > java.security.AccessControlException: access denied > (java.lang.RuntimePermission modifyThreadGroup) > at > java.security.AccessControlContext.checkPermission(AccessControlContext.java:374) > at > java.security.AccessController.checkPermission(AccessController.java:549) > at java.lang.SecurityManager.checkPermission(SecurityManager.java:532) > at > com.google.appengine.tools.development.DevAppServerFactory$CustomSecurityManager.checkPermission(DevAppServerFactory.java:289) > at > com.google.appengine.tools.development.DevAppServerFactory$CustomSecurityManager.checkAccess(DevAppServerFactory.java:314) > at java.lang.ThreadGroup.checkAccess(ThreadGroup.java:299) > at java.lang.Thread.init(Thread.java:336) > at java.lang.Thread.<init>(Thread.java:472) > at > com.amazonaws.http.IdleConnectionReaper.<init>(IdleConnectionReaper.java:56) > at > com.amazonaws.http.IdleConnectionReaper.registerConnectionManager(IdleConnectionReaper.java:62) > at > com.amazonaws.http.ConnectionManagerFactory.createThreadSafeClientConnManager(ConnectionManagerFactory.java:30) > at > com.amazonaws.http.HttpClientFactory.createHttpClient(HttpClientFactory.java:88) > at com.amazonaws.http.AmazonHttpClient.<init>(AmazonHttpClient.java:111) > at > com.amazonaws.AmazonWebServiceClient.<init>(AmazonWebServiceClient.java:60) > at > com.amazonaws.services.cloudwatch.AmazonCloudWatchClient.<init>(AmazonCloudWatchClient.java:165) > at > com.amazonaws.services.cloudwatch.AmazonCloudWatchClient.<init>(AmazonCloudWatchClient.java:146) > at > com.ea.tnt.cloudbilling.BillingDataRetriever.retrieveData(BillingDataRetriever.java:77) > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/google-appengine/-/1qCMdjlMYxMJ. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
