Skip to content

Commit 2d2ce13

Browse files
authored
[rust] Add Copyright header on all rust files (#2114)
1 parent 4f7e983 commit 2d2ce13

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+1016
-94
lines changed

rust/crates/dummy-cuebot/src/main.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::{collections::HashMap, str::FromStr};
214

315
use miette::Result;

rust/crates/dummy-cuebot/src/report_servant.rs

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,26 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::net::{Ipv4Addr, SocketAddr};
214

315
use miette::IntoDiagnostic;
416
use opencue_proto::report::rqd_report_interface_server::RqdReportInterfaceServer;
517
use opencue_proto::report::{
6-
RqdReportRqdStartupRequest, RqdReportRqdStartupResponse,
7-
RqdReportRunningFrameCompletionRequest, RqdReportRunningFrameCompletionResponse,
8-
RqdReportStatusRequest, RqdReportStatusResponse,
9-
rqd_report_interface_server::RqdReportInterface,
18+
rqd_report_interface_server::RqdReportInterface, RqdReportRqdStartupRequest,
19+
RqdReportRqdStartupResponse, RqdReportRunningFrameCompletionRequest,
20+
RqdReportRunningFrameCompletionResponse, RqdReportStatusRequest, RqdReportStatusResponse,
1021
};
1122
use tonic::transport::Server;
12-
use tonic::{Request, Response, Status, async_trait};
23+
use tonic::{async_trait, Request, Response, Status};
1324

1425
pub struct ReportServant {}
1526
#[async_trait]

rust/crates/dummy-cuebot/src/rqd_client.rs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,20 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::{collections::HashMap, sync::Arc};
214

315
use miette::{Context, IntoDiagnostic, Result};
416
use opencue_proto::rqd::{
5-
self as pb, RunFrame, rqd_interface_client::RqdInterfaceClient, run_frame::UidOptional,
17+
self as pb, rqd_interface_client::RqdInterfaceClient, run_frame::UidOptional, RunFrame,
618
};
719
use tokio::sync::Mutex;
820
use tonic::transport::Channel;

rust/crates/opencue-proto/build.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::path::PathBuf;
214

315
fn main() -> Result<(), Box<dyn std::error::Error>> {

rust/crates/opencue-proto/src/lib.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use core::fmt;
214

315
use host::Host;

rust/crates/rqd/src/config/error.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use miette::Diagnostic;
214
use thiserror::Error;
315
use tonic::Status;

rust/crates/rqd/src/config/mod.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
pub mod error;
214

315
use crate::config::error::RqdConfigError;

rust/crates/rqd/src/frame/cache.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::sync::Arc;
214

315
use dashmap::DashMap;

rust/crates/rqd/src/frame/docker_running_frame.rs

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,18 @@
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
113
use std::{cmp, sync::Arc};
214

315
use bollard::{
4-
Docker,
516
container::{
617
self, AttachContainerOptions, AttachContainerResults, CreateContainerOptions,
718
StartContainerOptions, WaitContainerOptions,
@@ -10,6 +21,7 @@ use bollard::{
1021
ContainerWaitResponse, DeviceMapping, HostConfig, Mount, MountBindOptions,
1122
MountBindOptionsPropagationEnum, MountTypeEnum,
1223
},
24+
Docker,
1325
};
1426
use futures::StreamExt;
1527
use itertools::Either;
@@ -19,7 +31,7 @@ use tracing::{error, info, trace, warn};
1931
use crate::frame::frame_cmd::FrameCmdBuilder;
2032
use crate::frame::running_frame::RunningFrame;
2133

22-
use miette::{Context, IntoDiagnostic, Result, miette};
34+
use miette::{miette, Context, IntoDiagnostic, Result};
2335

2436
use super::logging::{FrameLogger, FrameLoggerBuilder};
2537

rust/crates/rqd/src/frame/frame_cmd.rs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,16 @@
1-
use miette::{IntoDiagnostic, Result, miette};
1+
// Copyright Contributors to the OpenCue Project
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
4+
// in compliance with the License. You may obtain a copy of the License at
5+
//
6+
// http://www.apache.org/licenses/LICENSE-2.0
7+
//
8+
// Unless required by applicable law or agreed to in writing, software distributed under the License
9+
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
10+
// or implied. See the License for the specific language governing permissions and limitations under
11+
// the License.
12+
13+
use miette::{miette, IntoDiagnostic, Result};
214
use std::fmt::Display;
315
use std::io::Write;
416
use std::{fs, fs::File};

0 commit comments

Comments
 (0)