* count workspace starts in debug mode
Signed-off-by: Michal Vala <mvala@redhat.com>
fix maven dependencies
Signed-off-by: Michal Vala <mvala@redhat.com>
observe debug mode metrics with events
Signed-off-by: Michal Vala <mvala@redhat.com>
change start attemts in debug mode metrics name, fix pom deps
Signed-off-by: Michal Vala <mvala@redhat.com>
rename start workspace in debug metrics with tags
Signed-off-by: Michal Vala <mvala@redhat.com>
* add options to workspace start event to be able to count debug starts
* remove no longer used logwatch meter binder, write hopefully proper metrics tags
Signed-off-by: Michal Vala <mvala@redhat.com>
* cleanup
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix tags again
Signed-off-by: Michal Vala <mvala@redhat.com>
* grafana graph with workspace start attempts total and in debug
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* runtime log messages and bytes metrics
Signed-off-by: Michal Vala <mvala@redhat.com>
* add missing license header
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix grafana datasources
Signed-off-by: Michal Vala <mvala@redhat.com>
* set grafana graphs mins for runtime logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* watch current logwatch instances
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix module version in pom.xml, fix log message grammar, format
* runtime log messages and bytes metrics
Signed-off-by: Michal Vala <mvala@redhat.com>
add missing license header
Signed-off-by: Michal Vala <mvala@redhat.com>
fix grafana datasources
Signed-off-by: Michal Vala <mvala@redhat.com>
set grafana graphs mins for runtime logs
Signed-off-by: Michal Vala <mvala@redhat.com>
explicitly set charset when counting runtime log bytes
Signed-off-by: Michal Vala <mvala@redhat.com>
* javadoc and fix pom module dependency
Signed-off-by: Michal Vala <mvala@redhat.com>
* tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* add grafana dashboard graph with current watchers
Signed-off-by: Michal Vala <mvala@redhat.com>
* removed infrastructure-metrics module
Signed-off-by: Michal Vala <mvala@redhat.com>
* Revert "removed infrastructure-metrics module"
This reverts commit 16392f5936378204031330971e0a874aacf0723a.
* moved CurrentLogwatchersMeterBinder into own maven and guice module and events into kubernetes module
Signed-off-by: Michal Vala <mvala@redhat.com>
Additionally, the following fixes are included:
* Honor the sidecar image pull policy while deploying jwt proxy sidecar into
the workspace pod.
* Configure the JWT proxy completely in the pod. Don't leave anything
to the hardcoded values in the che-jwtproxy image.
Signed-off-by: Lukas Krejci <lkrejci@redhat.com>
* collect logs first
* very very rough log watching implementation, does not even work
Signed-off-by: Michal Vala <mvala@redhat.com>
* ok this should work
Signed-off-by: Michal Vala <mvala@redhat.com>
* cleanup
Signed-off-by: Michal Vala <mvala@redhat.com>
* format
Signed-off-by: Michal Vala <mvala@redhat.com>
* simplify, get rid of custom input stream
Signed-off-by: Michal Vala <mvala@redhat.com>
* format
Signed-off-by: Michal Vala <mvala@redhat.com>
* start watching for logs later, when we know the machines we're interested in
Signed-off-by: Michal Vala <mvala@redhat.com>
* make waiting for containers to get the logs rather time based
Signed-off-by: Michal Vala <mvala@redhat.com>
* block closing only when workspace failure, reusing kubernetes threadpool... can this thing get any better?
Signed-off-by: Michal Vala <mvala@redhat.com>
* just some refactoring and cleanup
Signed-off-by: Michal Vala <mvala@redhat.com>
* and format
Signed-off-by: Michal Vala <mvala@redhat.com>
* reading log input stream moved to LogWatcher and PodLongHandler is now responsible for handling just single log messages
Signed-off-by: Michal Vala <mvala@redhat.com>
* more precise checking for log error
Signed-off-by: Michal Vala <mvala@redhat.com>
* format
Signed-off-by: Michal Vala <mvala@redhat.com>
* make it possible to start the workspace in debug mode
Signed-off-by: Michal Vala <mvala@redhat.com>
* debug mode in devfile attributes
Signed-off-by: Michal Vala <mvala@redhat.com>
* get rid of inconsistent executor in KubernetesDeployments#watchLogs method
Signed-off-by: Michal Vala <mvala@redhat.com>
* log and javadoc fixes
Signed-off-by: Michal Vala <mvala@redhat.com>
* nullcheckcs for the devfile and fix tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* better logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* add few tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* LogWatcher tests first batch
Signed-off-by: Michal Vala <mvala@redhat.com>
* remove unused imports
Signed-off-by: Michal Vala <mvala@redhat.com>
* bit reworked container logwatch
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix missing license headers
Signed-off-by: Michal Vala <mvala@redhat.com>
* equals, hashCode and toString
Signed-off-by: Michal Vala <mvala@redhat.com>
* that's not probably needed
Signed-off-by: Michal Vala <mvala@redhat.com>
* review fixes, simplify code, better variable names
Signed-off-by: Michal Vala <mvala@redhat.com>
* we don't need distinct on Set
Signed-off-by: Michal Vala <mvala@redhat.com>
* add rest param to watch the workspace pod logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix and add tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* return when finish with watching logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* test successful ended container log watch
Signed-off-by: Michal Vala <mvala@redhat.com>
* simplify
Signed-off-by: Michal Vala <mvala@redhat.com>
* comment up
Signed-off-by: Michal Vala <mvala@redhat.com>
* tests
Signed-off-by: Michal Vala <mvala@redhat.com>
* PodLogHandlerToEventPublisherTest
Signed-off-by: Michal Vala <mvala@redhat.com>
* make debug workspace start query param lowercase
Signed-off-by: Michal Vala <mvala@redhat.com>
* hold sharedpool object in namespace/project factories
Signed-off-by: Michal Vala <mvala@redhat.com>
* watch plugin broker logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* synchroinze closing and adding container log watchers, wait before close on error
Signed-off-by: Michal Vala <mvala@redhat.com>
* synchronize new logwatch with closing
Signed-off-by: Michal Vala <mvala@redhat.com>
* add missing license header
Signed-off-by: Michal Vala <mvala@redhat.com>
* fix logwatch close test
Signed-off-by: Michal Vala <mvala@redhat.com>
* get startOptions down to broker deploy to tell wether we want to watch the logs
Signed-off-by: Michal Vala <mvala@redhat.com>
* Update infrastructures/kubernetes/src/main/java/org/eclipse/che/workspace/infrastructure/kubernetes/namespace/KubernetesDeployments.java
Co-Authored-By: Angel Misevski <amisevsk@redhat.com>
* Update infrastructures/kubernetes/src/main/java/org/eclipse/che/workspace/infrastructure/kubernetes/namespace/log/LogWatcher.java
Co-Authored-By: Angel Misevski <amisevsk@redhat.com>
* review fixes
Signed-off-by: Michal Vala <mvala@redhat.com>
* aaand format
Signed-off-by: Michal Vala <mvala@redhat.com>
* timeoutes to constants
Signed-off-by: Michal Vala <mvala@redhat.com>
* remove unnecessary AtomiBoolean, synchronize creating LogWatch, and few more review fixes
Signed-off-by: Michal Vala <mvala@redhat.com>
* limit log inputstream size to be safe
Signed-off-by: Michal Vala <mvala@redhat.com>
* remove logwatch TODO, which is fixed now
Signed-off-by: Michal Vala <mvala@redhat.com>
* don't need AtomicBoolean, extra options isEmpty check, some javadoc
Signed-off-by: Michal Vala <mvala@redhat.com>
Co-authored-by: Angel Misevski <amisevsk@redhat.com>
* Make embedded OAuth authentication model default for both singe and multiuser che
Signed-off-by: Sergii Kabashniuk <skabashniuk@redhat.com>
* Allow to get oauth tokens with machine tokens
Co-authored-by: Oleksii Kurinnyi <okurinny@redhat.com>
Brokers update includes fix to warn user when multiple plugins embed the
same plugin (which can cause plugins to fail).
Signed-off-by: Angel Misevski <amisevsk@redhat.com>
che #15709 Ability to add a plugin via URL, that is not in a plugin registry via CHE_WORKSPACE_DEFAULT__EDITOR_PLUGINS env var and dedicated property
Signed-off-by: Tom George <tg82490@gmail.com>
* Add ability to set up Che workspace and postgress pvc names using helm.
Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
* improve helm value chePostgresPVCStorageClassName location
Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
* Fix indent in the yaml.
Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
Refactor the plugin brokering process to accomodate changes in plugin
brokers (splitting brokers into a metadata and artifacts broker)
Co-authored-by: Sergii Leshchenko <sleshche@redhat.com>
Signed-off-by: Angel Misevski <amisevsk@redhat.com>
Load the workspace during then namespace resolution so that we can check
for the attribute stored in the workspace attributes.
Switch the default namespace to `<username>-che`.
Update the property descriptions in che.properties and use the new
CHE_INFRA_KUBERNETES_NAMESPACE_DEFAULT in the helm chart.
Move the delete to the KubernetesNamespace/OpenShiftProject to
concentrate the handling in one place.
Split the isNamespaceStatic() (previously called isPredefined()) into
isCreatingNamespaces() and isManagingNamespaces() to separately capture
the two usecases in which that single method was previously incorrectly
called. Also make these methods workspace-specific to be able to
consistently work with the legacy logic across all methods.
Signed-off-by: Lukas Krejci <lkrejci@redhat.com>