webMethods

 View Only
  • 1.  Can't delete folder

    Posted Mon December 12, 2022 07:54 AM

    What product/components do you use and which version/fix level are you on?

    IS 10.5

    Is your question related to the free trial, or to a production (customer) instance?

    PRODUCTION

    What are you trying to achieve? Please describe it in detail.

    I want to delete folder which is located on shared drive :

    \shareDrive\RI_SHARE\RI\INPUTFILES\paymentFiles

    and there is no way from WMPublic methods to delete it.

    I tried to use java Files like this :

    Files.delete(directory); and it gives me

    java.nio.file.AccessDeniedException: \crsrimigas\RI_SHARE\RI\INPUTFILES\paymentFiles

    Some help ??


    #webMethods
    #Application-Platform
    #B2B-Integration


  • 2.  RE: Can't delete folder

    Posted Mon December 12, 2022 08:56 AM

    Hi @Marko_K ,
    If you are trying to delete a directory using a java service, and it fails, please check if you can try a java standalone program to do the same. This looks a permissions issue, and some other process could have a lock on the directory.
    Also, you can check the Server->Logs->Error Log → Expand stacktrace to see, if there is a detailed log of the reason why this failed.

    -NP


    #Application-Platform
    #webMethods
    #B2B-Integration


  • 3.  RE: Can't delete folder

    Posted Mon December 12, 2022 03:17 PM

    Another consideration – the user being used to attempt to delete the directory simply does not have permission to do so. The error message is very clear – AccessDeniedException.

    Looks like you’re using UNC notation to delete from a Windows share. I’m assuming the JVM hosting Integration Server is also on a Windows machine. The “run as” user of the JVM would need permission to delete that folder.


    #B2B-Integration
    #webMethods
    #Application-Platform


  • 4.  RE: Can't delete folder

    Posted Tue December 27, 2022 09:05 AM

    The problem was that WM server was not started through services with the proper user which has the right to that folder. When started with proper user, everything works as expected.


    #Application-Platform
    #webMethods
    #B2B-Integration