You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Google App engine Image transforming Issue from local tomcat server #702
I am trying to transform images using BlobstoreServiceFactory.
The code is running perfectly on Google cloud app engine. But when I am running the code from local tomcat sever it's throwing the below.
I have set the service account json file in system environment variable. I can read the bucket content from eclipse but while transforming getting the below exception. Please help..
com.google.apphosting.api.ApiProxy$CallNotFoundException: Can't make API call blobstore.CreateEncodedGoogleStorageKey in a thread that is neither the original request thread nor a thread created by ThreadManager.
These apis are meant to be called from App Engine or from the development environment. For Image transformation on your own Tomcat server, you might wish to use a java image transform library.
Reacted by JAVA/J2EE Application Architect and Alex
Thanks lesv.. but before that I have to get the image from cloud bucket and for that I am using this method which is not giving the actual image.
public static List<StorageObject> listBucket(String bucketName) throws IOException, GeneralSecurityException {
Storage client = StorageFactory.getService();
System.out.print(bucketName);
Storage.Objects.List listRequest = client.objects().list(bucketName);
System.out.print("******* " + listRequest+ "**********");
List<StorageObject> results = new ArrayList<StorageObject>();
Objects objects;
// Iterate through each page of results, and add them to our results
// list.
do {
objects = listRequest.execute();
// Add the items in this page of results to the list we'll return.
results.addAll(objects.getItems());
// Get the next page, in the next iteration of this loop.
listRequest.setPageToken(objects.getNextPageToken());
} while (null != objects.getNextPageToken());
return results;
}
Can please let me know how to get the actual image from cloud bucket if I am not using app engine library.
Lesv do we have any tutorial in java for object change notification. I am running my application on cloud app engine and need to add this feature as well. Please share some tutorial link so that I can check and implement.
As I remember, the key things about setting up object-change-notification is that you need to have the endpoint setup to respond to the requests before you create the request.
With Tomcat, it's probably GAE Flexible, as GAE Standard uses Jetty as it's servlet container. It's reasonable to have a sample, I'm still scheduling the Q, will know more later this week.
Activity
lesv commentedon Jun 13, 2017
These apis are meant to be called from App Engine or from the development environment. For Image transformation on your own Tomcat server, you might wish to use a java image transform library.
yasikmondal commentedon Jun 13, 2017
I am deploying my application on tomcat but getting the image object from google cloud storage bucket.
In that case which library I need to use in my application (in eclipse) java image transform library or Google Cloud App engine library ?
lesv commentedon Jun 13, 2017
Since you are running your app on your machine you will want to use something like: https://stackoverflow.com/questions/5895829/resizing-image-in-java
yasikmondal commentedon Jun 14, 2017
Thanks lesv.. but before that I have to get the image from cloud bucket and for that I am using this method which is not giving the actual image.
Can please let me know how to get the actual image from cloud bucket if I am not using app engine library.
lesv commentedon Jun 14, 2017
You might wish to use some older apis [docs] [example]
yasikmondal commentedon Jun 24, 2017
Lesv do we have any tutorial in java for object change notification. I am running my application on cloud app engine and need to add this feature as well. Please share some tutorial link so that I can check and implement.
lesv commentedon Jun 25, 2017
Take a look at Object-Change-Notifications -- There is a python example. (of course, now there are pub/sub notifications)
As I remember, the key things about setting up object-change-notification is that you need to have the endpoint setup to respond to the requests before you create the request.
yasikmondal commentedon Jun 27, 2017
@lesv : Do you have any example with source code (in JAVA). so that I can check.
lesv commentedon Jun 28, 2017
On GAE standard, Flex, or somewhere else? I'll add it to the todo list for next Q.
yasikmondal commentedon Jul 14, 2017
@lesv I am running my code on GAE . Do you have any update for this Enhancement in Java?
lesv commentedon Jul 17, 2017
With Tomcat, it's probably GAE Flexible, as GAE Standard uses Jetty as it's servlet container. It's reasonable to have a sample, I'm still scheduling the Q, will know more later this week.
yasikmondal commentedon Aug 1, 2017
@lesv any update on this ? do we have any sample..
6 remaining items
kurtisvg commentedon Jun 10, 2019
Notice: this issue has been closed because it has been inactive for 652 days. You may reopen this issue if it has been closed in error.
chore(deps): update dependency com.google.cloud:google-cloud-datalabe…
chore(deps): update dependency com.google.cloud:google-cloud-datalabe…
deps: update dependency com.google.cloud:google-cloud-core to v2.1.3 (#…
deps: update dependency com.google.cloud:google-cloud-core to v2.1.3 (#…
deps: update dependency com.google.cloud:google-cloud-core to v2.1.7 (#…
chore(deps): update dependency com.google.cloud:libraries-bom to v23.…
samples: migrate code from googleapis/java-speech (#7437)
chore(deps): update dependency com.google.cloud:google-cloud-aiplatfo…
samples: migrate code from googleapis/java-vision (#7428)
samples: migrate code from googleapis/java-vision (#7428)
samples: migrate code from googleapis/java-aiplatform (#7451)
deps: update dependency com.google.cloud:google-cloud-pubsub to v1.11…
chore: release 3.0.11 (#703)