Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
cta
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Harbor Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dCache
cta
Commits
01d57023
Commit
01d57023
authored
10 years ago
by
Sebastien Ponce
Browse files
Options
Downloads
Patches
Plain Diff
Implemented a fake librados so that synchronization can compile on SLC5
parent
2bba29a2
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
castor/gc/CephGlobals.cpp
+1
-0
1 addition, 0 deletions
castor/gc/CephGlobals.cpp
fakeradosstriper/rados/librados.hpp
+98
-0
98 additions, 0 deletions
fakeradosstriper/rados/librados.hpp
fakeradosstriper/radosstriper/libradosstriper.hpp
+1
-54
1 addition, 54 deletions
fakeradosstriper/radosstriper/libradosstriper.hpp
with
100 additions
and
54 deletions
castor/gc/CephGlobals.cpp
+
1
−
0
View file @
01d57023
...
...
@@ -24,6 +24,7 @@
*****************************************************************************/
#include
"castor/gc/CephGlobals.hpp"
#include
<map>
/// global variables holding ioCtx and stripers for each ceph pool
std
::
map
<
std
::
string
,
libradosstriper
::
RadosStriper
*>
g_radosStripers
;
...
...
This diff is collapsed.
Click to expand it.
fakeradosstriper/rados/librados.hpp
0 → 100644
+
98
−
0
View file @
01d57023
/******************************************************************************
* This is a fake implementation of librados.hpp API allowing to
* compile CASTOR code without depending on CEPH
* This bad hack should be dropped. It only exists in order to support
* compilation on SLC5, while ceph is not compiling on SLC5.
* Obviously, even if the software will compile with this fake implementation
* the ceph functionnality won't be present when using this.
*****************************************************************************/
#ifndef __LIBRADOS_HPP
#define __LIBRADOS_HPP
#include
<errno.h>
#include
<string>
namespace
ceph
{
class
bufferlist
{
public:
void
append
(
const
char
*
data
,
unsigned
len
)
{};
void
copy
(
unsigned
off
,
unsigned
len
,
char
*
dest
)
const
{};
};
};
namespace
librados
{
class
ObjectIterator
{
public:
ObjectIterator
()
{}
bool
operator
!=
(
const
ObjectIterator
&
rhs
)
const
{
return
false
;
}
const
std
::
pair
<
std
::
string
,
std
::
string
>*
operator
->
()
const
{
return
&
m_null
;
};
ObjectIterator
operator
++
(
int
)
{
return
*
this
;
};
std
::
pair
<
std
::
string
,
std
::
string
>
m_null
;
};
class
IoCtx
{
public:
IoCtx
(){}
ObjectIterator
objects_begin
()
{
return
ObjectIterator
();
}
ObjectIterator
objects_end
()
{
return
ObjectIterator
();
}
};
class
Rados
{
public:
Rados
(){};
int
init
(
const
char
*
const
id
)
{
return
-
EINVAL
;
}
int
conf_read_file
(
const
char
*
const
path
)
{
return
-
EINVAL
;
}
int
conf_parse_env
(
const
char
*
env
)
const
{
return
-
EINVAL
;
}
int
connect
()
{
return
-
EINVAL
;
}
void
shutdown
(){}
int
ioctx_create
(
const
char
*
name
,
IoCtx
&
pioctx
)
{
return
-
EINVAL
;
}
};
};
#endif
This diff is collapsed.
Click to expand it.
fakeradosstriper/radosstriper/libradosstriper.hpp
+
1
−
54
View file @
01d57023
...
...
@@ -12,60 +12,7 @@
#include
<errno.h>
#include
<string>
namespace
ceph
{
class
bufferlist
{
public:
void
append
(
const
char
*
data
,
unsigned
len
)
{};
void
copy
(
unsigned
off
,
unsigned
len
,
char
*
dest
)
const
{};
};
};
namespace
librados
{
class
IoCtx
{
public:
IoCtx
(){}
};
class
Rados
{
public:
Rados
(){};
int
init
(
const
char
*
const
id
)
{
return
-
EINVAL
;
}
int
conf_read_file
(
const
char
*
const
path
)
{
return
-
EINVAL
;
}
int
conf_parse_env
(
const
char
*
env
)
const
{
return
-
EINVAL
;
}
int
connect
()
{
return
-
EINVAL
;
}
void
shutdown
(){}
int
ioctx_create
(
const
char
*
name
,
IoCtx
&
pioctx
)
{
return
-
EINVAL
;
}
};
};
#include
<rados/librados.hpp>
namespace
libradosstriper
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment