View Poll Results: If you read it, did you find DirectJNgine User's Guide adequate?

Voters
54. You may not vote on this poll
  • Yes

    40 74.07%
  • No

    14 25.93%
  1. #271
    Ext User
    Join Date
    Aug 2009
    Posts
    20
    Vote Rating
    0
    vlagorce is on a distinguished road

      0  

    Default


    Hi Pedro,

    I try to upgrade my Djn-spring dev environment to the version 1.3.aplha1.


    As you know I use maven to manage my dependency. I found 4 new jar.
    I faced some problem to resolve some package version.


    [INFO] com.softwarementors.extjs:djn:jar:1.3.aplha1
    [INFO] +- javax.servletervlet-api:jar:2.5:provided
    [INFO] +- commons-fileupload:commons-fileupload:jar:1.2.1:compile
    [INFO] +- commons-io:commons-io:jar:1.4:compile
    [INFO] +- commons-lang:commons-lang:jar:2.3:compile
    [INFO] +- com.google.code.gson:gson:jar:1.3:compile
    [INFO] +- jargs:jargs:jar:1.0:runtime
    [INFO] +- log4j:log4j:jar:1.2.15:compile
    [INFO] +- rhino:js:jar:1.6R7:runtime
    [INFO] +- com.yahoo:yuicompressor:jar:2.4.2:compile
    [INFO] +- org.testng:testng:jar:jdk15:5.7:test
    [INFO] | \- junit:junit:jar:3.8.1:test
    [INFO] +- com.google.code.findbugs:jsr305:jar:1.3.9:provided
    [INFO] +- com.google.code.findbugs:annotations:jar:1.3.9:provided
    [INFO] \- com.google.appengine:appengine-api-1.0-agentimpl:jar:1.3.2:provided
    [INFO] \- com.google.appengine:appengine-api-1.0-agent:jar:1.3.2:provided


    Please can you confirm that I have resolve the right version number.


    I'll send you soon some needed modification in your code to allow IOC framework to deal with DJN.


    Regards,
    Vincent

  2. #272
    Ext JS Premium Member
    Join Date
    May 2009
    Location
    Barcelona (Spain)
    Posts
    218
    Vote Rating
    19
    pagullo will become famous soon enough pagullo will become famous soon enough

      0  

    Default


    Quote Originally Posted by vlagorce View Post
    Hi Pedro,
    Please can you confirm that I have resolve the right version number.
    Hi!

    I found two minor issues:

    - Servlet API is 2.4, not 2.5 -though I'm quite sure we could use older versions, just haven't tried...
    - I do not include JUnit.

    And, btw, I've noticed that you mention 'log4j....jar' and other jars as needed at compile time only. If that's meaningful for you, you might need to check the jars again.

    It looks like everything else is ok :-)

    Best regards,
    Pedro Agulló, Barcelona (Spain)
    Agile team building, consulting, training & development
    DirectJNgine: http://code.google.com/p/directjngine - Log4js-ext: http://www.softwarementors.com/projects/p/log4js-ext/

  3. #273
    Ext User
    Join Date
    Aug 2009
    Posts
    20
    Vote Rating
    0
    vlagorce is on a distinguished road

      0  

    Default


    Quote Originally Posted by pagullo View Post
    Hi!

    I found two minor issues:

    - Servlet API is 2.4, not 2.5 -though I'm quite sure we could use older versions, just haven't tried...
    - I do not include JUnit.

    And, btw, I've noticed that you mention 'log4j....jar' and other jars as needed at compile time only. If that's meaningful for you, you might need to check the jars again.

    It looks like everything else is ok :-)

    Best regards,
    Thank you,

    I have change to the Servlet-Api 2.4.(All my project execute successfully with 2.5)

    Junit3.8.1 is a maven transitiv dependency( testng.jar maven definition request this jar). Testng is only needed for testing there is no problem to keep this dependency.(User can easily exclude the dependency).


    Compile : the jar is need to compile and will be used during the runtime.
    Runtime : the jar isn't need to compile but will be used during the runtime
    Provided: the jar is need to compile but and other is provided during the runtime
    Test : like compile but just when running test

    Best regards

  4. #274
    Ext User
    Join Date
    Apr 2010
    Posts
    1
    Vote Rating
    0
    harmen_wessels is on a distinguished road

      0  

    Default


    I am currently considering using the directjngine. For this I have a question:

    When writing procedures in Java and offering them through Ext Direct using the annotation, how can I restrict access to certain users?
    Is there some functionality included in the API for handling authentication and authorization?

    Thanks inadvance.

    Regards,
    Harmen.

  5. #275
    Ext JS Premium Member
    Join Date
    May 2009
    Location
    Barcelona (Spain)
    Posts
    218
    Vote Rating
    19
    pagullo will become famous soon enough pagullo will become famous soon enough

      0  

    Default


    Quote Originally Posted by harmen_wessels View Post
    When writing procedures in Java and offering them through Ext Direct using the annotation, how can I restrict access to certain users?
    Is there some functionality included in the API for handling authentication and authorization?
    Harmen,

    There is no support for things such as authentication, authorization, etc. The intention of DirectJNgine is to provide just an ExtJs-Java bridge.

    If you have a strong business layer (a big if!), you should build the classes in the "bridge" layer (the objects DJN passes back and forth, as well as the classes that handle the Javascript calls) so that they delegate in your business classes, which is where I would place those access restrictions.

    As a best practice, the "bridge" layer should be as thin as possible and very ExtJs-oriented (i.e., fields, etc. corresponding to what the Javascript code will consume/return back to the business code). This will end up in cleaner code in the long run.

    Hope this scenario fits your needs, and we see you using DJN!

    Best regards,
    Pedro Agulló, Barcelona (Spain)
    Agile team building, consulting, training & development
    DirectJNgine: http://code.google.com/p/directjngine - Log4js-ext: http://www.softwarementors.com/projects/p/log4js-ext/

  6. #276
    Sencha User
    Join Date
    Nov 2007
    Posts
    294
    Vote Rating
    0
    Sesshomurai is on a distinguished road

      0  

    Default


    Hi,
    I am using the WebContextManager to get the servlet context and session in my direct methods to set session state.

    In a separate servlet, in same webapp, I want to get that state from the session, but its not visible. Is there a way to do this?
    I am using Tomcat 6.

    Thanks for any tips.

  7. #277
    Sencha User chrizmaster's Avatar
    Join Date
    Feb 2009
    Location
    Australia
    Posts
    441
    Vote Rating
    1
    chrizmaster is on a distinguished road

      0  

    Default Out of MemoryException!

    Out of MemoryException!


    Hi,

    i use the polling service as described in your documentation, but after about 8 - 10 minutes of letting it run, I got an OutOfMemory Exception...

    If I looked at my Processbar, I see that Tomcat has 100 Threads.
    Everytime I call a function which uses your framework, 1 thread will be added and the memory increases about 100 kb..

    Here's the code for my polling service

    PHP Code:
    ar pollingProvider Ext.Direct.addProvider({ 
      
    type'polling'
      
    interval1000*60,// 1 min 
      
    urlExt.app.POLLING_URLS.message
      
    listeners: { 
        
    data: function(providerevent) {
            if(!
    event.status){//if sc-server is "dead"
                
    Ext.Msg.show({
                    
    title    :lng.getEntry("startmenu.common.fail"),
                    
    msg        lng.getEntry("err.msg4"),
                    
    buttons    Ext.Msg.OK,
                    
    fn        :function(){
                          
                        
    Ext.ux.io.server.doAutomaticallyLogout();
                       
                    },                                   
                       
    animEl'elId',
                    
    iconExt.MessageBox.ERROR
                
    });        
                
    /** disconnect polling provider to prevent message overlay **/
                
    pollingProvider.disconnect();
            }
        } 
      } 
    }); 
     
    pollingProvider.connect(); 
    And here's the error:
    PHP Code:
    SCHWERWIEGENDStandardWrapper.Throwable
    java
    .lang.OutOfMemoryErrorJava heap space
        at java
    .lang.String.valueOf(String.java:2706)
        
    at java.lang.Character.toString(Character.java:2149)
        
    at com.yahoo.platform.yui.compressor.JavaScriptCompressor.<clinit>(JavaScriptCompressor.java:69)
        
    at com.softwarementors.extjs.djn.jscodegen.Minifier.minify(Minifier.java:67)
        
    at com.softwarementors.extjs.djn.jscodegen.CodeFileGenerator.saveCode(CodeFileGenerator.java:104)
        
    at com.softwarementors.extjs.djn.jscodegen.CodeFileGenerator.updateApiFiles(CodeFileGenerator.java:64)
        
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.createDirectJNgineRouter(DirectJNgineServlet.java:159)
        
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.init(DirectJNgineServlet.java:119)
        
    at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1172)
        
    at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:992)
        
    at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4058)
        
    at org.apache.catalina.core.StandardContext.start(StandardContext.java:4371)
        
    at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3099)
        
    at org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:404)
        
    at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1309)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
        
    at java.lang.Thread.run(Thread.java:613)
    27.04.2010 12:52:28 org.apache.catalina.core.StandardContext loadOnStartup
    SCHWERWIEGEND
    Servlet  threw load() exception
    java
    .lang.OutOfMemoryErrorJava heap space
        at java
    .lang.String.valueOf(String.java:2706)
        
    at java.lang.Character.toString(Character.java:2149)
        
    at com.yahoo.platform.yui.compressor.JavaScriptCompressor.<clinit>(JavaScriptCompressor.java:69)
        
    at com.softwarementors.extjs.djn.jscodegen.Minifier.minify(Minifier.java:67)
        
    at com.softwarementors.extjs.djn.jscodegen.CodeFileGenerator.saveCode(CodeFileGenerator.java:104)
        
    at com.softwarementors.extjs.djn.jscodegen.CodeFileGenerator.updateApiFiles(CodeFileGenerator.java:64)
        
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.createDirectJNgineRouter(DirectJNgineServlet.java:159)
        
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.init(DirectJNgineServlet.java:119)
        
    at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1172)
        
    at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:992)
        
    at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4058)
        
    at org.apache.catalina.core.StandardContext.start(StandardContext.java:4371)
        
    at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3099)
        
    at org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:404)
        
    at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1309)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1601)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1610)
        
    at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1590)
        
    at java.lang.Thread.run(Thread.java:613)
    Exception in thread "http-8080-6" java.lang.NullPointerException
        at java
    .util.concurrent.ConcurrentLinkedQueue.offer(ConcurrentLinkedQueue.java:180)
        
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler$1.offer(Http11Protocol.java:532)
        
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler$1.offer(Http11Protocol.java:549)
        
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:613

  8. #278
    Ext JS Premium Member
    Join Date
    May 2009
    Location
    Barcelona (Spain)
    Posts
    218
    Vote Rating
    19
    pagullo will become famous soon enough pagullo will become famous soon enough

      0  

    Default


    Quote Originally Posted by Sesshomurai View Post
    Hi,
    I am using the WebContextManager to get the servlet context and session in my direct methods to set session state.

    In a separate servlet, in same webapp, I want to get that state from the session, but its not visible. Is there a way to do this?
    Session scoped actions are stored in the HttpSession with the following attribute name:
    "DirectJNgine.SESSION." + actionName
    Pedro Agulló, Barcelona (Spain)
    Agile team building, consulting, training & development
    DirectJNgine: http://code.google.com/p/directjngine - Log4js-ext: http://www.softwarementors.com/projects/p/log4js-ext/

  9. #279
    Ext JS Premium Member
    Join Date
    May 2009
    Location
    Barcelona (Spain)
    Posts
    218
    Vote Rating
    19
    pagullo will become famous soon enough pagullo will become famous soon enough

      0  

    Default


    Quote Originally Posted by chrizmaster View Post
    Hi,

    i use the polling service as described in your documentation, but after about 8 - 10 minutes of letting it run, I got an OutOfMemory Exception...

    If I looked at my Processbar, I see that Tomcat has 100 Threads.
    Everytime I call a function which uses your framework, 1 thread will be added and the memory increases about 100 kb..
    Hi, Chris:

    Before I start to dig, I need some additional information that might help me investigate the issue:

    - What version of DJN are you using?
    - What's the value of the batchRequestsMultithreadingEnabled entry in web.xml?
    - Is the application/servlet being reloaded, maybe accidentally? Believe it or not, this happened to somebody else, and he had very similar symptoms (!)
    - Are you using batched requests?
    - If you do not use polling operations, and use the application extensively, does the same happen? Do many threads appear that are never stopped?
    - Are you using Tomcat? What else? What version?
    - Can you send me the Java code being executed by the request?
    - What's your OS?

    I will take a look at this asap once I get your feedback.

    Additionally, could you please set batchRequestsMultithreadingEnabled to false in web.xml, and see what happens?

    Thanks for reporting this!
    Pedro Agulló, Barcelona (Spain)
    Agile team building, consulting, training & development
    DirectJNgine: http://code.google.com/p/directjngine - Log4js-ext: http://www.softwarementors.com/projects/p/log4js-ext/

  10. #280
    Sencha User chrizmaster's Avatar
    Join Date
    Feb 2009
    Location
    Australia
    Posts
    441
    Vote Rating
    1
    chrizmaster is on a distinguished road

      0  

    Default


    Hey,

    Quote Originally Posted by pagullo View Post
    Hi, Chris:

    Before I start to dig, I need some additional information that might help me investigate the issue:

    - What version of DJN are you using?
    V 1.2

    - What's the value of the batchRequestsMultithreadingEnabled entry in web.xml?
    true

    - Is the application/servlet being reloaded, maybe accidentally? Believe it or not, this happened to somebody else, and he had very similar symptoms (!)
    it could be that the servlet has been reloaded, im not fully sure, because Im using Eclipse with Tomcat. If I save something in the backend, im not sure whether the servlet will be reloaded or not.

    - Are you using batched requests?
    yes

    - If you do not use polling operations, and use the application extensively, does the same happen? Do many threads appear that are never stopped?
    I could'nt reproduce the error jet, but I'll let a testcase run the whole night and see what happens. BUT I recognized that the memory increases with "normal" calls as well. (Means if I don't use pollingservice, but other functions, that using your framework.

    - Are you using Tomcat? What else? What version?
    Tomcat 6 and Java 5

    - Can you send me the Java code being executed by the request?
    It's a simple XmlRpc call. Im afraid you can't run it, because I can'T provide u the backend server, but Im sure it's not because of the xmlrpc.

    - What's your OS?
    Mac OS 10.5.8
    mhm, during the report, I thought about if it's really the polling service, cause I recognized that the memory increases if I do "normal" calls as well...

    Christian

Thread Participants: 88

  1. Animal (5 Posts)
  2. barton (4 Posts)
  3. Condor (1 Post)
  4. mauro_monti (6 Posts)
  5. mbarto (1 Post)
  6. aconran (1 Post)
  7. MoShAn480 (1 Post)
  8. asgillett (2 Posts)
  9. seade (6 Posts)
  10. zaqwsxqwer (3 Posts)
  11. Sesshomurai (16 Posts)
  12. ThierryC (3 Posts)
  13. maxm165 (3 Posts)
  14. techstudios (2 Posts)
  15. sayonara (2 Posts)
  16. kschlaudt (1 Post)
  17. hschaefer123 (2 Posts)
  18. omarc (2 Posts)
  19. lxbzmy (4 Posts)
  20. mct (6 Posts)
  21. mediacept (2 Posts)
  22. dionisexorcius (1 Post)
  23. alper (1 Post)
  24. steverc (2 Posts)
  25. chrizmaster (18 Posts)
  26. J@y (21 Posts)
  27. Georgioa (6 Posts)
  28. wguan (1 Post)
  29. minneyar (16 Posts)
  30. jhoweaa (1 Post)
  31. Ramez (2 Posts)
  32. malus (1 Post)
  33. dweller (8 Posts)
  34. stdunbar (1 Post)
  35. vlagorce (20 Posts)
  36. cwilliso (1 Post)
  37. Whatty (13 Posts)
  38. Ice (1 Post)
  39. clynnh (1 Post)
  40. SreevaniN (1 Post)
  41. Stsalomon90 (1 Post)
  42. GregT (9 Posts)
  43. jcalfee (6 Posts)
  44. set_ti (1 Post)
  45. maho2nd (3 Posts)
  46. dreamtaotao (3 Posts)
  47. Toxa (4 Posts)
  48. tungchau (3 Posts)
  49. wlan0 (2 Posts)
  50. jpr (2 Posts)
  51. gianmarco (5 Posts)
  52. extjslikeit (2 Posts)
  53. harmen_wessels (1 Post)
  54. Olivercomputing2 (4 Posts)
  55. brainformance (2 Posts)
  56. vanessa_ng (2 Posts)
  57. alois.cochard (5 Posts)
  58. kyrillos52 (2 Posts)
  59. Tod (1 Post)
  60. Alinanila (1 Post)
  61. tfannon (2 Posts)
  62. Kynao (1 Post)
  63. feiq (4 Posts)
  64. dalt (1 Post)
  65. xfolch (1 Post)
  66. avijit (1 Post)
  67. marcelsnews (2 Posts)
  68. maddhippy (1 Post)
  69. sritter (1 Post)
  70. july (2 Posts)
  71. jtkeller7983 (1 Post)
  72. lfranchini (2 Posts)
  73. 7/11 (2 Posts)
  74. yAdEs (1 Post)
  75. zazz (1 Post)
  76. waqar (5 Posts)
  77. pjain11 (1 Post)
  78. alexMobimesh (2 Posts)
  79. zachHurt (4 Posts)
  80. n0n3 (5 Posts)
  81. adavis2 (1 Post)
  82. mark.peters (1 Post)
  83. lee el (4 Posts)
  84. frengo19 (3 Posts)
  85. prakashwagle (1 Post)
  86. extejnar (2 Posts)
  87. alin@sonatype.com (1 Post)
  88. ajay_kango (3 Posts)