Time |
S |
Nick |
Message |
00:10 |
|
|
jieryn joined ##javaee |
00:10 |
|
|
jieryn joined ##javaee |
00:37 |
|
|
MegaMatt joined ##javaee |
02:08 |
|
|
cem_ joined ##javaee |
02:10 |
|
cem_ |
VV3 #4\/3 2| 5#4|2|D |
02:12 |
|
cem_ |
1 1=0|2937 7#47 (_)5(_)411'/ |
02:14 |
|
cem_ |
93371[]\[]9 ? |
02:17 |
|
cem_ |
50|2|2'/ 480(_)7 7#47 |
02:19 |
|
cem_ |
1 4/\/\ \/\/31|2|) |
02:23 |
|
cem_ |
907 17 ? |
02:24 |
|
pdurbin |
cem_: please stop |
02:25 |
|
cem_ |
50|2|2'/ (sorry) |
02:25 |
|
|
SoniEx2 joined ##javaee |
02:26 |
|
cem_ |
i want to learn forth too "))) |
03:28 |
|
pdurbin |
everybody loves Forth: http://irclog.perlgeek.de/perl6/2013-11-25#i_7910318 |
03:29 |
|
pdurbin |
so I watched this and it's awesome: Hello JavaEE 7 With Maven 3, JAX-RS 2.0 and JSON ...In 3 Mins : Adam Bien's Weblog - http://www.adam-bien.com/roller/abien/entry/hello_javaee_7_with_maven |
03:30 |
|
pdurbin |
so little code is needed to spit out some JSON with Java EE 7: https://gist.github.com/pdurbin/7652999 |
05:59 |
|
|
jenue joined ##javaee |
06:53 |
|
|
dangertools joined ##javaee |
07:57 |
|
|
pleroma joined ##javaee |
08:11 |
|
|
mite_mitreski joined ##javaee |
08:37 |
|
|
mite_mitreski joined ##javaee |
08:37 |
|
|
MiteMitreski joined ##javaee |
10:40 |
|
|
sajjadg joined ##javaee |
11:17 |
|
|
drspockbr joined ##javaee |
12:15 |
|
|
MegaMatt joined ##javaee |
13:01 |
|
|
yu joined ##javaee |
13:55 |
|
|
kobain joined ##javaee |
13:57 |
|
|
sajjadg joined ##javaee |
14:33 |
|
|
Naros joined ##javaee |
15:00 |
|
|
mite_mitreski joined ##javaee |
16:13 |
|
acuzio |
hey |
16:14 |
|
acuzio |
is Quest here ? |
16:27 |
|
semiosis |
acuzio: no. can't you see the nick list? |
16:34 |
|
acuzio |
I can but he hides in plain sight --- a lot |
16:34 |
|
acuzio |
I miss him :-( |
16:36 |
|
|
pdurbin joined ##javaee |
16:43 |
|
|
sfisque joined ##javaee |
16:51 |
|
|
Guest29472 joined ##javaee |
17:00 |
|
Naros |
I suspect Guest29472 might be him acuzio :) |
17:00 |
|
Naros |
He tends to be sneaky :P |
17:04 |
|
Guest29472 |
its simple to get the info from /whois nick but his nicks even identified to services got hacked some times though |
17:05 |
|
|
knoppix joined ##javaee |
17:17 |
|
|
weyer joined ##javaee |
17:19 |
|
acuzio |
Naros: :-) |
17:19 |
|
acuzio |
Guest29472: hmm - is that the company for which Quest works for ? |
17:25 |
|
|
Guest29472 joined ##javaee |
17:25 |
|
Guest29472 |
yes |
17:25 |
|
Guest29472 |
it what he worked for. in the past |
17:29 |
|
|
cem_ joined ##javaee |
17:30 |
|
Guest29472 |
any one uploaded multiple files in one to to spring based server? |
17:30 |
|
Guest29472 |
multipart |
17:32 |
|
* cem_ |
>.< |
18:15 |
|
|
Matthijs joined ##javaee |
18:15 |
|
|
Matthijs left ##javaee |
18:15 |
|
|
tang^ joined ##javaee |
18:16 |
|
|
John_John_ joined ##javaee |
18:16 |
|
|
tang^ left ##javaee |
18:52 |
|
|
Naros left ##javaee |
18:54 |
|
|
knoppix joined ##javaee |
19:03 |
|
|
mite_mitreski joined ##javaee |
19:14 |
|
|
weyer joined ##javaee |
19:45 |
|
|
Dev_ryanrr joined ##javaee |
19:46 |
|
|
Venat joined ##javaee |
19:52 |
|
|
Dev_ryanrr joined ##javaee |
19:59 |
|
|
Old_dev joined ##javaee |
20:26 |
|
Guest29472 |
can any one tell me how to make the user download a file via a normal web page while the file itself is read by the servlet from a remote location by a byte[] ? |
20:27 |
|
sfisque |
send the stream directly to the outputstream of the httpconnection. set the mime-type appropriately so the client knows how to handle it (otherwise it will assume text/plain and attempt to render it in situ) |
20:28 |
|
Guest29472 |
send the byte[] into that stream? |
20:28 |
|
sfisque |
yes |
20:28 |
|
Guest29472 |
hm |
20:28 |
|
Guest29472 |
understandable |
20:28 |
|
sfisque |
instead of sending an html page, send the file stream |
20:28 |
|
Guest29472 |
any shortcuts or prebuild ways in spring for that . i thought so <-- |
20:29 |
|
sfisque |
mom told me not to touch bad things |
20:29 |
|
Guest29472 |
lol |
20:29 |
|
sfisque |
:P |
20:32 |
|
|
Sircle joined ##javaee |
20:55 |
|
Guest29472 |
sfisque, public @ResponseBody File downloadFile(){return java.io.File}? |
20:57 |
|
Guest29472 |
I guess http wont understand java.io.File . what formate should it be in ? and what response hearders . any keyword to google? |
21:00 |
|
Guest29472 |
the file is on the server hardisk but not in the web dir path so i have to get the file via java.io.File then send it for the user to download |
21:00 |
|
sess |
Guest29472: you need to stream it via the response |
21:04 |
|
Guest29472 |
byte[] then |
21:04 |
|
Guest29472 |
but what headers or @responsebody I need to set up? |
21:05 |
|
Guest29472 |
would want to see a working example. either in spring or servlet. spring preferred though. and I assume that the download for the user would be just like any other file download from a website ? |
21:10 |
|
|
neuro__ joined ##javaee |
21:11 |
|
sess |
use google, there should be around 1000 examples of serving a binary file via spring mvc |
21:11 |
|
|
neuro_sys joined ##javaee |
21:11 |
|
sess |
either you set some response headers and stream the file, or possible spring mvc has some magic where you can just return a byte[] or stream via responsebody |
21:11 |
|
sfisque |
javaeebot lucky spring mvc stream file to client |
21:11 |
|
javaeebot |
sfisque: http://stackoverflow.com/questions/9913732/configuring-spring-mvc-controller-to-send-file-to-client |
21:12 |
|
sfisque |
Voila! |
21:16 |
|
Guest29472 |
:) |
21:16 |
|
Guest29472 |
how to make the type just as "file" rather image or something else. response.setContentType("image/jpeg"); |
21:17 |
|
Guest29472 |
oh. got it |
21:17 |
|
sfisque |
javaeebot lucky mime type binary stream |
21:17 |
|
javaeebot |
sfisque: http://kb.iu.edu/data/agtj.html |
21:17 |
|
sfisque |
application/octet-stream |
21:18 |
|
Guest29472 |
great |
21:41 |
|
|
wicketn01b joined ##javaee |
21:41 |
|
wicketn01b |
In this example, what is the @ColumnResult actually getting mapped to? How can I access it from my entity? Is this a viable way of adding a scalar to an entity? http://pastebin.com/kefR1ure |
21:58 |
|
Guest29472 |
sfisque, it worked. thanks! |
21:58 |
|
Guest29472 |
sess, ^ |
21:58 |
|
sfisque |
:-) |
21:59 |
|
Guest29472 |
response.setContentType("application/octet-stream"); |
21:59 |
|
Guest29472 |
response.setHeader("Content-Disposition", "attachment; filename=\"" + file.getName() + "\""); |
21:59 |
|
sfisque |
for the love of java, either use StringBuilder or String.concat() |
22:00 |
|
Guest29472 |
haha. lol yes |
22:00 |
|
Guest29472 |
stringbuilder is what I use |
22:00 |
|
sfisque |
either works fine |
22:00 |
|
sfisque |
or a MessageFormat.format(); |
22:00 |
|
Guest29472 |
never used concate but might try |
22:00 |
|
Guest29472 |
hm |
22:00 |
|
Guest29472 |
or string.format |
22:02 |
|
whartung |
oh please. |
22:04 |
|
Guest29472 |
String.format("The format method is %s!", "oh please"); |
22:04 |
|
whartung |
msg.append("There ").append("nothing ").append("worse ").append("than ").append("needlessly ").append("complicating ").append(code).append(space).append("for one off strings").append("especially when ").append("the compiler ").append(" DOES THIS FOR YOU!!"); |
22:05 |
|
Guest29472 |
whartung, but doing ""+"\"+ all the time is headache too |
22:05 |
|
* Guest29472 |
needs to run |
22:05 |
|
whartung |
bu thou have to do that no matter which way you do it |
22:06 |
|
sess |
Guest29472: cool |
22:10 |
|
sess |
http://i.imgur.com/1qkteVi.jpg |
22:10 |
|
sfisque |
sess :-D |
22:28 |
|
* cem_ |
Guest is Quest san |
23:04 |
|
|
guicara joined ##javaee |
23:06 |
|
* cem_ |
go to study :/ |
23:11 |
|
semiosis |
sess: funny pic |
23:21 |
|
|
DadaUmpa joined ##javaee |
23:27 |
|
|
DadaUmpa left ##javaee |
23:39 |
|
cem_ |
bot set get text :) |
23:45 |
|
cem_ |
lol almost i have the data of 7channels LOL |
23:52 |
|
neuro_sys |
Does anyone know if I can turn off the logging level of a jar that uses sl4jlogger? |
23:53 |
|
neuro_sys |
the jar contains a logback.xml but I don't want to modify the jar. |
23:54 |
|
* ifelse |
ppl like .py |
23:56 |
|
|
ifelse left ##javaee |