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. #401
    Sencha User
    Join Date
    Jun 2011
    Posts
    8
    Vote Rating
    0
    jtkeller7983 is on a distinguished road

      0  

    Default OOM when uploading large files.

    OOM when uploading large files.


    We are using ExtJS's File field along with the DirectJEngine and we are getting OOM's because it wants the file to be loaded in memory (see stacktrace below). Obviously, this will not work for large files. What's out options?

    java.lang.OutOfMemoryError: Java heap space
    at org.apache.commons.io.output.ByteArrayOutputStream.needNewBuffer(ByteArrayOutputStream.java:128)
    at org.apache.commons.io.output.ByteArrayOutputStream.write(ByteArrayOutputStream.java:158)
    at org.apache.commons.io.output.ThresholdingOutputStream.write(ThresholdingOutputStream.java:128)
    at org.apache.commons.fileupload.util.Streams.copy(Streams.java:101)
    at org.apache.commons.fileupload.util.Streams.copy(Streams.java:64)
    at org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase.java:362)
    at org.apache.commons.fileupload.servlet.ServletFileUpload.parseRequest(ServletFileUpload.java:126)
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.getFileItems(DirectJNgineServlet.java:657)
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.processUploadFormPost(DirectJNgineServlet.java:645)
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.processRequest(DirectJNgineServlet.java:613)
    at com.softwarementors.extjs.djn.servlet.DirectJNgineServlet.doPost(DirectJNgineServlet.java:580)

  2. #402
    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


    The easiest workaround will be to increment the allocated VM memory to be able to handle the biggest file size you inted to support.

    Of course, the best and nicest way to do this would be to use the alternative way of handling files the apache FileUpload library provides, that allows you to handle the stream of data on your own (http://commons.apache.org/fileupload/streaming.html): perhaps you can take a look at the source code and work it out? Unfortunately, I am way too busy to do this myself right now.
    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. #403
    Ext JS Premium Member
    Join Date
    Dec 2011
    Posts
    5
    Vote Rating
    0
    zazz is on a distinguished road

      0  

    Default


    Hi,

    When will production version of DJN 2.0 be available. I see you have an alpha posted in July but no activity since then

    thanks

    ~Michael

  4. #404
    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 DJN 2.0

    DJN 2.0


    DJN 2.0 alpha will probably become 2.0 as is, as no changes to functionality have been made. You can use it as is, it is extremely robust.

    I haven't delivered 2.0 yet because I would like to update the documentation (not many changes, really, but have to check it all) and add some minor things. If I do not find time to do that, I will just push the current alpha .jar as final at the beginning of the year.

    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/

  5. #405
    Sencha User
    Join Date
    Nov 2010
    Posts
    13
    Vote Rating
    1
    Kynao is on a distinguished road

      0  

    Default


    Is DirectJNgine comet capable ?
    Am i completly missing something or there are just a few extjs components supporting ext direct ?
    I would be glad to be wrong and a list of supported components would be useful.

  6. #406
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Question DirectJNgine woth Spring3

    DirectJNgine woth Spring3


    Hello Guys;
    I am in a middle of transition from ExtJs3 to ExtJs4 and I have heavly relied on DIRECTJNgine for communication this time.

    Right now I am facing problem with DirectJNgine direct calls, I can login succesfully (non Direct call form submit) in my application, and then my main page loads,

    but when I make a "DIRECT" call to my Java controller to fetch the name of the user saved in session using :
    "SecurityContextHolder.getContext().getAuthentication()" comes out to be null.

    My security config in web.xml :
    Code:
    <filter>
            <filter-name>springSecurityFilterChain</filter-name>
            <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
        </filter>
        <filter-mapping>
            <filter-name>springSecurityFilterChain</filter-name>
            <url-pattern>/*</url-pattern>
        </filter-mapping>
    My DirectStore in JS:
    Code:
    buildUserGridStore: function(){
                return new Ext.data.DirectStore( {
                        autoLoad: true,
                        paramsAsHash:false,
                        root:'',
                        directFn: UserController.loadAllByCriteria,
                        idProperty:'userId',
                        paramOrder: [],
                        fields: [
                          {name: 'userId'},
                          {name: 'userName'},
                        ],
                        listeners: {
                            exception: function(misc){
                                alert("exception occured: " + misc);
                            },
                            load: function(s, records){
                                console.info( "User Loaded " + records.length + " records");
                            }
                        }
                    });
                }
    });
    In My Java Controller:
    Code:
        @DirectMethod
        public List<UserVo> loadAllByCriteria() {
                  Authentication authentication = 
    SecurityContextHolder.getContext().getAuthentication();
    if(authentication != null){
    baseService().getAllUsers()
    }
    return null;
         }
    I am getting SecurityContextHolder.getContext().getAuthentication() NULL ! Any help will be appreciated,.

    I am running short of time

    please help!!

  7. #407
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Default about User guide Beta

    about User guide Beta


    Let me add some more info that I am using DJN2.0 to stay updated with EXTJS4 + DJN2.0

    and I was using User Guide alpha "DirectJNgine_User_Guide.2.0-alpha1.pdf" which explicitly said base params are not working with direct store? but I don't see any information about them "working or not "in beta version of the document.

    Secondly I still could not sort out why the Direct calls from DJN are comming out of spring security becuase when the DJN remote call is recieved the java code :
    Code:
    "SecurityContextHolder.getContext().getAuthentication()" returns null ...
    Looking forward for suggestions.

  8. #408
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Default


    @Pagullo;
    Hi,
    Did the direct calls have started supporting the Base Params in Extjs4 + DJN 2.0 ? any updates ?


    Quote Originally Posted by pagullo View Post
    DJN 2.0 alpha will probably become 2.0 as is, as no changes to functionality have been made. You can use it as is, it is extremely robust.

    I haven't delivered 2.0 yet because I would like to update the documentation (not many changes, really, but have to check it all) and add some minor things. If I do not find time to do that, I will just push the current alpha .jar as final at the beginning of the year.

    Regards,

  9. #409
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Default Form post not working

    Form post not working


    Hi I am trying submit a form this way (as explained in the User Guide DJN 2.0 alpha1)

    Code:
    handler: function(){
        Profile.updateBasicInfo(form.getForm().el, function(result, e){});
    }
    My Code : (used to work in ExtJs3 + DJN 1.3)
    Code:
    if (btn == 'yes') {
        console.info(form.getForm().el);  //   THIS appears UNDEFINED (I am sure this is the problem)
        console.info(form.getForm().getValues());  // I TRIED PASSING THIS but it didnt worked
        UserController.deleteUser(form.getForm().getValues().el, function(result, e){
            if(e.result.success == true){
               //Success Code~
             }
          } 
        });
    }
    Error (in Chrome) :

    Uncaught TypeError: Cannot call method 'getAttribute' of undefined

    I am following UserGuide 2.0 page 20 solution, but any progress on this, any updates, any solution will be really appreciated

  10. #410
    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


    From beginning of DJN documentation for 2.0 alpha:

    Very important!
    The remaining documentation belongs to DirectJNgine 1.3, and is mostly correct:
    however, due to changes in ExtJs 4.x itself that break older ExtJs code, we advise you to
    be careful. If you find some problem, please, contact us.
    As far as we know, code using baseParams is not supported anymore. Besides, we have
    implemented form submitting via the api parameter: the approach we used in ExtJs 3.x
    does not work with ExtJs 4.x anymore, again due to changes in ExtJs itself. See example
    and test code for information on how to support form submit.
    The problem here is due to ExtJs 4.x not being backwards compatible with 3.x in that respect . DJN implementation did not break anything...

    That said, form submit works without a hitch: in order to see how to do it in ExtJs 4, just check the examples & tests DJN provides.

    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/

Thread Participants: 86

  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 (4 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. vanessa_ng (2 Posts)
  56. alois.cochard (5 Posts)
  57. kyrillos52 (2 Posts)
  58. Tod (1 Post)
  59. Alinanila (1 Post)
  60. tfannon (2 Posts)
  61. Kynao (1 Post)
  62. feiq (4 Posts)
  63. dalt (1 Post)
  64. xfolch (1 Post)
  65. avijit (1 Post)
  66. marcelsnews (2 Posts)
  67. maddhippy (1 Post)
  68. sritter (1 Post)
  69. july (2 Posts)
  70. jtkeller7983 (1 Post)
  71. lfranchini (2 Posts)
  72. 7/11 (2 Posts)
  73. yAdEs (1 Post)
  74. zazz (1 Post)
  75. waqar (5 Posts)
  76. pjain11 (1 Post)
  77. alexMobimesh (2 Posts)
  78. zachHurt (4 Posts)
  79. n0n3 (5 Posts)
  80. adavis2 (1 Post)
  81. mark.peters (1 Post)
  82. lee el (4 Posts)
  83. frengo19 (3 Posts)
  84. prakashwagle (1 Post)
  85. extejnar (2 Posts)
  86. alin@sonatype.com (1 Post)