Skip to main content
Nintex Community Menu Bar

File Service Broker v2.0

  • Aug 22, 2016 7:52 PM UTC
  • 48 replies
  • 1228 views
  • Translate All

Forum|alt.badge.img+4

File Service Broker v2.0

 

 

 

 

This custom service broker allows the user to perform the following functions based on a full file path

 

 

  •  
  • Read from a file
  • Write a file to a folder location
  • Delete a file
  • Get a list of full path files names from a directory
  • Get a list of full path sub-directory names from a directory

     

 

 

This custom service broker is based on the original File Service Broker v1 written by Johnny Fang,

 

 

 

 

However, Please note that the two versions and function set are not compatible.

 

 

 

 

48 replies

Forum|alt.badge.img+5

Does this work for Network Share?

Translate

Forum|alt.badge.img+4
  • Author
  • Nov 17, 2016 2:42 AM UTC

Sorry for the late reply. Yes this should work with network share file paths, as long as the correct folder permissions are granted to the account assigned to run this service instance.

Translate

Forum|alt.badge.img+3

So far, this appears to work on 4.7 with the February cumulative update.  This may be obvious to everyone else, but I did have to go to the properties of the .dll file and unblock it in order to get it to work.

Translate

  • Apr 13, 2017 2:57 PM UTC

How can I get the File Size of a file using this service?

Translate

  • Apr 19, 2017 7:14 PM UTC

 Has anybody used the GetFiles method in a workflow in a for each loop? When I try to run a for each loop for each file using the GetFiles method in the folder, the File Name returned is a concatenation of all the file names in the folder. However when run through the SMO tester, that is not the case. Can somebody help understand this issue? 

Translate

Forum|alt.badge.img+2
  • May 5, 2017 12:18 PM UTC

Does this work for 4.6+?

 

Translate

  • Sep 27, 2017 1:11 PM UTC

Hello,

What is max file size that can be uploaded using this broker?


EDIT:
I had problem with adding files >20MB all I had to do was change web.config in k2 smartforms runtime and designer.

I made 2 changes:

1) change max file size that can be uploaded to file data file attachment i set it at 200MB by changing: <httpRuntime maxRequestLength="204800" ...

in this case max size must be given in kilobytes

2) change max allowed content size that can be stored:

<requestFiltering allowDoubleEscaping="true" /> 

With this: 

<requestFiltering allowDoubleEscaping="true">
    <requestLimits maxAllowedContentLength="209715200" />
</requestFiltering>

in this case max size must be given in bytes

 

https://community.k2.com/t5/K2-blackpearl-Articles/How-to-increase-default-file-size-limit-for-File-Attachment/ta-p/92828?nobounce=

 

Hope it will help someone someday

 

Greetings,

Wojtek

Translate

Forum|alt.badge.img+7
  • Oct 27, 2017 8:11 PM UTC

I got this to work in a for each loop to move 6 files  but it placed all the files in a folder with the date. Is there any way I can get this to not put in a folder as I need them directly in the root folder for another process to pick them up.

Translate

Forum|alt.badge.img+5

Hi,

How do I install this if the service isnt listed in the smartobject tester? I have unblocked the file in the service broker folder but it still doesnt appear in the list.

Thanks.

Translate

  • Nov 16, 2017 12:19 PM UTC

Peanutbutter22 

Have you copied "SourceCode.SmartObjects.Services.FileService.dll" to folder containing all service brokers? Its in install directoryServiceBroker (standard path: "C:Program Files (x86)K2 blackpearlServiceBroker".

Wojtek

Translate

Forum|alt.badge.img+4
  • Author
  • Nov 20, 2017 5:42 AM UTC

Hi MickiC,

 

  The functionality you are referring to seems to be based on v1.0 version of the broker. That version automatically appends the date folder underneath it. Can you check again with this version?

Translate

Forum|alt.badge.img+4
  • Author
  • Nov 20, 2017 5:43 AM UTC

Thanks Wojciech for your assistance with the fiel size check

 

  @Peanutbutter22 please check if you have done as what Wojciech mentioned.

 

Translate

Forum|alt.badge.img+5

Hi, yes I copied it across and unlocked it in the properties but it still doesn't appear. Thanks!

Translate

  • Dec 29, 2017 10:32 PM UTC

@peanutbutter22 - were you ever able to resolve your issue? We are having similar issues...

Translate

Forum|alt.badge.img+18
  • Dec 29, 2017 10:49 PM UTC


 


I assume it is not appearring when attempting to register the ServiceType?


 


Usually registering a broker will involve:


1.  Registering the ServiceType (the .dll assembly); this will surface the Service Broker and will be visible in the "ServiceObject Explorer" category afterwards


 


2.  The right clicking on the Service Broker to register the Service Instance:



 


3.  Then finally right clicking on the Service Instance to create/generate the SmartObject, or select the applicable Service Objects.

Translate

Forum|alt.badge.img+8
  • Rookie
  • Apr 6, 2018 12:50 AM UTC

can it work in conjunction with the exchange mailbox service broker?

i would like to read an ameil, read the attachment and then save to file location

Translate

Forum|alt.badge.img+2
  • Nintex Partner
  • Jul 8, 2018 3:57 PM UTC

Hi,

 

I found an issue in the case that I would like to display the file attachment control in the list view.

I execute the read method with the filepath as parameter. But the file attachment control show as blank even though I transfer the "File data" output from the file service broker smartobject.

 

I tried to show only path and make sure that the path is correct.

 

Does anyone face this problem?

Translate

Forum|alt.badge.img+4
  • Author
  • Jul 9, 2018 9:09 AM UTC

Hi Amornthep,

 

   If you are binding the list view to a list method like [Get Files], the full file path is returned via the [File Name] property, and not the [File Path] property. File Path was intended to be a input pararmeter for the method calls.

 

 

Translate

Forum|alt.badge.img+2
  • Nintex Partner
  • Jul 9, 2018 3:47 PM UTC

Thank you for your response.

 

Appreciated!!!

Translate

Forum|alt.badge.img+4
  • Author
  • Aug 9, 2018 8:43 AM UTC

The community website is undergoing a revamp, and  I think the download links are taken down temporarily. Hopefully it should be back up soon.

Translate

Forum|alt.badge.img+1
  • Aug 21, 2018 6:09 PM UTC

 I am trying to execute the File System Service.Create method within my workflow and noticed that "Content" is a required input.  If you execute the method via the SmO Tester, only File Name and File Path are required.  

1. Is there a way to change this so that Content is not required?

2. If not, then what is the best way to obtain and input the file's Content?

 

Translate

Forum|alt.badge.img+1
  • Aug 21, 2018 7:48 PM UTC

1 more question in addition to the one above - in an earlier comment I saw it mentioned that this should work for network share file paths, however I can only seem to get it to work locally.  Is this something that has been addressed and has anyone been able successful in moving files to network share paths?  

Note, the account trying to execute this has the the proper access to the specific folder it's writing to, so it does not appear to be a permissions issue.  

Translate

Forum|alt.badge.img+7
  • Aug 21, 2018 8:31 PM UTC

I am using this broker in an a K2 Studio workflow runing 4.7 where I get files from an email in exchange and move them to a file share with a UNC. If it would help I can get some print screens of my configuration.

Translate

Forum|alt.badge.img+7
  • Aug 21, 2018 9:03 PM UTC

For the other question the input called filedata.content is the actual file through whatever method you are calling store the file in a value and put that value in as content. It would help to understand your workflow to be more specific. Where is the file originating from?

Translate

Forum|alt.badge.img+2

Thanks JamesKho for your work.

Works well with K2 5.1 on prem.

 

@mh 

I just installed it did a quick test and was able to copy (create method) a file from the smartobject tester to a network location.Works fine. so yes i can confirm it works for the network locations

Translate