2014-04-08 71 views
0

AppEngineProble與谷歌的AppEngine與Java「HTTP錯誤500」

是新的文件訪問權限我試圖TRAITE在我的桌面文件與servlet

我用這個代碼

BufferedReader breader = new BufferedReader(new FileReader("my source file")); 
    weka.core.Instances train = new Instances (breader); 
     breader.close(); 

「我藏有源文件」

所以我有在執行這個錯誤

HTTP ERROR 500 

Problem accessing /testservlet. Reason: 

access denied ("java.io.FilePermission" "source file derectory" "read") 
Caused by: 

Caused by: 

java.security.AccessControlException: access denied ("java.io.FilePermission"   "soure file derectory" "read") 
at java.security.AccessControlContext.checkPermission(Unknown Source) 
at java.security.AccessController.checkPermission(Unknown Source) 
at java.lang.SecurityManager.checkPermission(Unknown Source) 
at com.google.appengine.tools.development.DevAppServerFactory$CustomSecurityManager.checkPermission(DevAppServerFactory.java:429) 
at java.lang.SecurityManager.checkRead(Unknown Source) 
at java.io.FileInputStream.<init>(Unknown Source) 
at java.io.FileInputStream.<init>(Unknown Source) 

請問你能提出,這有什麼問題嗎?

+0

你有此文件的讀取權限?這與App Engine有什麼關係? –

回答

0

您無法訪問使用Java文件IO類已被禁用

看一看這一:

bloblstore

+0

感謝您的回覆,您可以給我一個簡單的說明,說明我在使用servlet和AppEngine打開和讀取文件的過程中做什麼,以及blobstore API的具體做法 – user3511444