Re: Mocking a class in a script

2020-10-22 Thread Mantas Gridinas
Id suggest providing URL as an argument, but this looks too complex to be shoved in a groovy script. On Thu, Oct 22, 2020, 12:54 Иванов Григорий - wrote: > > Hi > > I have a production route with a groovy script I should test, is there a > way to mock URL class or do something else to not really

Re: Stream Huge JSON File

2020-10-23 Thread Mantas Gridinas
>From personal experience any activities related to file component tend to try to load entire file into memory. You could perhaps fiddle around by converting it to an input stream but then you get into an issue of making sure that you don't read an entire file into memory before actually converting

Re: Stream Huge JSON File

2020-10-23 Thread Mantas Gridinas
ub < > https://github.com/rmannibucau> | > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book > < > https://www.packtpub.com/application-development/java-ee-8-high-performance > > > > > Le ven. 23 oct. 2020 à 16:16, Mantas Gridinas a > écrit : > >

Regarding toD component and throwing on non existing endpoints

2021-01-11 Thread Mantas Gridinas
Yo! I would like toD EIP to throw when it would create an endpoint, rather than create it. I've been reading a bit about toD EIP (for 3.x, since 2.x documentation is not available for it anymore?) and I found the following flag: ignoreInvalidEndpoint - Ignore the invalidate endpoint exception whe

Re: Load route steps dynamically

2021-04-17 Thread Mantas Gridinas
Sounds like you're programming in your routes rather than integrating processes/systems. I think the simplest solution would be using feature flags in choice blocks. On Sat, Apr 17, 2021 at 8:00 AM ski n wrote: > > Hi all, > > I have a question how to load (add or remove) route steps dynamically

Re: How to override CXF version for Camel-CXF

2021-05-18 Thread Mantas Gridinas
Sure. Add the cxf dependencies in your pom.xml. Mind you will need to add all dependencies that camel-cxf artifact requires, otherwise you might encounter weird issues. On Tue, May 18, 2021, 12:35 Chio Chuan Ooi wrote: > Hi All, > > i am currently using camel 3.7.4 and notice that camel-cxf is u

Re: One CamelContext vs. multiple CamelContexts

2019-09-27 Thread Mantas Gridinas
You're going to be fine. My current project runs 400+ routes in single context. On Fri, Sep 27, 2019 at 7:14 PM Ron Cecchini wrote: > > TL;DR: 1 CamelContext with 100 Routes vs. 100 CamelContexts each with 1 Route > > Say I need to ingest data from a hundred sensors or data sources, over TCP or

Re: too many objects

2019-10-08 Thread Mantas Gridinas
What is the actual route definition you're using? I would try swapping out http4 component for regular http component. On Mon, Oct 7, 2019 at 2:34 PM arshid wrote: > > > > Hi all, > > > > I am reading a csv file around 300 gb and then splitting it and parsing it to > json and sending it to rest

Re: How to aggregate files after producer created all files?

2019-11-13 Thread Mantas Gridinas
I suppose the solution would not be using the file component at all, but rather agregating messages and using ZipOutputStream to convert those messages into a zip file and only then to store it in the file system via file component. On Wed, Nov 13, 2019, 20:57 WEIQUAN YUAN wrote: > can you use s

Re: Aggregator within Splitter

2019-12-15 Thread Mantas Gridinas
Splitter already features an aggregation strategy as argument. By default, it discards any modifications done to messages while consuming them during splitter EIP. Are you sure you aren't looking for that? On Sun, Dec 15, 2019 at 5:53 AM Jeremy Ross wrote: > > Hi, > > I have a use case that invol

Re: Aggregator within Splitter

2019-12-15 Thread Mantas Gridinas
be aggregated as one output message. My use case > > requires splits elements to be aggregated somewhat arbitrarily. E.g., if > > the splitter splits a message into 1000 elements, this will be aggregated > > into 20-40 "output" messages, depending on the content of

Re: Parsing JSON within the Camel Velocity component template?

2020-01-07 Thread Mantas Gridinas
Why not use unmarshall EIP before passing the body to velocity template? Then, as per the velocity component, you would access your body via $body variable. On Mon, Jan 6, 2020 at 3:19 PM Alex Dettinger wrote: > > Hi Gerald, > > The example below shows how to use a pojo from a velocity context:

Re: Parsing JSON within the Camel Velocity component template?

2020-01-07 Thread Mantas Gridinas
he single attributes of the JSON tree inside Velocity component. > > Best > - Gerald > > Am 07.01.2020 um 12:45 schrieb Mantas Gridinas : > > > > Why not use unmarshall EIP before passing the body to velocity > > template? Then, as per the velocity component

Re: Parsing JSON within the Camel Velocity component template?

2020-01-07 Thread Mantas Gridinas
nsfer the JSON into a (pre-defined) > POJO in front of Velocity processing. I wonder if there is any other way to > access a JSON object directly from the Velocity engine. > > Best > - Gerald > > > Mantas Gridinas hat am 7. Januar 2020 um 12:51 > geschrieben: > > >

Re: Recommendation for a HTTP(S) Consumer Component in Camel 3

2020-02-08 Thread Mantas Gridinas
Personally i'd go for regular approach of having a standalone server which just throws all requests into camel context via direct component. On Sat, Feb 8, 2020, 13:15 Gerald Kallas wrote: > Dear community, > > I want to configure HTTP(S) consumers with following requirements > > 1. TLS/SSL supp