Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use "noverify" #1

Open
domlachowicz opened this issue Sep 20, 2010 · 1 comment
Open

use "noverify" #1

domlachowicz opened this issue Sep 20, 2010 · 1 comment

Comments

@domlachowicz
Copy link

The getPaths() calls all pass "noVerify=false", which means "verify that these paths exist". If you use MogileFS with your own WebDAV server, such as Apache2, these calls will fail.

The fix is to use "noVerify=true". Patch forthcoming.

@domlachowicz
Copy link
Author

From e4160bf57c89d381579599ff3add77c1257637d1 Mon Sep 17 00:00:00 2001
From: jeremy <jeremy@jeremy-laptop.(none)>
Date: Mon, 20 Sep 2010 12:40:06 -0400
Subject: [PATCH] set getPaths second argument to "true" and made getPaths a function in MogileOutputStream


java/com/guba/mogilefs/BaseMogileFSImpl.java | 6 +++---
java/com/guba/mogilefs/MogileOutputStream.java | 4 ++++
2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/java/com/guba/mogilefs/BaseMogileFSImpl.java b/java/com/guba/mogilefs/BaseMogileFSImpl.java
index 1b96192..d2ab4f0 100644
--- a/java/com/guba/mogilefs/BaseMogileFSImpl.java
+++ b/java/com/guba/mogilefs/BaseMogileFSImpl.java
@@ -291,7 +291,7 @@ public abstract class BaseMogileFSImpl implements MogileFS {

public byte[] getFileBytes(String key) throws NoTrackersException, TrackerCommunicationException, IOException, StorageCommunicationException {
    // pull in the paths for this file
  •   String paths[] = getPaths(key, false);
    
  •   String paths[] = getPaths(key, true);
    
    // does this exist?
    if (paths == null) {
    

    @@ -352,7 +352,7 @@ public abstract class BaseMogileFSImpl implements MogileFS {
    */
    public InputStream getFileStream(String key) throws NoTrackersException, TrackerCommunicationException, StorageCommunicationException {
    // pull in the paths for this file

  •   String paths[] = getPaths(key, false);
    
  •   String paths[] = getPaths(key, true);
    
    // does this exist?
    if (paths == null)
    

    @@ -610,4 +610,4 @@ public abstract class BaseMogileFSImpl implements MogileFS {

-}
\ No newline at end of file
+}
diff --git a/java/com/guba/mogilefs/MogileOutputStream.java b/java/com/guba/mogilefs/MogileOutputStream.java
index 81f9a8c..bf3de90 100644
--- a/java/com/guba/mogilefs/MogileOutputStream.java
+++ b/java/com/guba/mogilefs/MogileOutputStream.java
@@ -63,6 +63,10 @@ public class MogileOutputStream extends OutputStream {
private BufferedReader reader;

 private int count;
  • public String getPath() {
  • return path;
  • }

public MogileOutputStream(ObjectPool backendPool, String domain, String fid,

String path, String devid, String key,

1.7.0.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant