occi 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/occi/version.rb +1 -1
- metadata +1 -17
- data/lib/occi/backend/dummy.rb +0 -232
- data/lib/occi/backend/ec2/Compute.rb +0 -310
- data/lib/occi/backend/ec2/compute.rb +0 -310
- data/lib/occi/backend/ec2/ec2.rb +0 -215
- data/lib/occi/backend/manager.rb +0 -131
- data/lib/occi/backend/opennebula/compute.rb +0 -360
- data/lib/occi/backend/opennebula/network.rb +0 -143
- data/lib/occi/backend/opennebula/opennebula.rb +0 -188
- data/lib/occi/backend/opennebula/storage.rb +0 -175
- data/lib/occi/extensions/monitoring/cpu.rb +0 -51
- data/lib/occi/extensions/monitoring/memory.rb +0 -49
- data/lib/occi/extensions/monitoring/metric.rb +0 -54
- data/lib/occi/extensions/monitoring/netrx.rb +0 -49
- data/lib/occi/extensions/monitoring/nettx.rb +0 -55
- data/lib/occi/extensions/one/VNC.rb +0 -58
- data/lib/occi/extensions/one/vnc.rb +0 -58
@@ -1,51 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2012 GWDG
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI monitoring VM cpu usage
|
19
|
-
# Author(s): Ali Imran Jehangiri, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'singleton'
|
23
|
-
require 'occi/core/mixin'
|
24
|
-
|
25
|
-
module OCCI
|
26
|
-
module Monitor
|
27
|
-
class Cpu < OCCI::Core::Mixin
|
28
|
-
|
29
|
-
# Define appropriate mixin
|
30
|
-
begin
|
31
|
-
# Define actions
|
32
|
-
actions = []
|
33
|
-
|
34
|
-
related = [OCCI::Monitor::Metric::MIXIN]
|
35
|
-
entities = []
|
36
|
-
|
37
|
-
term = "cpu"
|
38
|
-
scheme = "http://example.com/occi/infrastructure/metric/compute#"
|
39
|
-
title = "compute.cpu"
|
40
|
-
|
41
|
-
attributes = OCCI::Core::Attributes.new()
|
42
|
-
|
43
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
44
|
-
OCCI::CategoryRegistry.register(MIXIN)
|
45
|
-
OCCI::Rendering::HTTP::LocationRegistry.register('/metric/compute/cpu', MIXIN)
|
46
|
-
|
47
|
-
|
48
|
-
end
|
49
|
-
end
|
50
|
-
end
|
51
|
-
end
|
@@ -1,49 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2012 GWDG
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI monitoring VM memory usage
|
19
|
-
# Author(s): Ali Imran Jehangiri, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'singleton'
|
23
|
-
require 'occi/core/mixin'
|
24
|
-
|
25
|
-
module OCCI
|
26
|
-
module Monitor
|
27
|
-
class Memory < OCCI::Core::Mixin
|
28
|
-
|
29
|
-
# Define appropriate mixin
|
30
|
-
begin
|
31
|
-
# Define actions
|
32
|
-
actions = []
|
33
|
-
|
34
|
-
related = [OCCI::Monitor::Metric::MIXIN]
|
35
|
-
entities = []
|
36
|
-
|
37
|
-
term = "memory"
|
38
|
-
scheme = "http://example.com/occi/infrastructure/metric/compute#"
|
39
|
-
title = "compute.memory"
|
40
|
-
|
41
|
-
attributes = OCCI::Core::Attributes.new()
|
42
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
43
|
-
OCCI::CategoryRegistry.register(MIXIN)
|
44
|
-
OCCI::Rendering::HTTP::LocationRegistry.register('/metric/compute/memory', MIXIN)
|
45
|
-
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
49
|
-
end
|
@@ -1,54 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2012 GWDG
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI monitoring metric
|
19
|
-
# Author(s): Ali Imran Jehangiri, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'singleton'
|
23
|
-
|
24
|
-
require 'occi/core/mixin'
|
25
|
-
|
26
|
-
module OCCI
|
27
|
-
module Monitor
|
28
|
-
class Metric < OCCI::Core::Mixin
|
29
|
-
|
30
|
-
# Define appropriate mixin
|
31
|
-
begin
|
32
|
-
# Define actions
|
33
|
-
actions = []
|
34
|
-
|
35
|
-
related = []
|
36
|
-
entities = []
|
37
|
-
|
38
|
-
term = "metric"
|
39
|
-
scheme = "http://schemas.ogf.org/occi/monitoring#"
|
40
|
-
title = "Metric"
|
41
|
-
|
42
|
-
attributes = OCCI::Core::Attributes.new()
|
43
|
-
attributes << OCCI::Core::Attribute.new(name = 'value', mutable = false, mandatory = true, unique = true)
|
44
|
-
attributes << OCCI::Core::Attribute.new(name = 'timestamp', mutable = false, mandatory = true, unique = true)
|
45
|
-
attributes << OCCI::Core::Attribute.new(name = 'samplerate', mutable = true, mandatory = false, unique = true)
|
46
|
-
attributes << OCCI::Core::Attribute.new(name = 'resolution', mutable = true, mandatory = false, unique = true)
|
47
|
-
attributes << OCCI::Core::Attribute.new(name = 'unit', mutable = false, mandatory = true, unique = true)
|
48
|
-
|
49
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
50
|
-
OCCI::CategoryRegistry.register(MIXIN)
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|
@@ -1,49 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2012 GWDG
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI monitoring VM Network reception
|
19
|
-
# Author(s): Ali Imran Jehangiri, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'singleton'
|
23
|
-
require 'occi/core/mixin'
|
24
|
-
|
25
|
-
module OCCI
|
26
|
-
module Monitor
|
27
|
-
class Nettx < OCCI::Core::Mixin
|
28
|
-
|
29
|
-
# Define appropriate mixin
|
30
|
-
begin
|
31
|
-
# Define actions
|
32
|
-
actions = []
|
33
|
-
|
34
|
-
related = [OCCI::Monitor::Metric::MIXIN]
|
35
|
-
entities = []
|
36
|
-
|
37
|
-
term = "net_rx"
|
38
|
-
scheme = "http://example.com/occi/infrastructure/metric/compute#"
|
39
|
-
title = "compute.net_rx"
|
40
|
-
|
41
|
-
attributes = OCCI::Core::Attributes.new()
|
42
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
43
|
-
OCCI::CategoryRegistry.register(MIXIN)
|
44
|
-
OCCI::Rendering::HTTP::LocationRegistry.register('/metric/compute/net_rx', MIXIN)
|
45
|
-
|
46
|
-
end
|
47
|
-
end
|
48
|
-
end
|
49
|
-
end
|
@@ -1,55 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2012 GWDG
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI monitoring VM Network transmission
|
19
|
-
# Author(s): Ali Imran Jehangiri, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'singleton'
|
23
|
-
require 'occi/core/mixin'
|
24
|
-
|
25
|
-
module OCCI
|
26
|
-
module Monitor
|
27
|
-
class Nettx < OCCI::Core::Mixin
|
28
|
-
|
29
|
-
# Define appropriate mixin
|
30
|
-
begin
|
31
|
-
# Define actions
|
32
|
-
actions = []
|
33
|
-
|
34
|
-
related = [OCCI::Monitor::Metric::MIXIN]
|
35
|
-
entities = []
|
36
|
-
|
37
|
-
term = "net_tx"
|
38
|
-
scheme = "http://example.com/occi/infrastructure/metric/compute#"
|
39
|
-
title = "compute.net_tx"
|
40
|
-
|
41
|
-
attributes = OCCI::Core::Attributes.new()
|
42
|
-
# attributes << OCCI::Core::Attribute.new(name = 'compute.net_tx.value', mutable = false, mandatory = true, unique = true)
|
43
|
-
# attributes << OCCI::Core::Attribute.new(name = 'compute.net_tx.timestamp', mutable = false, mandatory = true, unique = true)
|
44
|
-
# attributes << OCCI::Core::Attribute.new(name = 'compute.net_tx.samplerate', mutable = true, mandatory = false, unique = true)
|
45
|
-
# attributes << OCCI::Core::Attribute.new(name = 'compute.net_tx.resolution', mutable = true, mandatory = false, unique = true)
|
46
|
-
# attributes << OCCI::Core::Attribute.new(name = 'compute.net_tx.unit', mutable = false, mandatory = true, unique = true)
|
47
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
48
|
-
|
49
|
-
OCCI::CategoryRegistry.register(MIXIN)
|
50
|
-
OCCI::Rendering::HTTP::LocationRegistry.register('/metric/compute/net_tx', MIXIN)
|
51
|
-
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|
55
|
-
end
|
@@ -1,58 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2011 Service Computing group, TU Dortmund
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI Mixin to support OpenNebula specific virtual machine parameters
|
19
|
-
# Author(s): Hayati Bice, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'occi/core/mixin'
|
23
|
-
require 'occi/core/attribute'
|
24
|
-
require 'occi/core/attributes'
|
25
|
-
require 'singleton'
|
26
|
-
|
27
|
-
module OCCI
|
28
|
-
module Backend
|
29
|
-
module ONE
|
30
|
-
class VNC < OCCI::Core::Mixin
|
31
|
-
|
32
|
-
# Define appropriate mixin
|
33
|
-
begin
|
34
|
-
# Define actions
|
35
|
-
actions = []
|
36
|
-
|
37
|
-
related = []
|
38
|
-
entities = []
|
39
|
-
|
40
|
-
term = "vnc"
|
41
|
-
scheme = "http://schemas.opennebula.org/occi/infrastructure#"
|
42
|
-
title = "OpenNebula VNC Mixin"
|
43
|
-
|
44
|
-
attributes = OCCI::Core::Attributes.new()
|
45
|
-
attributes << OCCI::Core::Attribute.new(name = 'opennebula.vm.vnc', mutable = true, required = false, type = "string", range = "", default = "")
|
46
|
-
attributes << OCCI::Core::Attribute.new(name = 'opennebula.vm.web_vnc', mutable = true, required = false, type = "string", range = "", default = "")
|
47
|
-
|
48
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
49
|
-
end
|
50
|
-
|
51
|
-
def initialize(term, scheme, title, attributes, actions, related, entities)
|
52
|
-
super(term, scheme, title, attributes, actions, related, entities)
|
53
|
-
end
|
54
|
-
|
55
|
-
end
|
56
|
-
end
|
57
|
-
end
|
58
|
-
end
|
@@ -1,58 +0,0 @@
|
|
1
|
-
##############################################################################
|
2
|
-
# Copyright 2011 Service Computing group, TU Dortmund
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
##############################################################################
|
16
|
-
|
17
|
-
##############################################################################
|
18
|
-
# Description: OCCI Mixin to support OpenNebula specific virtual machine parameters
|
19
|
-
# Author(s): Hayati Bice, Florian Feldhaus, Piotr Kasprzak
|
20
|
-
##############################################################################
|
21
|
-
|
22
|
-
require 'occi/core/mixin'
|
23
|
-
require 'occi/core/attribute'
|
24
|
-
require 'occi/core/attributes'
|
25
|
-
require 'singleton'
|
26
|
-
|
27
|
-
module OCCI
|
28
|
-
module Backend
|
29
|
-
module ONE
|
30
|
-
class VNC < OCCI::Core::Mixin
|
31
|
-
|
32
|
-
# Define appropriate mixin
|
33
|
-
begin
|
34
|
-
# Define actions
|
35
|
-
actions = []
|
36
|
-
|
37
|
-
related = []
|
38
|
-
entities = []
|
39
|
-
|
40
|
-
term = "vnc"
|
41
|
-
scheme = "http://schemas.opennebula.org/occi/infrastructure#"
|
42
|
-
title = "OpenNebula VNC Mixin"
|
43
|
-
|
44
|
-
attributes = OCCI::Core::Attributes.new()
|
45
|
-
attributes << OCCI::Core::Attribute.new(name = 'opennebula.vm.vnc', mutable = true, required = false, type = "string", range = "", default = "")
|
46
|
-
attributes << OCCI::Core::Attribute.new(name = 'opennebula.vm.web_vnc', mutable = true, required = false, type = "string", range = "", default = "")
|
47
|
-
|
48
|
-
MIXIN = OCCI::Core::Mixin.new(term, scheme, title, attributes, actions, related, entities)
|
49
|
-
end
|
50
|
-
|
51
|
-
def initialize(term, scheme, title, attributes, actions, related, entities)
|
52
|
-
super(term, scheme, title, attributes, actions, related, entities)
|
53
|
-
end
|
54
|
-
|
55
|
-
end
|
56
|
-
end
|
57
|
-
end
|
58
|
-
end
|