web stats
SmbFileConnection in MC3 not valid anymore - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 03-18-2014, 12:42 AM
gkittlaus gkittlaus is offline
OBX.3 Kenobi
 
Join Date: Jan 2012
Posts: 104
gkittlaus is on a distinguished road
Default SmbFileConnection in MC3 not valid anymore

Hi,

we were using a function like this in MC2
Code:
//Create SMB file handle with 5 seconds timeout
var fileConn = new com.mirth.connect.connectors.file.filesystems.SmbFileConnection(host, usr, pwd, 5000);
in MC3 we get an error now:
Quote:
[2014-03-18 09:06:18,731] ERROR (filter:?): SMB: InternalError: Can't find method com.mirth.connect.connectors.file.filesystems.SmbF ileConnection.writeFile(org.mozilla.javascript.Con sString,org.mozilla.javascript.ConsString,boolean,[B). (7f091df4-e5dd-4f1b-a425-8adf3d8ca7a5#387)
Thank you and very best regards,
Gregor

EDIT: I work around with JCIFS now. What packages/libs is mirth using internally? apache-fileupload?

Last edited by gkittlaus; 03-18-2014 at 01:46 AM.
Reply With Quote
  #2  
Old 03-18-2014, 06:17 AM
narupley's Avatar
narupley narupley is offline
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,126
narupley is on a distinguished road
Default

That is expected. You're using an internal Mirth Connect class, and as such that class is subject to change between versions without prior notice and without automatic migration of any kind. Only classes we purposefully expose to the user (like those in the User API) are guaranteed to work in newer versions.

The method in question has been changed to take in an InputStream rather than an array of bytes. So you can just wrap your byte array in a ByteArrayInputStream and it should work just fine. On the backend, we're already using JCIFS for SMB file connections.
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #3  
Old 03-18-2014, 06:49 AM
gkittlaus gkittlaus is offline
OBX.3 Kenobi
 
Join Date: Jan 2012
Posts: 104
gkittlaus is on a distinguished road
Default

Thank you for the quick answer
Reply With Quote
Reply

Tags
3.0.1, mirthconnect, share, smb

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 10:15 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Mirth Corporation