Commit graph

38 commits

Author SHA1 Message Date
Pradyumna Kaushik
3b70a13cc8 refactored logging/types imports to dot imports 2019-12-05 21:43:16 -05:00
Pradyumna Kaushik
6fb0e4a3fe move cfg to loggers + refactor + log fn wrappers
1. Instead of maintaining a global config, each specialized logger
now stores its config.
2. Refactored logInterface to elektronLogger.
3. Refactored loggerImpl to baseElektronLogger to be consistent with
the rest of the code base.
4. Wrapped elektronLogger#Log(...) and elektronLogf(...) so that we
do not have to use the instance of elektronLogger everytime we want
to log. Instead, we just do logging.Log(...) or logging.Logf(...).
5. Wrapped elektronLogger#WithFields(...) and
elektronLogger#WithField(...).
6. Refactored codebase to adhere to the changes.
2019-12-05 21:32:37 -05:00
Pradyumna Kaushik
3d201bf437 refactored elektronLogging to logging 2019-12-05 17:38:56 -05:00
balandi1
bedfa52d7a Added functions to logging library
Added Logf() and WithFields() functions.
Logf() for logging formatted messages.
WithFields() for handling optional log fields.
2019-12-04 13:16:48 -05:00
balandi1
0c0361e209 Code Refactoring
Modified comments. Organized imports.
2019-11-26 14:24:20 -05:00
balandi1
eaac82ceb9 Few code improvements and refactoring 2019-11-21 15:26:57 -05:00
balandi1
cb5df9acc8 Removed ERROR, GENERAL, SUCCESS, WARNING log types 2019-11-21 14:58:14 -05:00
balandi1
268df3cd51 Changed alias for elektronLogging to elekLog 2019-11-21 14:35:20 -05:00
balandi1
270c8669e6 Revert previous commit. Renamed wrong alias 2019-11-21 14:12:53 -05:00
balandi1
9952b9861d Renamed alias log to elekLog 2019-11-21 14:02:47 -05:00
balandi1
13c3de44be Changed alias elekLogT to elekLogTypes 2019-11-21 13:05:52 -05:00
balandi1
4d15e59d4c Code formatting 2019-11-20 13:33:46 -05:00
balandi1
40efeca04b Replaced old usage with new library 2019-11-13 15:37:55 -05:00
PRADYUMNA KAUSHIK
e3caa90c31
Refactor imports, Add vendor/ as submodule (#5)
refact imports to github.xxx. update go.mod + go.sum

* removed vendor/ folder

* Added vendor/ submodule.

Moved dependencies that need to be vendored into separate repository.
	- https://github.com/spdfg/elektron-vendor
Added vendor/ as a submodule using the below command.
	- git submodule add https://github.com/spdfg/elektron-vendor vendor
If wanting to use vendor, run the following commands after cloning
elektron.
1. git submodule init
2. git submodule update

* added instructions to clone vendor/ submodule.

* updated module to spdfg. Refactored imports
2019-10-31 14:32:46 -04:00
Renan DelValle
291f4f3979
Adding GPLv3 Licensing. 2018-10-06 20:03:14 -07:00
Renan DelValle
9554bf2666
Runing goimports on project as well as fixing README so that headers render correctly. 2018-09-30 18:23:38 -07:00
Pradyumna Kaushik
66c19b53c9 Merged in differentSwitchingMechanisms (pull request #14)
DifferentSwitchingMechanisms

Approved-by: Akash Kothawale <akothaw1@binghamton.edu>
2018-09-23 19:21:52 -04:00
Pradyumna Kaushik
ae81125110 Merged in mapTaskDistrToSchedPolWhenSwitching (pull request #11)
MapTaskDistrToSchedPolWhenSwitching

Approved-by: Akash Kothawale <akothaw1@binghamton.edu>
2018-09-23 19:18:07 -04:00
Pradyumna Kaushik
85383da550 Merged in scheduleOnlySchedWindowTasks (pull request #6)
ScheduleOnlySchedWindowTasks

Approved-by: Akash Kothawale <akothaw1@binghamton.edu>
2018-09-23 19:07:22 -04:00
Pradyumna Kaushik
6c77aa777e Merged in resourceUsageTracking (pull request #2)
ResourceUsageTracking

Approved-by: Akash Kothawale <akothaw1@binghamton.edu>
Approved-by: Pradyumna Kaushik <pkaushi1@binghamton.edu>
2018-09-23 18:36:07 -04:00
Pradyumna Kaushik
9599588fb5 formatted code. 2018-09-23 17:49:08 -04:00
Pradyumna Kaushik
c31bf8db01 BUG Fix1: taskID creation in taskUtils#initTaskResourceRequirements. BUG Fix2: Converted value in utilities/trackResourceUsage#TrackResourceUsage#perHostResourceAvailability to be a pointer to ResourceCount. 2018-09-23 17:46:38 -04:00
Pradyumna Kaushik
657dc8df93 Track resource usage across the cluster. Created utility in utilities/ to track the total and the unused resources for each host in the cluster. Added utility to def/taskUtils.go to retrieve the resource requirement for a given taskID. Decoupled the code, to launch a list of tasks on a set of offerIDs, to schedulers/helpers.go and updated all the scheduling policies to call this function instead of directly calling mesos.SchedulerDriver#LaunchTasks. The resource availability of the cluster is updated at 2 stages -- 1. When the tasks are about to be launched (in schedulers/helpers.go#LaunchTasks), the scheduling policy switching logic will be able to adhere to the update in the resource availability due to the JUST launched tasks and 2. when a terminal status update is received for a task (in schedulers/base.go#statusUpdate). 2018-09-23 17:44:36 -04:00
Akash Kothawale
3b80af6d8f Fix: mesos-go imports 2018-09-23 17:31:03 -04:00
Pradyumna Kaushik
b807625b78 Fixed the comments to be capitalized at the start and also terminate with a period. 2017-09-28 15:36:47 -04:00
Pradyumna Kaushik
59266d207d retrofitted to use the generic task sorter. 2017-09-26 00:37:12 -04:00
Pradyumna Kaushik
3a9db01fa0 formatted files 2017-08-26 22:33:06 -04:00
Pradyumna Kaushik
8bc408dea1 fixed comments. Removed an old comment that no longer made sense. 2017-08-26 15:43:09 -04:00
Pradyumna Kaushik
9e620eaede changed def.TaskSorter(...) to def.SortTasks(...) for semantics. Now, def.SortTasks(...) also sorts the tasks instead of returning just a func (i, j int) bool {}. Removed TODO from the README associated with this PR 2017-08-26 15:39:45 -04:00
Pradyumna Kaushik
0869bea2d8 Used closures instead of strings for the generic sorter. This removed the need for reflection. 2017-08-26 15:19:30 -04:00
Pradyumna Kaushik
3c65bdf02e changed the scope of TaskResourceNames and SortCriteria to be package private. 2017-08-23 20:10:33 -04:00
Pradyumna Kaushik
f29b7f51a9 Added a generic task sorter utility. This allows for an array of tasks to be sorted based on any resource. The possible resources by which an array of tasks can be sorted currently are listed in def/sortingCriteria.go. One can add more to this if required. 2017-08-23 19:35:19 -04:00
Pradyumna Kaushik
e1350838f3 Merge branch 'kmeansTaskClassification' of https://bitbucket.org/sunybingcloud/electron into kmeansTaskClassification 2017-08-22 13:03:17 -04:00
Pradyumna Kaushik
f4459c8cbf Consolidated the ClassifyTasks(...) functions from topHeavy and bottomHeavy and added the function to def/taskUtils.go. Added TODOs for refining the means by which the kmeans classified clusters were sorted. 2017-08-22 13:00:40 -04:00
Pradyumna Kaushik
e3569e95ce fixed comments to be a little more meaningful. 2017-04-30 16:48:38 -04:00
Pradyumna Kaushik
74eb616a72 the observation that is to be considered for the classification of a task can now be given as a function that takes the task and returns the observations as a slice of float64. Retrofitted the other functions in taskUtils to make use of this feature. 2017-02-25 19:57:01 -05:00
Pradyumna Kaushik
e54697b0dc Added a task utility to be able to cluster tasks into N clusters based on their watts resource requirements. Electron now compatible with Go1.8 and no longer with 1.7. Added TODOs. 2017-02-25 15:43:32 -05:00
Pradyumna Kaushik
9dddc38cad created a utility for tasks that allows for KMeans clustering based on watts resource requirement 2017-02-24 20:52:59 -05:00