perfomance problem when adding file in big directory

Maksimenko Alexander <[email protected]>
Newsgroups gmane.comp.jakarta.slide.user
Message-ID <[email protected]>
Hi!
I stuck in the following problem -
One of my directories has 2000 files stored in it
while adding file in this directory Slide adds this file as a child of 
the directory and updates it

StructureImpl.class line 344 :

    public void create(SlideToken token, ObjectNode object,
                       String strUri)


                    parentObject = 
parentUri.getStore().retrieveObject(parentUri);  
                     .....
                    parentObject.addChild(newObject);
                    store(token, parentObject, true);



But while storing parent directory StandardRDBMSAdapter (line 136) 
clears all its bindings and adds them again :

            // update binding...

            try {
                clearBinding(connection, uri);
            } catch (ObjectNotFoundException e1) {
                // clear only if it existed
            }
           
            Enumeration bindings = object.enumerateBindings();
            while (bindings.hasMoreElements()) {
                ObjectNode.Binding binding = (ObjectNode.Binding) 
bindings.nextElement();
                try {
                    statement =
                        connection.prepareStatement(
                            "insert into BINDING (URI_ID, NAME, 
CHILD_UURI_ID) select ?, ?, URI_ID from URI where URI_STRING = ?");



So when I add one file in this directory  Slide does 2000 jdbc calls  - 
and it causes very serious perfomance problems

Why Slide clears all bindings when just updating?
Is there some workarounds for this problem?

 
Thanks!
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.