Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • May 26 16:10
    shawkins edited #4172
  • May 26 15:21
    OneCricketeer edited #3870
  • May 26 14:53
    sonarcloud[bot] commented #4175
  • May 26 14:29
    shawkins review_requested #4175
  • May 26 14:29
    shawkins opened #4175
  • May 26 14:12
    sonarcloud[bot] commented #4174
  • May 26 14:06

    manusa on master

    for consistency request should … (compare)

  • May 26 14:06
    manusa closed #4173
  • May 26 14:06
    manusa milestoned #4173
  • May 26 13:46
    shawkins edited #4174
  • May 26 13:45
    shawkins review_requested #4174
  • May 26 13:45
    shawkins review_requested #4174
  • May 26 13:45
    shawkins review_requested #4174
  • May 26 13:45
    shawkins opened #4174
  • May 26 13:30
    manusa commented #4173
  • May 26 13:27
    sonarcloud[bot] commented #4173
  • May 26 13:04
    shawkins commented #4173
  • May 26 13:03
    shawkins synchronize #4173
  • May 26 12:45
    shawkins review_requested #4173
  • May 26 12:45
    shawkins review_requested #4173
Rohan Kumar
@rohanKanojia
I realized the reason why we had to add a hack for replacing javaType with existingJavaType was due to a hardcoded check added in generator during JSONSchema2Pojo upgrade
I have created an issue for this fabric8io/kubernetes-client#3372
so if I remove the hack and use latest generator, it works if I rename package to io.fabric8.apicurio.registry.operator.api.model. rohanKanojia/apicurio-model-generator@8b6ad96
I'll probably create a PR to your repository once above issue gets fixed
Rohan Kumar
@rohanKanojia

probably the most desirable thing is to generate POJOs which would extend CustomResource so I don't have to load yaml CRDs in my code (as that's deprecated and requires me to actually get hold of those descriptors).

I think we can do it by providing a manual ApicurioRegistry and ApicurioRegistryList which will extend CustomResource

we can add a delete task to maven-antrun-plugin to delete generated ApicurioRegistry class and use hand written class which will extend CustomResource
Jakub Cechacek
@jcechace

probably the most desirable thing is to generate POJOs which would extend CustomResource so I don't have to load yaml CRDs in my code (as that's deprecated and requires me to actually get hold of those descriptors).

I think we can do it by providing a manual ApicurioRegistry and ApicurioRegistryList which will extend CustomResource

Loading the yaml descriptor seems cleaner in that case. Writing the classes doesn't really seem as a good option and thus I think this method shouldn't be deprecated -- the majority of CR/Ds one is going to encounter are not going to be written in java.

Rohan Kumar
@rohanKanojia
I think you're right
I also think this method should not be deprecated. It will come handy when you're trying to use same pojo for different customresource versions fabric8io/kubernetes-client#2738
I think we should create a new issue to start this discussion again
Rohan Kumar
@rohanKanojia

the majority of CR/Ds one is going to encounter are not going to be written in java.

I think I see more and more people interested in writing operators in java these days

Red Hat is also investing some resources in java operator sdk
Jakub Cechacek
@jcechace
Yes but we should strive for general usability :)

@rohanKanojia
btw did you ever see this? Without touching my cluster the client starting spitting this at me

Caused by: io.fabric8.kubernetes.client.WatcherException: too old resource version: 48308901 (48321468)

5.2.1 client

Jakub Cechacek
@jcechace
Ok I supsect some micro release update in the cluster broke something. Updating to 5.5 fixed it
Rohan Kumar
@rohanKanojia
Hmm, yes. I have seen this
If you use SharedIndexInformers, client would automatically handle 410
Jakub Cechacek
@jcechace
strangely in. my case this was happening across multiple executions so no watch should have persisted .. nevertheless update fixed and I want to thank you for removing InterruptedException from waits :)
Much cleaner
Rohan Kumar
@rohanKanojia
no need to thank me, @shawkins improved this
Jonathan Block
@blockjon
(newbie question) I'm learning Kotlin and when I use this kubernetes-client in a coroutine, my program hangs and I'm not sure why. I posted some details here fabric8io/kubernetes-client#3382 I wouldn't be surprised if the answer is obvious but this is my 3rd day of Kotlin so I'm currently stumped
Rohan Kumar
@rohanKanojia
is your kotlin coroutine doing something else?
I don't know kotlin but I think it might be okhttp
Jakub Cechacek
@jcechace
Migth want to wrap the call in runBlocking
Jakub Cechacek
@jcechace
@rohanKanojia is there a way to use the client for the equivalent of oc apply -f <folder or file>?
Rohan Kumar
@rohanKanojia
could you please try client.load(getClass().getResourceAsStream("/file.yml")).inNamespace("foo").createOrReplace()
this won't work if there are custom resources present in file
Jakub Cechacek
@jcechace
Will give it a try, it's for future work. I'm just planning some improvements for our project
will it work with multiple resources in the same file?
Rohan Kumar
@rohanKanojia
I think so
Jonathan Block
@blockjon
@rohanKanojia I was able to determine is that the coroutine hangs for exactly 5 minutes when I use this kubernetes-client library. Using a custom config and okHttpClient didnt seem to have an effect.
Jonathan Block
@blockjon
@rohanKanojia Mystery solved "Clear the connection pool with evictAll(). Note that the connection pool’s daemon thread may not exit immediately." - https://square.github.io/okhttp/4.x/okhttp/okhttp3/-ok-http-client/#shutdown-isnt-necessary
Rohan Kumar
@rohanKanojia
cool
Do you think we can add a FAQ regarding this to https://github.com/fabric8io/kubernetes-client/blob/master/doc/FAQ.md ?
Marc Nuri
@manusa
Starting release process for v5.7.0
Rohan Kumar
@rohanKanojia
:+1:
vamseeds
@vamseeds

Hi Guys!
I see io.fabric8.kubernetes.client.dsl.internal.core.v1.PodTemplateOperationsImpl has been removed in v5.7.0 and I don't see any info relating to this removal in changelog .
is io.fabric8.kubernetes.client.dsl.internal.HasMetadataOperationsImpl replacement for above class ?

my previous usage (v5.4.0):

new PodTemplateOperationsImpl(
                k8sClient.getHttpClient(),
                k8sClient.getConfiguration());

current usage(v5.7.0):

new HasMetadataOperationsImpl<>(
                k8sClient.getHttpClient(),
                k8sClient.getConfiguration(), ResourceDefinitionContext.fromResourceType(PodTemplate.class), PodTemplate.class, PodTemplateList.class);
Kamal khanna
@KamalSinghKhanna
hey! new here
I am trying to run mvn clean install but it is showing the error
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M5:test (default-test) on project kubernetes-client: There are test failures.
[ERROR]
[ERROR] Please refer to /home/kamal/Desktop/Java-project/kubernetes-client/kubernetes-client/target/surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <args> -rf :kubernetes-client
how to fix it?
Mohd Uzair
@MUzairS15
I think it's related to dependencies, could you tell more at which specific part build fail?
Try again with all needed dependencies, should work I think.
Rohan Kumar
@rohanKanojia
@KamalSinghKhanna : Were you able to resolve your issue?
which tests are failing specifically on your machine?
Marc Nuri
@manusa
Starting release process for v5.7.1
Rohan Kumar
@rohanKanojia
:+1: