You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Israel Malachi <is...@ellipsis.co.il> on 2014/12/01 08:53:30 UTC

[VFS] VFS sandbox?

Hello all!
I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
samba connections.
When I try to reach smb server I get FileSystemException - Badly formed uri
I understand that I have to import the sandbox jar, but do I get it from?

Re: [VFS] VFS sandbox?

Posted by Dan Tran <da...@gmail.com>.
see https://issues.apache.org/jira/browse/VFS-438

I have the changes at https://svn.codehaus.org/mojo/tags/vfs-1.0/vfs-smb
for reference only, it does not get pushed to Maven Central

-D



On Mon, Dec 1, 2014 at 4:52 AM, Gary Gregory <ga...@gmail.com> wrote:

> Israel,
>
>
> The sandbox is not released as a jar for licensing reasons IIRC. You have
> to check it out of SVN and build it yourself.
>
> Gary
>
> On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
> wrote:
>
> > Hello all!
> > I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> > samba connections.
> > When I try to reach smb server I get FileSystemException - Badly formed
> uri
> > I understand that I have to import the sandbox jar, but do I get it from?
> >
>
>
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory
>

Re: Fwd: [VFS] VFS sandbox?

Posted by Gary Gregory <ga...@gmail.com>.
On Thu, Dec 4, 2014 at 8:23 AM, Gary Gregory <ga...@gmail.com> wrote:

> On Thu, Dec 4, 2014 at 8:13 AM, Schalk Cronj é <ys...@gmail.com> wrote:
>
>> On 04/12/2014 07:39, Israel Malachi wrote:
>>
>>> line 46: extends AbstractFileObject<SmbFileSystem>
>>>
>>> AbstractFileObject is not generic, and can't be parameterized, should I
>>> erase <SmbFileSystem> ?
>>>
>>
> Yes, it is generic:
>
> public abstract class AbstractFileObject<AFS extends AbstractFileSystem>
> implements FileObject
>
> Note that the SVN server is down. If you have old sources, you'll have to
> wait until it comes back alive. There is an Apache blog post somewhere that
> is tracking the status (I don't have the link handy).
>

Ah, here is the link
https://blogs.apache.org/infra/entry/subversion_master_undergoing_emergency_maintenance

Gary

>
> Gary
>
>
>
>>  There are a couple of things you need to do like that as in VFS 2.0
>> those classes are not generic.
>>
>>> line 227: if (e.getErrorCode() == SmbException.ERRbadfile)
>>>
>>> getErrorCode() and ERRbadfile are not defined in SmbException, what to
>>> do?
>>>
>>>  SmbException is a jCIFS class. I think you have to look for
>> e.getNtStatus() instead.
>>
>> I cannot correctly remember all of the details as I ended up writing my
>> own SMB provider for Groovy-VFS.
>>
>>
>> --
>> Schalk W. Cronjé
>> Twitter / Ello / Toeter : @ysb33r
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
>> For additional commands, e-mail: dev-help@commons.apache.org
>>
>>
>
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory
>



-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: Fwd: [VFS] VFS sandbox?

Posted by Gary Gregory <ga...@gmail.com>.
On Thu, Dec 4, 2014 at 8:13 AM, Schalk Cronj é <ys...@gmail.com> wrote:

> On 04/12/2014 07:39, Israel Malachi wrote:
>
>> line 46: extends AbstractFileObject<SmbFileSystem>
>>
>> AbstractFileObject is not generic, and can't be parameterized, should I
>> erase <SmbFileSystem> ?
>>
>
Yes, it is generic:

public abstract class AbstractFileObject<AFS extends AbstractFileSystem>
implements FileObject

Note that the SVN server is down. If you have old sources, you'll have to
wait until it comes back alive. There is an Apache blog post somewhere that
is tracking the status (I don't have the link handy).

Gary



>  There are a couple of things you need to do like that as in VFS 2.0 those
> classes are not generic.
>
>> line 227: if (e.getErrorCode() == SmbException.ERRbadfile)
>>
>> getErrorCode() and ERRbadfile are not defined in SmbException, what to do?
>>
>>  SmbException is a jCIFS class. I think you have to look for
> e.getNtStatus() instead.
>
> I cannot correctly remember all of the details as I ended up writing my
> own SMB provider for Groovy-VFS.
>
>
> --
> Schalk W. Cronjé
> Twitter / Ello / Toeter : @ysb33r
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: Fwd: [VFS] VFS sandbox?

Posted by Schalk Cronjé <ys...@gmail.com>.
On 04/12/2014 07:39, Israel Malachi wrote:
> line 46: extends AbstractFileObject<SmbFileSystem>
>
> AbstractFileObject is not generic, and can't be parameterized, should I
> erase <SmbFileSystem> ?
There are a couple of things you need to do like that as in VFS 2.0 
those classes are not generic.
> line 227: if (e.getErrorCode() == SmbException.ERRbadfile)
>
> getErrorCode() and ERRbadfile are not defined in SmbException, what to do?
>
SmbException is a jCIFS class. I think you have to look for 
e.getNtStatus() instead.

I cannot correctly remember all of the details as I ended up writing my 
own SMB provider for Groovy-VFS.


-- 
Schalk W. Cronjé
Twitter / Ello / Toeter : @ysb33r


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Fwd: [VFS] VFS sandbox?

Posted by Israel Malachi <is...@ellipsis.co.il>.
Hi all

I was trying to follow Gary's advice (and thank you again, Gary) but I ran
into two issues when trying to build the classes

On SmbFileObject

line 46: extends AbstractFileObject<SmbFileSystem>

AbstractFileObject is not generic, and can't be parameterized, should I
erase <SmbFileSystem> ?

line 227: if (e.getErrorCode() == SmbException.ERRbadfile)

getErrorCode() and ERRbadfile are not defined in SmbException, what to do?



---------- Forwarded message ----------
From: Gary Gregory <ga...@gmail.com>
Date: Mon, Dec 1, 2014 at 2:52 PM
Subject: Re: [VFS] VFS sandbox?
To: Commons Developers List <de...@commons.apache.org>


Israel,


The sandbox is not released as a jar for licensing reasons IIRC. You have
to check it out of SVN and build it yourself.

Gary

On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
wrote:

> Hello all!
> I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> samba connections.
> When I try to reach smb server I get FileSystemException - Badly formed
uri
> I understand that I have to import the sandbox jar, but do I get it from?
>



--
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Fwd: [VFS] VFS sandbox?

Posted by Israel Malachi <is...@ellipsis.co.il>.
Hi all

I will try to switch line 227 On SmbFileObject

if (e.getErrorCode() == SmbException.ERRbadfile)

with

if (e.getNtStatus() == SmbException.NT_STATUS_NO_SUCH_FILE)

on my machine and I'll see how it will go...

---------- Forwarded message ----------
From: Israel Malachi <is...@ellipsis.co.il>
Date: Thu, Dec 4, 2014 at 9:41 AM
Subject: Fwd: [VFS] VFS sandbox?
To: Commons Developers List <de...@commons.apache.org>


Hi all

I was trying to follow Gary's advice (and thank you again, Gary) but I ran
into two issues when trying to build the classes

On SmbFileObject

line 46: extends AbstractFileObject<SmbFileSystem>

AbstractFileObject is not generic, and can't be parameterized, should I
erase <SmbFileSystem> ?

line 227: if (e.getErrorCode() == SmbException.ERRbadfile)

getErrorCode() and ERRbadfile are not defined in SmbException, what to do?



---------- Forwarded message ----------
From: Gary Gregory <ga...@gmail.com>
Date: Mon, Dec 1, 2014 at 2:52 PM
Subject: Re: [VFS] VFS sandbox?
To: Commons Developers List <de...@commons.apache.org>


Israel,


The sandbox is not released as a jar for licensing reasons IIRC. You have
to check it out of SVN and build it yourself.

Gary

On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
wrote:

> Hello all!
> I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> samba connections.
> When I try to reach smb server I get FileSystemException - Badly formed
uri
> I understand that I have to import the sandbox jar, but do I get it from?
>



--
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: [VFS] VFS sandbox?

Posted by Bernd Eckenfels <ec...@zusammenkunft.net>.
Hello,

your problem is a Version Mismatch. The Generics will be there in 2.1, so if you want to Build the Sandbox you need to check Out the 2.0 tag. Or (which I think is better) you check put the project (Patent to Core and Sandbox) from the Trunk and Build both in one go. 

(Having Said that, we should raise the Version number in the POM)

It would actually be helpfull if you can Report back, if the new Version works in your Scenario: rember it is not an official release yet. (And I am not Sure of the mighty builds contain the sendbox)

Gruß
Bernd


> Am 04.12.2014 um 08:41 schrieb Israel Malachi <is...@ellipsis.co.il>:
> 
> Hi all
> 
> I was trying to follow Gary's advice (and thank you again, Gary) but I ran
> into two issues when trying to build the classes
> 
> On SmbFileObject
> 
> line 46: extends AbstractFileObject<SmbFileSystem>
> 
> AbstractFileObject is not generic, and can't be parameterized, should I
> erase <SmbFileSystem> ?
> 
> line 227: if (e.getErrorCode() == SmbException.ERRbadfile)
> 
> getErrorCode() and ERRbadfile are not defined in SmbException, what to do?
> 
> 
> 
> ---------- Forwarded message ----------
> From: Gary Gregory <ga...@gmail.com>
> Date: Mon, Dec 1, 2014 at 2:52 PM
> Subject: Re: [VFS] VFS sandbox?
> To: Commons Developers List <de...@commons.apache.org>
> 
> 
> Israel,
> 
> 
> The sandbox is not released as a jar for licensing reasons IIRC. You have
> to check it out of SVN and build it yourself.
> 
> Gary
> 
> On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
> wrote:
> 
>> Hello all!
>> I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
>> samba connections.
>> When I try to reach smb server I get FileSystemException - Badly formed
> uri
>> I understand that I have to import the sandbox jar, but do I get it from?
> 
> 
> 
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Fwd: [VFS] VFS sandbox?

Posted by Israel Malachi <is...@ellipsis.co.il>.
Hi all

I was trying to follow Gary's advice (and thank you again, Gary) but I ran
into two issues when trying to build the classes

On SmbFileObject

line 46: extends AbstractFileObject<SmbFileSystem>

AbstractFileObject is not generic, and can't be parameterized, should I
erase <SmbFileSystem> ?

line 227: if (e.getErrorCode() == SmbException.ERRbadfile)

getErrorCode() and ERRbadfile are not defined in SmbException, what to do?



---------- Forwarded message ----------
From: Gary Gregory <ga...@gmail.com>
Date: Mon, Dec 1, 2014 at 2:52 PM
Subject: Re: [VFS] VFS sandbox?
To: Commons Developers List <de...@commons.apache.org>


Israel,


The sandbox is not released as a jar for licensing reasons IIRC. You have
to check it out of SVN and build it yourself.

Gary

On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
wrote:

> Hello all!
> I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> samba connections.
> When I try to reach smb server I get FileSystemException - Badly formed
uri
> I understand that I have to import the sandbox jar, but do I get it from?
>



--
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: [VFS] VFS sandbox?

Posted by Israel Malachi <is...@ellipsis.co.il>.
Gary,

Thank you very much!

On Mon, Dec 1, 2014 at 2:52 PM, Gary Gregory <ga...@gmail.com> wrote:

> Israel,
>
>
> The sandbox is not released as a jar for licensing reasons IIRC. You have
> to check it out of SVN and build it yourself.
>
> Gary
>
> On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
> wrote:
>
> > Hello all!
> > I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> > samba connections.
> > When I try to reach smb server I get FileSystemException - Badly formed
> uri
> > I understand that I have to import the sandbox jar, but do I get it from?
> >
>
>
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory
>

Re: [VFS] VFS sandbox?

Posted by Gary Gregory <ga...@gmail.com>.
Israel,


The sandbox is not released as a jar for licensing reasons IIRC. You have
to check it out of SVN and build it yourself.

Gary

On Mon, Dec 1, 2014 at 2:53 AM, Israel Malachi <is...@ellipsis.co.il>
wrote:

> Hello all!
> I'm writing a program that uses the VFS (2.0) so I could manage SFTP and
> samba connections.
> When I try to reach smb server I get FileSystemException - Badly formed uri
> I understand that I have to import the sandbox jar, but do I get it from?
>



-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory