Toggle navigation
Toggle navigation
This project
Loading...
Sign in
홍길동
/
onos
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
weibit
2014-10-23 16:30:03 -0700
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
253c865d79a34ba7f25606f7e10143173a6313db
253c865d
1 parent
41c088a2
some optical intent changes
Change-Id: Ie9b02e2d199aa72f9828e91b248bd052f7b38fa2
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
10 deletions
apps/optical/src/main/java/org/onlab/onos/optical/cfg/OpticalConfigProvider.java
apps/optical/src/main/java/org/onlab/onos/optical/testapp/LambdaForwarding.java
core/net/src/main/java/org/onlab/onos/net/intent/impl/OpticalConnectivityIntentCompiler.java
core/net/src/main/java/org/onlab/onos/net/intent/impl/OpticalPathIntentInstaller.java
apps/optical/src/main/java/org/onlab/onos/optical/cfg/OpticalConfigProvider.java
View file @
253c865
...
...
@@ -93,9 +93,9 @@ public class OpticalConfigProvider extends AbstractProvider implements DevicePro
log
.
info
(
"Starting optical network configuration process..."
);
log
.
info
(
"Optical config file set to {}"
,
configFileName
);
//
loadOpticalConfig();
//
parseOpticalConfig();
//
publishOpticalConfig();
loadOpticalConfig
();
parseOpticalConfig
();
publishOpticalConfig
();
}
@Deactivate
...
...
apps/optical/src/main/java/org/onlab/onos/optical/testapp/LambdaForwarding.java
View file @
253c865
...
...
@@ -29,7 +29,7 @@ import org.slf4j.Logger;
/**
* Sample reactive forwarding application.
*/
//
:
@Component(immediate = true)
//@Component(immediate = true)
public
class
LambdaForwarding
{
private
final
Logger
log
=
getLogger
(
getClass
());
...
...
core/net/src/main/java/org/onlab/onos/net/intent/impl/OpticalConnectivityIntentCompiler.java
View file @
253c865
...
...
@@ -84,8 +84,8 @@ public class OpticalConnectivityIntentCompiler implements IntentCompiler<Optical
// create a new opticalPathIntent
Intent
newIntent
=
new
OpticalPathIntent
(
intent
.
appId
(),
path
.
src
(),
path
.
d
st
(),
intent
.
getSrcConnectPoint
(),
intent
.
getD
st
(),
path
);
retList
.
add
(
newIntent
);
...
...
@@ -100,8 +100,11 @@ public class OpticalConnectivityIntentCompiler implements IntentCompiler<Optical
@Override
public
double
weight
(
TopologyEdge
edge
)
{
boolean
isOptical
=
false
;
String
t
=
edge
.
link
().
annotations
().
value
(
"linkType"
);
if
(
t
.
equals
(
"WDM"
))
{
Link
.
Type
lt
=
edge
.
link
().
type
();
//String t = edge.link().annotations().value("linkType");
if
(
lt
==
Link
.
Type
.
OPTICAL
)
{
isOptical
=
true
;
}
if
(
isOptical
)
{
...
...
core/net/src/main/java/org/onlab/onos/net/intent/impl/OpticalPathIntentInstaller.java
View file @
253c865
...
...
@@ -87,8 +87,6 @@ public class OpticalPathIntentInstaller implements IntentInstaller<OpticalPathIn
TrafficSelector
.
Builder
selectorBuilder
=
DefaultTrafficSelector
.
builder
();
selectorBuilder
.
matchInport
(
intent
.
src
().
port
());
TrafficTreatment
.
Builder
treatmentBuilder
=
DefaultTrafficTreatment
.
builder
();
List
<
FlowRuleBatchEntry
>
rules
=
Lists
.
newLinkedList
();
ConnectPoint
prev
=
intent
.
src
();
...
...
@@ -107,6 +105,7 @@ public class OpticalPathIntentInstaller implements IntentInstaller<OpticalPathIn
return
null
;
}
TrafficTreatment
.
Builder
treatmentBuilder
=
DefaultTrafficTreatment
.
builder
();
treatmentBuilder
.
setOutput
(
link
.
src
().
port
());
treatmentBuilder
.
setLambda
((
short
)
la
.
toInt
());
...
...
Please
register
or
login
to post a comment