Add misc typo fixes (#3006)
<!-- PR description--> --- #### Does this PR need a docs update or release note? - [ ] ⛔ No #### Type of change <!--- Please check the type of change your PR introduces: ---> - [ ] 🧹 Tech Debt/Cleanup #### Issue(s) <!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. --> * #<issue> #### Test Plan <!-- How will this be tested prior to merging.--> - [ ] 💪 Manual
This commit is contained in:
parent
6ca5ff1df2
commit
ec064e539b
@ -12,7 +12,7 @@ Manages compilation and validation of repository configuration and consts. Both
|
|||||||
-----
|
-----
|
||||||
|
|
||||||
## /cli
|
## /cli
|
||||||
Command Line Interface controller. Utilizes /pkg/repository as an exernal dependency.
|
Command Line Interface controller. Utilizes /pkg/repository as an external dependency.
|
||||||
|
|
||||||
-----
|
-----
|
||||||
|
|
||||||
|
|||||||
@ -41,7 +41,7 @@ func (suite *ExchangeUnitSuite) TestAddExchangeCommands() {
|
|||||||
|
|
||||||
cmd := &cobra.Command{Use: test.use}
|
cmd := &cobra.Command{Use: test.use}
|
||||||
|
|
||||||
// normally a persisten flag from the root.
|
// normally a persistent flag from the root.
|
||||||
// required to ensure a dry run.
|
// required to ensure a dry run.
|
||||||
utils.AddRunModeFlag(cmd, true)
|
utils.AddRunModeFlag(cmd, true)
|
||||||
|
|
||||||
|
|||||||
@ -41,7 +41,7 @@ func (suite *OneDriveUnitSuite) TestAddOneDriveCommands() {
|
|||||||
|
|
||||||
cmd := &cobra.Command{Use: test.use}
|
cmd := &cobra.Command{Use: test.use}
|
||||||
|
|
||||||
// normally a persisten flag from the root.
|
// normally a persistent flag from the root.
|
||||||
// required to ensure a dry run.
|
// required to ensure a dry run.
|
||||||
utils.AddRunModeFlag(cmd, true)
|
utils.AddRunModeFlag(cmd, true)
|
||||||
|
|
||||||
|
|||||||
@ -41,7 +41,7 @@ func (suite *SharePointUnitSuite) TestAddSharePointCommands() {
|
|||||||
|
|
||||||
cmd := &cobra.Command{Use: test.use}
|
cmd := &cobra.Command{Use: test.use}
|
||||||
|
|
||||||
// normally a persisten flag from the root.
|
// normally a persistent flag from the root.
|
||||||
// required to ensure a dry run.
|
// required to ensure a dry run.
|
||||||
utils.AddRunModeFlag(cmd, true)
|
utils.AddRunModeFlag(cmd, true)
|
||||||
|
|
||||||
|
|||||||
@ -59,7 +59,7 @@ const (
|
|||||||
FileModifiedBeforeFN = "file-modified-before"
|
FileModifiedBeforeFN = "file-modified-before"
|
||||||
)
|
)
|
||||||
|
|
||||||
// well-knwon flag values
|
// well-known flag values
|
||||||
const (
|
const (
|
||||||
RunModeFlagTest = "flag-test"
|
RunModeFlagTest = "flag-test"
|
||||||
RunModeRun = "run"
|
RunModeRun = "run"
|
||||||
|
|||||||
2
src/cli/utils/testdata/flags.go
vendored
2
src/cli/utils/testdata/flags.go
vendored
@ -20,7 +20,7 @@ var (
|
|||||||
EmailReceivedAfterInput = "mailReceivedAfter"
|
EmailReceivedAfterInput = "mailReceivedAfter"
|
||||||
EmailReceivedBeforeInput = "mailReceivedBefore"
|
EmailReceivedBeforeInput = "mailReceivedBefore"
|
||||||
EmailSenderInput = "mailSender"
|
EmailSenderInput = "mailSender"
|
||||||
EmailSubjectInput = "mailSubjet"
|
EmailSubjectInput = "mailSubject"
|
||||||
|
|
||||||
EventInput = []string{"event1", "event2"}
|
EventInput = []string{"event1", "event2"}
|
||||||
EventCalInput = []string{"eventCal1", "eventCal2"}
|
EventCalInput = []string{"eventCal1", "eventCal2"}
|
||||||
|
|||||||
@ -56,7 +56,7 @@ func HasNoFlagsAndShownHelp(cmd *cobra.Command) bool {
|
|||||||
|
|
||||||
type cmdCfg struct {
|
type cmdCfg struct {
|
||||||
hidden bool
|
hidden bool
|
||||||
preRelese bool
|
preRelease bool
|
||||||
}
|
}
|
||||||
|
|
||||||
type cmdOpt func(*cmdCfg)
|
type cmdOpt func(*cmdCfg)
|
||||||
@ -76,7 +76,7 @@ func HideCommand() cmdOpt {
|
|||||||
func MarkPreReleaseCommand() cmdOpt {
|
func MarkPreReleaseCommand() cmdOpt {
|
||||||
return func(cc *cmdCfg) {
|
return func(cc *cmdCfg) {
|
||||||
cc.hidden = true
|
cc.hidden = true
|
||||||
cc.preRelese = true
|
cc.preRelease = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -89,7 +89,7 @@ func AddCommand(parent, c *cobra.Command, opts ...cmdOpt) (*cobra.Command, *pfla
|
|||||||
parent.AddCommand(c)
|
parent.AddCommand(c)
|
||||||
c.Hidden = cc.hidden
|
c.Hidden = cc.hidden
|
||||||
|
|
||||||
if cc.preRelese {
|
if cc.preRelease {
|
||||||
// There is a default deprecated message that always shows so we do some terminal magic to overwrite it
|
// There is a default deprecated message that always shows so we do some terminal magic to overwrite it
|
||||||
c.Deprecated = "\n\033[1F\033[K" +
|
c.Deprecated = "\n\033[1F\033[K" +
|
||||||
"==================================================================================================\n" +
|
"==================================================================================================\n" +
|
||||||
|
|||||||
@ -61,16 +61,16 @@ func main() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func handleFactoryRoot(cmd *cobra.Command, args []string) error {
|
func handleFactoryRoot(cmd *cobra.Command, args []string) error {
|
||||||
Err(cmd.Context(), impl.ErrNotYetImplemeted)
|
Err(cmd.Context(), impl.ErrNotYetImplemented)
|
||||||
return cmd.Help()
|
return cmd.Help()
|
||||||
}
|
}
|
||||||
|
|
||||||
func handleExchangeFactory(cmd *cobra.Command, args []string) error {
|
func handleExchangeFactory(cmd *cobra.Command, args []string) error {
|
||||||
Err(cmd.Context(), impl.ErrNotYetImplemeted)
|
Err(cmd.Context(), impl.ErrNotYetImplemented)
|
||||||
return cmd.Help()
|
return cmd.Help()
|
||||||
}
|
}
|
||||||
|
|
||||||
func handleOneDriveFactory(cmd *cobra.Command, args []string) error {
|
func handleOneDriveFactory(cmd *cobra.Command, args []string) error {
|
||||||
Err(cmd.Context(), impl.ErrNotYetImplemeted)
|
Err(cmd.Context(), impl.ErrNotYetImplemented)
|
||||||
return cmd.Help()
|
return cmd.Help()
|
||||||
}
|
}
|
||||||
|
|||||||
@ -35,7 +35,7 @@ var (
|
|||||||
|
|
||||||
// TODO: ErrGenerating = clues.New("not all items were successfully generated")
|
// TODO: ErrGenerating = clues.New("not all items were successfully generated")
|
||||||
|
|
||||||
var ErrNotYetImplemeted = clues.New("not yet implemented")
|
var ErrNotYetImplemented = clues.New("not yet implemented")
|
||||||
|
|
||||||
// ------------------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------------------
|
||||||
// Restoration
|
// Restoration
|
||||||
|
|||||||
@ -18,7 +18,7 @@ func AddOneDriveCommands(cmd *cobra.Command) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func handleOneDriveFileFactory(cmd *cobra.Command, args []string) error {
|
func handleOneDriveFileFactory(cmd *cobra.Command, args []string) error {
|
||||||
Err(cmd.Context(), ErrNotYetImplemeted)
|
Err(cmd.Context(), ErrNotYetImplemented)
|
||||||
|
|
||||||
if utils.HasNoFlagsAndShownHelp(cmd) {
|
if utils.HasNoFlagsAndShownHelp(cmd) {
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
@ -152,9 +152,9 @@ else {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#extract the suffix after the domain
|
#extract the suffix after the domain
|
||||||
$siteSiffix = ""
|
$siteSuffix = ""
|
||||||
if ($siteUrl -imatch "^.*?(?<=sharepoint.com)(.*?$)") {
|
if ($siteUrl -imatch "^.*?(?<=sharepoint.com)(.*?$)") {
|
||||||
$siteSiffix = $Matches.1
|
$siteSuffix = $Matches.1
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Write-Host "Site url appears to be malformed"
|
Write-Host "Site url appears to be malformed"
|
||||||
@ -174,5 +174,5 @@ $LibraryNameList = $LibraryNameList | ForEach-Object { @($_.Split(',').Trim()) }
|
|||||||
$FolderPrefixPurgeList = $FolderPrefixPurgeList | ForEach-Object { @($_.Split(',').Trim()) }
|
$FolderPrefixPurgeList = $FolderPrefixPurgeList | ForEach-Object { @($_.Split(',').Trim()) }
|
||||||
|
|
||||||
foreach ($library in $LibraryNameList) {
|
foreach ($library in $LibraryNameList) {
|
||||||
Purge-Library -LibraryName $library -PurgeBeforeTimestamp $PurgeBeforeTimestamp -FolderPrefixPurgeList $FolderPrefixPurgeList -SiteSuffix $siteSiffix
|
Purge-Library -LibraryName $library -PurgeBeforeTimestamp $PurgeBeforeTimestamp -FolderPrefixPurgeList $FolderPrefixPurgeList -SiteSuffix $siteSuffix
|
||||||
}
|
}
|
||||||
@ -20,7 +20,7 @@ func TestPointerSuite(t *testing.T) {
|
|||||||
suite.Run(t, s)
|
suite.Run(t, s)
|
||||||
}
|
}
|
||||||
|
|
||||||
// TestVal checks to ptr derefencing for the
|
// TestVal checks to ptr dereferencing for the
|
||||||
// following types:
|
// following types:
|
||||||
// - *string
|
// - *string
|
||||||
// - *bool
|
// - *bool
|
||||||
|
|||||||
@ -37,7 +37,7 @@ func (s BetaService) Serialize(object serialization.Parsable) ([]byte, error) {
|
|||||||
|
|
||||||
err = writer.WriteObjectValue("", object)
|
err = writer.WriteObjectValue("", object)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, clues.Wrap(err, "writeObjecValue serialization")
|
return nil, clues.Wrap(err, "writeObjectValue serialization")
|
||||||
}
|
}
|
||||||
|
|
||||||
return writer.GetSerializedContent()
|
return writer.GetSerializedContent()
|
||||||
|
|||||||
@ -19,7 +19,7 @@ import (
|
|||||||
|
|
||||||
// DeltaUpdate holds the results of a current delta token. It normally
|
// DeltaUpdate holds the results of a current delta token. It normally
|
||||||
// gets produced when aggregating the addition and removal of items in
|
// gets produced when aggregating the addition and removal of items in
|
||||||
// a delta-queriable folder.
|
// a delta-queryable folder.
|
||||||
type DeltaUpdate struct {
|
type DeltaUpdate struct {
|
||||||
// the deltaLink itself
|
// the deltaLink itself
|
||||||
URL string
|
URL string
|
||||||
|
|||||||
@ -94,7 +94,7 @@ func getItemsAddedAndRemovedFromContainer(
|
|||||||
|
|
||||||
// iterate through the items in the page
|
// iterate through the items in the page
|
||||||
for _, item := range items {
|
for _, item := range items {
|
||||||
// if the additional data conains a `@removed` key, the value will either
|
// if the additional data contains a `@removed` key, the value will either
|
||||||
// be 'changed' or 'deleted'. We don't really care about the cause: both
|
// be 'changed' or 'deleted'. We don't really care about the cause: both
|
||||||
// cases are handled the same way in storage.
|
// cases are handled the same way in storage.
|
||||||
if item.GetAdditionalData()[graph.AddtlDataRemoved] == nil {
|
if item.GetAdditionalData()[graph.AddtlDataRemoved] == nil {
|
||||||
|
|||||||
@ -9,7 +9,7 @@ import (
|
|||||||
"github.com/alcionai/corso/src/internal/connector/graph"
|
"github.com/alcionai/corso/src/internal/connector/graph"
|
||||||
)
|
)
|
||||||
|
|
||||||
// attachementUploadable represents structs that are able to upload small attachments directly to an item or use an
|
// attachmentUploadable represents structs that are able to upload small attachments directly to an item or use an
|
||||||
// upload session to connect large attachments to their corresponding M365 item.
|
// upload session to connect large attachments to their corresponding M365 item.
|
||||||
type attachmentUploadable interface {
|
type attachmentUploadable interface {
|
||||||
uploadSmallAttachment(ctx context.Context, attachment models.Attachmentable) error
|
uploadSmallAttachment(ctx context.Context, attachment models.Attachmentable) error
|
||||||
|
|||||||
@ -203,7 +203,7 @@ func (col *Collection) streamItems(ctx context.Context, errs *fault.Bus) {
|
|||||||
"fetch parallelism value not set or out of bounds, using default",
|
"fetch parallelism value not set or out of bounds, using default",
|
||||||
"default_parallelism",
|
"default_parallelism",
|
||||||
urlPrefetchChannelBufferSize,
|
urlPrefetchChannelBufferSize,
|
||||||
"requested_paralellism",
|
"requested_parallellism",
|
||||||
col.ctrl.ItemFetchParallelism,
|
col.ctrl.ItemFetchParallelism,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -10,7 +10,7 @@ type HorizontalSection struct {
|
|||||||
msmodel.Entity
|
msmodel.Entity
|
||||||
// The set of vertical columns in this section.
|
// The set of vertical columns in this section.
|
||||||
columns []HorizontalSectionColumnable
|
columns []HorizontalSectionColumnable
|
||||||
// Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
emphasis *SectionEmphasisType
|
emphasis *SectionEmphasisType
|
||||||
// Layout type of the section. The possible values are: none, oneColumn, twoColumns, threeColumns, oneThirdLeftColumn, oneThirdRightColumn, fullWidth, unknownFutureValue.
|
// Layout type of the section. The possible values are: none, oneColumn, twoColumns, threeColumns, oneThirdLeftColumn, oneThirdRightColumn, fullWidth, unknownFutureValue.
|
||||||
layout *HorizontalSectionLayoutType
|
layout *HorizontalSectionLayoutType
|
||||||
@ -34,7 +34,7 @@ func (m *HorizontalSection) GetColumns() []HorizontalSectionColumnable {
|
|||||||
return m.columns
|
return m.columns
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetEmphasis gets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// GetEmphasis gets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
func (m *HorizontalSection) GetEmphasis() *SectionEmphasisType {
|
func (m *HorizontalSection) GetEmphasis() *SectionEmphasisType {
|
||||||
return m.emphasis
|
return m.emphasis
|
||||||
}
|
}
|
||||||
@ -122,7 +122,7 @@ func (m *HorizontalSection) SetColumns(value []HorizontalSectionColumnable) {
|
|||||||
m.columns = value
|
m.columns = value
|
||||||
}
|
}
|
||||||
|
|
||||||
// SetEmphasis sets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// SetEmphasis sets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
func (m *HorizontalSection) SetEmphasis(value *SectionEmphasisType) {
|
func (m *HorizontalSection) SetEmphasis(value *SectionEmphasisType) {
|
||||||
m.emphasis = value
|
m.emphasis = value
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,7 +8,7 @@ import (
|
|||||||
// VerticalSection
|
// VerticalSection
|
||||||
type VerticalSection struct {
|
type VerticalSection struct {
|
||||||
msmodel.Entity
|
msmodel.Entity
|
||||||
// Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
emphasis *SectionEmphasisType
|
emphasis *SectionEmphasisType
|
||||||
// The set of web parts in this section.
|
// The set of web parts in this section.
|
||||||
webparts []WebPartable
|
webparts []WebPartable
|
||||||
@ -27,7 +27,7 @@ func CreateVerticalSectionFromDiscriminatorValue(parseNode i878a80d2330e89d26896
|
|||||||
return NewVerticalSection(), nil
|
return NewVerticalSection(), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetEmphasis gets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// GetEmphasis gets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
func (m *VerticalSection) GetEmphasis() *SectionEmphasisType {
|
func (m *VerticalSection) GetEmphasis() *SectionEmphasisType {
|
||||||
return m.emphasis
|
return m.emphasis
|
||||||
}
|
}
|
||||||
@ -93,7 +93,7 @@ func (m *VerticalSection) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// SetEmphasis sets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, netural, soft, strong, unknownFutureValue.
|
// SetEmphasis sets the emphasis property value. Enumeration value that indicates the emphasis of the section background. The possible values are: none, neutral, soft, strong, unknownFutureValue.
|
||||||
func (m *VerticalSection) SetEmphasis(value *SectionEmphasisType) {
|
func (m *VerticalSection) SetEmphasis(value *SectionEmphasisType) {
|
||||||
m.emphasis = value
|
m.emphasis = value
|
||||||
}
|
}
|
||||||
|
|||||||
@ -66,12 +66,12 @@ type ContainerResolver interface {
|
|||||||
// conclude its search. Default input is "".
|
// conclude its search. Default input is "".
|
||||||
Populate(ctx context.Context, errs *fault.Bus, baseFolderID string, baseContainerPather ...string) error
|
Populate(ctx context.Context, errs *fault.Bus, baseFolderID string, baseContainerPather ...string) error
|
||||||
|
|
||||||
// PathInCache performs a look up of a path reprensentation
|
// PathInCache performs a look up of a path representation
|
||||||
// and returns the m365ID of directory iff the pathString
|
// and returns the m365ID of directory iff the pathString
|
||||||
// matches the path of a container within the cache.
|
// matches the path of a container within the cache.
|
||||||
// @returns bool represents if m365ID was found.
|
// @returns bool represents if m365ID was found.
|
||||||
PathInCache(pathString string) (string, bool)
|
PathInCache(pathString string) (string, bool)
|
||||||
// LocationInCache performs a look up of a path reprensentation
|
// LocationInCache performs a look up of a path representation
|
||||||
// and returns the m365ID of directory iff the pathString
|
// and returns the m365ID of directory iff the pathString
|
||||||
// matches the logical path of a container within the cache.
|
// matches the logical path of a container within the cache.
|
||||||
// @returns bool represents if m365ID was found.
|
// @returns bool represents if m365ID was found.
|
||||||
|
|||||||
@ -28,7 +28,7 @@ type MetadataCollection struct {
|
|||||||
statusUpdater support.StatusUpdater
|
statusUpdater support.StatusUpdater
|
||||||
}
|
}
|
||||||
|
|
||||||
// MetadataCollecionEntry describes a file that should get added to a metadata
|
// MetadataCollectionEntry describes a file that should get added to a metadata
|
||||||
// collection. The Data value will be encoded into json as part of a
|
// collection. The Data value will be encoded into json as part of a
|
||||||
// transformation into a MetadataItem.
|
// transformation into a MetadataItem.
|
||||||
type MetadataCollectionEntry struct {
|
type MetadataCollectionEntry struct {
|
||||||
|
|||||||
@ -157,7 +157,7 @@ func (gc *GraphConnector) UpdateStatus(status *support.ConnectorOperationStatus)
|
|||||||
gc.status = support.MergeStatus(gc.status, *status)
|
gc.status = support.MergeStatus(gc.status, *status)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Status returns the current status of the graphConnector operaion.
|
// Status returns the current status of the graphConnector operation.
|
||||||
func (gc *GraphConnector) Status() support.ConnectorOperationStatus {
|
func (gc *GraphConnector) Status() support.ConnectorOperationStatus {
|
||||||
return gc.status
|
return gc.status
|
||||||
}
|
}
|
||||||
|
|||||||
@ -167,7 +167,7 @@ func GetMockMessageWith(
|
|||||||
// Serialized with: kiota-serialization-json-go v0.7.1
|
// Serialized with: kiota-serialization-json-go v0.7.1
|
||||||
func GetMockMessageWithSizedAttachment(subject string, n int) []byte {
|
func GetMockMessageWithSizedAttachment(subject string, n int) []byte {
|
||||||
// I know we said 35, but after base64encoding, 24mb of base content
|
// I know we said 35, but after base64encoding, 24mb of base content
|
||||||
// bloats up to 34mb (35 baloons to 49). So we have to restrict n
|
// bloats up to 34mb (35 balloons to 49). So we have to restrict n
|
||||||
// appropriately.
|
// appropriately.
|
||||||
if n > 24 {
|
if n > 24 {
|
||||||
n = 24
|
n = 24
|
||||||
|
|||||||
@ -1785,7 +1785,7 @@ func (suite *OneDriveCollectionsUnitSuite) TestGet() {
|
|||||||
doNotMergeItems: false,
|
doNotMergeItems: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "OneDrive_OneItemPage_InvalidPrevDelta_DeleteNonExistantFolder",
|
name: "OneDrive_OneItemPage_InvalidPrevDelta_DeleteNonExistentFolder",
|
||||||
drives: []models.Driveable{drive1},
|
drives: []models.Driveable{drive1},
|
||||||
items: map[string][]deltaPagerResult{
|
items: map[string][]deltaPagerResult{
|
||||||
driveID1: {
|
driveID1: {
|
||||||
|
|||||||
@ -33,7 +33,7 @@ const (
|
|||||||
|
|
||||||
// DeltaUpdate holds the results of a current delta token. It normally
|
// DeltaUpdate holds the results of a current delta token. It normally
|
||||||
// gets produced when aggregating the addition and removal of items in
|
// gets produced when aggregating the addition and removal of items in
|
||||||
// a delta-queriable folder.
|
// a delta-queryable folder.
|
||||||
// FIXME: This is same as exchange.api.DeltaUpdate
|
// FIXME: This is same as exchange.api.DeltaUpdate
|
||||||
type DeltaUpdate struct {
|
type DeltaUpdate struct {
|
||||||
// the deltaLink itself
|
// the deltaLink itself
|
||||||
|
|||||||
@ -117,8 +117,8 @@ func RestoreCollections(
|
|||||||
return status, err
|
return status, err
|
||||||
}
|
}
|
||||||
|
|
||||||
// createRestoreFolders creates the restore folder hieararchy in the specified drive and returns the folder ID
|
// createRestoreFolders creates the restore folder hierarchy in the specified drive and returns the folder ID
|
||||||
// of the last folder entry given in the hiearchy
|
// of the last folder entry given in the hierarchy
|
||||||
func createRestoreFolders(
|
func createRestoreFolders(
|
||||||
ctx context.Context,
|
ctx context.Context,
|
||||||
service graph.Servicer,
|
service graph.Servicer,
|
||||||
|
|||||||
@ -65,7 +65,7 @@ func ToMessage(orig models.Messageable) models.Messageable {
|
|||||||
return aMessage
|
return aMessage
|
||||||
}
|
}
|
||||||
|
|
||||||
// ToEventSimplified transforms an event to simplifed restore format
|
// ToEventSimplified transforms an event to simplified restore format
|
||||||
// To overcome some of the MS Graph API challenges, the event object is modified in the following ways:
|
// To overcome some of the MS Graph API challenges, the event object is modified in the following ways:
|
||||||
// - Instead of adding attendees and generating spurious notifications,
|
// - Instead of adding attendees and generating spurious notifications,
|
||||||
// add a summary of attendees at the beginning to the event before the original body content
|
// add a summary of attendees at the beginning to the event before the original body content
|
||||||
|
|||||||
@ -36,7 +36,7 @@ func (suite *UploadSessionSuite) TestWriter() {
|
|||||||
contentRangeRegex := regexp.MustCompile(`^bytes (?P<rangestart>\d+)-(?P<rangeend>\d+)/(?P<length>\d+)$`)
|
contentRangeRegex := regexp.MustCompile(`^bytes (?P<rangestart>\d+)-(?P<rangeend>\d+)/(?P<length>\d+)$`)
|
||||||
nextOffset := -1
|
nextOffset := -1
|
||||||
|
|
||||||
// Initialize a test http server that validates expeected headers
|
// Initialize a test http server that validates expected headers
|
||||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||||
assert.Equal(t, r.Method, http.MethodPut)
|
assert.Equal(t, r.Method, http.MethodPut)
|
||||||
|
|
||||||
|
|||||||
@ -87,7 +87,7 @@ func (w *conn) Initialize(ctx context.Context) error {
|
|||||||
return clues.Stack(ErrorRepoAlreadyExists, err).WithClues(ctx)
|
return clues.Stack(ErrorRepoAlreadyExists, err).WithClues(ctx)
|
||||||
}
|
}
|
||||||
|
|
||||||
return clues.Wrap(err, "initialzing repo").WithClues(ctx)
|
return clues.Wrap(err, "initializing repo").WithClues(ctx)
|
||||||
}
|
}
|
||||||
|
|
||||||
err = w.commonConnect(
|
err = w.commonConnect(
|
||||||
|
|||||||
@ -497,7 +497,7 @@ func (ms *ModelStore) Delete(ctx context.Context, s model.Schema, id model.Stabl
|
|||||||
return ms.DeleteWithModelStoreID(ctx, latest)
|
return ms.DeleteWithModelStoreID(ctx, latest)
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeletWithModelStoreID deletes the model with the given ModelStoreID from the
|
// DeleteWithModelStoreID deletes the model with the given ModelStoreID from the
|
||||||
// model store. Turns into a noop if id is not empty but the model does not
|
// model store. Turns into a noop if id is not empty but the model does not
|
||||||
// exist.
|
// exist.
|
||||||
func (ms *ModelStore) DeleteWithModelStoreID(ctx context.Context, id manifest.ID) error {
|
func (ms *ModelStore) DeleteWithModelStoreID(ctx context.Context, id manifest.ID) error {
|
||||||
|
|||||||
@ -286,7 +286,7 @@ func (suite *ModelStoreIntegrationSuite) TestPutGet_PreSetID() {
|
|||||||
expect assert.ComparisonAssertionFunc
|
expect assert.ComparisonAssertionFunc
|
||||||
}{
|
}{
|
||||||
{
|
{
|
||||||
name: "genreate new id",
|
name: "generate new id",
|
||||||
baseID: "",
|
baseID: "",
|
||||||
expect: assert.NotEqual,
|
expect: assert.NotEqual,
|
||||||
},
|
},
|
||||||
|
|||||||
@ -784,7 +784,7 @@ func (suite *SnapshotFetchUnitSuite) TestFetchPrevSnapshots() {
|
|||||||
|
|
||||||
assert.ElementsMatch(t, expected, got)
|
assert.ElementsMatch(t, expected, got)
|
||||||
|
|
||||||
// Check the resons for selecting each manifest are correct.
|
// Check the reasons for selecting each manifest are correct.
|
||||||
expectedReasons := make(map[manifest.ID][]Reason, len(test.expectedReasons))
|
expectedReasons := make(map[manifest.ID][]Reason, len(test.expectedReasons))
|
||||||
for idx, reason := range test.expectedReasons {
|
for idx, reason := range test.expectedReasons {
|
||||||
expectedReasons[test.data[idx].man.ID] = reason
|
expectedReasons[test.data[idx].man.ID] = reason
|
||||||
|
|||||||
@ -20,7 +20,7 @@ type Streamer struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (ms Streamer) Collect(context.Context, streamstore.Collectable) error {
|
func (ms Streamer) Collect(context.Context, streamstore.Collectable) error {
|
||||||
return clues.New("not implented")
|
return clues.New("not implemented")
|
||||||
}
|
}
|
||||||
|
|
||||||
func (ms Streamer) Read(
|
func (ms Streamer) Read(
|
||||||
@ -58,9 +58,9 @@ func (ms Streamer) Read(
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (ms Streamer) Write(context.Context, *fault.Bus) (string, error) {
|
func (ms Streamer) Write(context.Context, *fault.Bus) (string, error) {
|
||||||
return "", clues.New("not implented")
|
return "", clues.New("not implemented")
|
||||||
}
|
}
|
||||||
|
|
||||||
func (ms Streamer) Delete(context.Context, string) error {
|
func (ms Streamer) Delete(context.Context, string) error {
|
||||||
return clues.New("not implented")
|
return clues.New("not implemented")
|
||||||
}
|
}
|
||||||
|
|||||||
@ -98,7 +98,7 @@ func LoadTestM365UserID(t *testing.T) string {
|
|||||||
|
|
||||||
// expects cfg value to be a string representing an array such as:
|
// expects cfg value to be a string representing an array such as:
|
||||||
// ["site1\,uuid","site2\,uuid"]
|
// ["site1\,uuid","site2\,uuid"]
|
||||||
// the delimeter must be a |.
|
// the delimiter must be a |.
|
||||||
func LoadTestM365OrgSites(t *testing.T) []string {
|
func LoadTestM365OrgSites(t *testing.T) []string {
|
||||||
cfg, err := readTestConfig()
|
cfg, err := readTestConfig()
|
||||||
require.NoError(t, err, "retrieving load test m365 org sites from test configuration", clues.ToCore(err))
|
require.NoError(t, err, "retrieving load test m365 org sites from test configuration", clues.ToCore(err))
|
||||||
@ -118,7 +118,7 @@ func LoadTestM365OrgSites(t *testing.T) []string {
|
|||||||
|
|
||||||
// expects cfg value to be a string representing an array such as:
|
// expects cfg value to be a string representing an array such as:
|
||||||
// ["foo@example.com","bar@example.com"]
|
// ["foo@example.com","bar@example.com"]
|
||||||
// the delimeter may be either a , or |.
|
// the delimiter may be either a , or |.
|
||||||
func LoadTestM365OrgUsers(t *testing.T) []string {
|
func LoadTestM365OrgUsers(t *testing.T) []string {
|
||||||
cfg, err := readTestConfig()
|
cfg, err := readTestConfig()
|
||||||
require.NoError(t, err, "retrieving load test m365 org users from test configuration", clues.ToCore(err))
|
require.NoError(t, err, "retrieving load test m365 org users from test configuration", clues.ToCore(err))
|
||||||
|
|||||||
@ -51,7 +51,7 @@ func New(failFast bool) *Bus {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// FailFast returs the failFast flag in the bus.
|
// FailFast returns the failFast flag in the bus.
|
||||||
func (e *Bus) FailFast() bool {
|
func (e *Bus) FailFast() bool {
|
||||||
return e.failFast
|
return e.failFast
|
||||||
}
|
}
|
||||||
|
|||||||
@ -109,22 +109,22 @@ func (i Item) Values() []string {
|
|||||||
return []string{"Error", i.Type.Printable(), i.Name, cn, i.Cause}
|
return []string{"Error", i.Type.Printable(), i.Name, cn, i.Cause}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ContainerErr produces a Container-type Item for tracking erronous items
|
// ContainerErr produces a Container-type Item for tracking erroneous items
|
||||||
func ContainerErr(cause error, id, name string, addtl map[string]any) *Item {
|
func ContainerErr(cause error, id, name string, addtl map[string]any) *Item {
|
||||||
return itemErr(ContainerType, cause, id, name, addtl)
|
return itemErr(ContainerType, cause, id, name, addtl)
|
||||||
}
|
}
|
||||||
|
|
||||||
// FileErr produces a File-type Item for tracking erronous items.
|
// FileErr produces a File-type Item for tracking erroneous items.
|
||||||
func FileErr(cause error, id, name string, addtl map[string]any) *Item {
|
func FileErr(cause error, id, name string, addtl map[string]any) *Item {
|
||||||
return itemErr(FileType, cause, id, name, addtl)
|
return itemErr(FileType, cause, id, name, addtl)
|
||||||
}
|
}
|
||||||
|
|
||||||
// OnwerErr produces a ResourceOwner-type Item for tracking erronous items.
|
// OnwerErr produces a ResourceOwner-type Item for tracking erroneous items.
|
||||||
func OwnerErr(cause error, id, name string, addtl map[string]any) *Item {
|
func OwnerErr(cause error, id, name string, addtl map[string]any) *Item {
|
||||||
return itemErr(ResourceOwnerType, cause, id, name, addtl)
|
return itemErr(ResourceOwnerType, cause, id, name, addtl)
|
||||||
}
|
}
|
||||||
|
|
||||||
// itemErr produces a Item of the provided type for tracking erronous items.
|
// itemErr produces a Item of the provided type for tracking erroneous items.
|
||||||
func itemErr(t itemType, cause error, id, name string, addtl map[string]any) *Item {
|
func itemErr(t itemType, cause error, id, name string, addtl map[string]any) *Item {
|
||||||
return &Item{
|
return &Item{
|
||||||
ID: id,
|
ID: id,
|
||||||
@ -176,7 +176,7 @@ var _ print.Printable = &Skipped{}
|
|||||||
// the underlying reason is transient or otherwise recoverable,
|
// the underlying reason is transient or otherwise recoverable,
|
||||||
// the item should not be skipped.
|
// the item should not be skipped.
|
||||||
//
|
//
|
||||||
// Skipped wraps Item primarily to minimze confusion when sharing the
|
// Skipped wraps Item primarily to minimize confusion when sharing the
|
||||||
// fault interface. Skipped items are not errors, and Item{} errors are
|
// fault interface. Skipped items are not errors, and Item{} errors are
|
||||||
// not the basis for a Skip.
|
// not the basis for a Skip.
|
||||||
type Skipped struct {
|
type Skipped struct {
|
||||||
|
|||||||
@ -59,7 +59,7 @@ func Example_seed() {
|
|||||||
func Example_logger_standards() {
|
func Example_logger_standards() {
|
||||||
log := logger.Ctx(context.Background())
|
log := logger.Ctx(context.Background())
|
||||||
|
|
||||||
// 1. Keep messsages short. Lowercase text, no ending punctuation.
|
// 1. Keep messages short. Lowercase text, no ending punctuation.
|
||||||
// This ensures logs are easy to scan, and simple to grok.
|
// This ensures logs are easy to scan, and simple to grok.
|
||||||
//
|
//
|
||||||
// preferred
|
// preferred
|
||||||
|
|||||||
@ -132,7 +132,7 @@ var (
|
|||||||
|
|
||||||
// Builder is a simple path representation that only tracks path elements. It
|
// Builder is a simple path representation that only tracks path elements. It
|
||||||
// can join, escape, and unescape elements. Higher-level packages are expected
|
// can join, escape, and unescape elements. Higher-level packages are expected
|
||||||
// to wrap this struct to build resource-speicific contexts (e.x. an
|
// to wrap this struct to build resource-specific contexts (e.x. an
|
||||||
// ExchangeMailPath).
|
// ExchangeMailPath).
|
||||||
// Resource-specific paths allow access to more information like segments in the
|
// Resource-specific paths allow access to more information like segments in the
|
||||||
// path. Builders that are turned into resource paths later on do not need to
|
// path. Builders that are turned into resource paths later on do not need to
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
---
|
---
|
||||||
slug: benchmarking-intel-vs-arm-for-backup-applications
|
slug: benchmarking-intel-vs-arm-for-backup-applications
|
||||||
title: "Benchmarking Intel vs. ARM (Graviton) for Splitting, Compressing, Hashing, and Encrypting Data"
|
title: "Benchmarking Intel vs. ARM (Graviton) for Splitting, Compressing, Hashing, and Encrypting Data"
|
||||||
description: "Throughput and cost-effectiveness comparision of Intel vs. Arm using compute-intensive data-processing microbenchmarks."
|
description: "Throughput and cost-effectiveness comparison of Intel vs. Arm using compute-intensive data-processing microbenchmarks."
|
||||||
authors: ntolia
|
authors: ntolia
|
||||||
tags: [corso, intel, arm, benchmarks]
|
tags: [corso, intel, arm, benchmarks]
|
||||||
date: 2022-12-12
|
date: 2022-12-12
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
description: "Connect to a Microsft 365 tenant"
|
description: "Connect to a Microsoft 365 tenant"
|
||||||
---
|
---
|
||||||
|
|
||||||
# Microsoft 365 access
|
# Microsoft 365 access
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user